Plan for D

IGotD- nise at nise.com
Mon May 17 19:10:09 UTC 2021


On Monday, 17 May 2021 at 16:56:37 UTC, Ola Fosheim Grostad wrote:
>
> Not impossible, you can do like C++, use smart pointers, but 
> unlike C++ inject a new IR before LLVM IR that does ARC. Also, 
> let the smart pointers use compiler intrinsics for ARC.

That's a possibility, however badging the code similar to 
unique_ptr and shared_ptr like in C++ is not something I want to 
do. What if I want to change the GC algorithm suddenly? One 
possibility is just to have a generic name for the GC type, like 
GcRef which is an alias for the actual GC type and then you can 
change it.

Anyone can do this today but still there is the default GC in 
phobos/druntime. Then we have to go through the entire library 
and change to the versatile GC alias.


More information about the Digitalmars-d mailing list