I am thinking about extra Crystal flexibility and implementing of configurable ARC (automatic reference counting, Rust and Swift are examples of ARC languages).
I am thinking of piggybacking on GC and to implement a visitor that will check the AST and insert acquire and release elements and occasional GC.free on not used reference variables.
Do you think it is feasible?
I want to test execution speed for different GC approaches. I see that -D gc_none is not freeing the memory but may be ARC approach can do it. Or we don’t even need to do acquire and release if we exactly know if value of the variable is passed along the way to the place where we can safely deallocate it.