HuoLanguage / huo

interpreted language written in C
MIT License
213 stars 21 forks source link

Figure out why AST nodes can't be freed #3

Open incrediblesound opened 8 years ago

incrediblesound commented 8 years ago

For some reason freeing an AST node causes a segfault. This may be because they reference other pointers that need to be freed or because there is corruption happening somewhere.

TheLoneWolfling commented 8 years ago

The content of AST nodes are referenced all over the place.

We'd need to do defensive copies of AST node content in order to be able to free them.