amethods.nim 211 B

1234567891011121314
  1. type
  2. TBaseClass* = object of RootObj
  3. proc newBaseClass*: ref TBaseClass =
  4. new result
  5. method echoType*(x: ref TBaseClass) {.base.} =
  6. echo "base class"
  7. proc echoAlias*(x: ref TBaseClass) =
  8. echoType x