[Issue 14419] [CTFE] Need infinite loop detection?

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Mon Apr 6 09:34:40 PDT 2015


https://issues.dlang.org/show_bug.cgi?id=14419

--- Comment #5 from Kenji Hara <k.hara.pg at gmail.com> ---
(In reply to Ketmar Dark from comment #3)
> alias extern(C) immutable void function () VectorFunc;
> VectorFunc[3] g_pfnVectors = [
>   Reset_Handler,
> ];
> 
> extern(C) void Reset_Handler () {
>   while (true) {}
> }

It's another issue in the process of initializer semantic. Essentially it
should make a type error: Reset_Handler() is void and has no value, but current
dmd prematurely runs CTFE.

--


More information about the Digitalmars-d-bugs mailing list