https://issues.dlang.org/show_bug.cgi?id=14699
Ketmar Dark <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Hardware|x86_64 |All Summary|dmd 2.67 segfaults on |ICE: segfaults on array |innocent code |with zero size OS|Windows |All --- Comment #1 from Ketmar Dark <[email protected]> --- it asserts on GNU/Linux: "Internal error: backend/dt.c 120". and it asserts even with only "this works" line (i.e. having "this crashes" commented). the following code triggers the bug on GNU/Linux, x86: struct Table(K, V, ushort capacity_) { V[capacity_] values; } Table!(uint, ubyte[0], 10) thisWorks; dmd -c z00.d —> ICE. it does so on git HEAD too. this is triggered by `ubyte[0]`, changing it to `ubyte[1]` avoids the bug. so i'm changing hardware info and subject. p.s. it seems that there is unguarded `-1` somewhere in the compiler code, so `0‒1` results in `-1`, which triggers assertion in dt.c:120. --
