named arguments, string interpolation, please stop.

Paolo Invernizzi paolo.invernizzi at gmail.com
Thu Jan 11 22:54:45 UTC 2024


On Thursday, 11 January 2024 at 22:49:51 UTC, Guillaume Piolat 
wrote:
> On Thursday, 11 January 2024 at 21:37:01 UTC, Walter Bright 
> wrote:
>>
>> This subthread suggests to me that the problem with @nogc is 
>> it works.
>
>
> @nogc could get an escape hatch maybe?
> pure is especially annoying because no escape hatch.
>
> Perhaps we can live with their UB in a per-attribute basis.
> UB of @nogc is allocating  with GC, it only annoys in cases 
> without GC, else well, type system was broken.
>
> It's pretty nice to enforce statically no accidental allocation 
> in a time critical callback, in short the reasons that made 
> @nogc invented still apply.

+1, I was posting the same. If @nogc code _could_ call _explicit_ 
`@gc` functions that could be a solution.




More information about the Digitalmars-d mailing list