digitalmars.D.bugs - [Issue 13874] New: Invalid FunctionTypeOf segfault the compiler
- via Digitalmars-d-bugs (31/31) Dec 17 2014 https://issues.dlang.org/show_bug.cgi?id=13874
https://issues.dlang.org/show_bug.cgi?id=13874 Issue ID: 13874 Summary: Invalid FunctionTypeOf segfault the compiler Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: DMD Assignee: nobody puremagic.com Reporter: pro.mathias.lang gmail.com The following code crashes the compiler: ```` import std.traits : FunctionTypeOf; enum DummyEnum; static assert(!is(FunctionTypeOf!DummyEnum)); ```` % ./projects/dlang/dmd/src/dmd segv.d [3] 8952 segmentation fault (core dumped) Valgrind believes it's a stack overflow: ==8964== Stack overflow in thread 1: can't grow stack to 0xffe801f1c ==8964== ==8964== Process terminating with default action of signal 11 (SIGSEGV): dumping core ==8964== Access not within mapped region at address 0xFFE801F1C ==8964== at 0x411591: TypeEnum::getProperty(Loc, Identifier*, int) (in /mnt/shared/projects/dlang/dmd/src/dmd) Tested with dmd 2.066.1 & master (v2.067-devel-1b8db26). --
Dec 17 2014