Discussion about deprecating @nogc and workarounds

Kapendev alexandroskapretsos at gmail.com
Sat Sep 7 08:05:10 UTC 2024


On Friday, 6 September 2024 at 09:37:48 UTC, solidstate1991 wrote:
> A lot of people are arguing (especially on Discord) that 
> `@nogc` should be discarded entirely in favor of betterC.

I am fine with how things are, but here are some ideas.

I am OK with removing `@nogc` because it's annoying to use and a 
bit useless. It kind of forces you to take a side, even though 
nogc code can work with gc code.

BetterC is weird, but it does do something. If `@nogc` were to be 
removed, BetterC could act as a replacement for those who want to 
avoid using the gc and enforce that at compile time.


More information about the Digitalmars-d mailing list