uhmanoa-transpiler-project / shaka-scheme

The official repository for the UH Manoa Transpiler Project's Scheme interpreter, Shaka Scheme.
32 stars 24 forks source link

GC Integration, create_node() initialization, NodePtr re-aliased to GCNode #74

Closed btwooton closed 6 years ago

btwooton commented 6 years ago

This pull request implements the integration of the Garbage Collector with the rest of the code base. NodePtr has been re-aliased to GCNode, and an initialization mechanism has been implemented that allows the create_node() procedure to be dynamically bound to a procedure that creates Data objects that are managed by the garbage collector. All unit tests have been fixed by introducing GC instances into the appropriate test environments and calling init_create_node(). All unit tests should hopefully be passing again. We need to figure out a way to trick the type checker into allowing us to choose whether to bind create_node to the old procedure that returned a std::shared_ptr<Data> or to the new one that returns a GCNode without complaining about the NodePtr aliasing. For now, this is a quick and dirty fix. Please review and let me know if there are any questions/concerns/oversights.