proposed @noreturn attribute

Nick Sabalausky (Abscissa) via Digitalmars-d digitalmars-d at puremagic.com
Sun Jul 9 11:49:35 PDT 2017


On 07/09/2017 06:51 AM, Daniel N wrote:
> On Sunday, 9 July 2017 at 10:31:47 UTC, Mr.D wrote:
>> On Saturday, 8 July 2017 at 10:15:39 UTC, Walter Bright wrote:
>>
>>> Has anyone a better idea?
>>
>> What about
>>
>> scope(exit) assert(0);
>>
>> ?
> 
> void func()
> out { assert(0); }
> body
> {
> }

Too indirect and verbose. An attribute or special "return type" would 
just cut straight to the case.


More information about the Digitalmars-d mailing list