mfriends.nim 128 B

123456789101112
  1. type
  2. TMyObj = object
  3. x: int
  4. proc gen*[T](): T =
  5. var d: TMyObj
  6. # access private field here
  7. d.x = 3
  8. result = d.x