On Sunday, 16 May 2021 at 09:48:58 UTC, IGotD- wrote:
>In practice that's the case, that you cannot avoid GC unless you don't use anything from the standard library. As soon you use arrays, associative arrays and many other data structures GC will be used.
By definition, avoiding the GC means avoiding features that use the GC. And you don't lose everything in the standard library, either. A good chunk of it does not require the GC.
Like anything else in programming, it's a tradeoff. Give up the GC and you lose the convenience it provides. The question is, do you need to give up the GC or not? And if so, do you need to give it up completely or only in the spots where you absolutely cannot trigger an allocation?
I'm not saying there can't be more work done to alleviate any pain that arises from going without the GC. But I do believe some people reach for @nogc when they don't need to, and I don't think that's a demographic we should be aiming for.