codegen for user-defined destructors

This commit is contained in:
Zahary Karadjov 2012-05-25 19:02:14 +03:00
commit 337e1ecc7c
4 changed files with 87 additions and 2 deletions

View file

@ -567,6 +567,9 @@ type
# for record types a nkRecord node
# for enum types a list of symbols
# else: unused
destructor*: PSym # destructor. warning: nil here may not necessary
# mean that there is no destructor.
# see instantiateDestructor in types.nim
owner*: PSym # the 'owner' of the type
sym*: PSym # types have the sym associated with them
# it is used for converting types to strings