Since dmd r629: ICE(expression.c, 816) occurs when null array is used in static-if or template constraint. Repro. -------------------- test.d static if (string.init.length > 0) // null array { } -------------------- % dmd -c -o- test Assertion failed: (precedence[e->op] != PREC_zero), function expToCBuffer, file expression.c, line 816. -------------------- It was a rejects-valid bug 1982 before r629. -------------------- % dmd-r628 -c -o- test test.d(1): Error: expression (null.length) > 0u is not constant or does not evaluate to a bool --------------------
The phobos' std.conv hits this issue. % dmd -c -unittest std/conv.d Assertion failed: (precedence[e->op] != PREC_zero), function expToCBuffer, file expression.c, line 816.
Fixed svn 651.
Got this issue today. Should I reopen the bug or submit a new ticket?
Original test case has been fixed so I'll create a new report. Sorry for the buzz.