Should debug{} allow GC?

Q. Schroll via Digitalmars-d digitalmars-d at puremagic.com
Sun Sep 11 04:26:09 PDT 2016


On Sunday, 11 September 2016 at 07:46:09 UTC, Manu wrote:
> I'm having a lot of trouble debugging @nogc functions. I have a 
> number of debug functions that use GC, but I can't call them 
> from @nogc code... should debug{} allow @nogc calls, the same 
> as impure calls?

Generally, there is more to consider. It makes no sense to allow 
impure debug inside a pure function and not to do so for other 
attributes. For nothrow, it is also quite annoying.

If no one has strong counterarguments, just file an enhancement 
request. Implementation of such should not be too difficult.


More information about the Digitalmars-d mailing list