February 04, 2021 [Issue 21610] New: CTFE should not evaluate both branches for ?: operator | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=21610 Issue ID: 21610 Summary: CTFE should not evaluate both branches for ?: operator Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: bugzilla@bernis-buecher.de enum a = false ? 1 / 0 : 1; does not compile, but produces /home/D/test.d(1): Error: divide by 0 -- |
Copyright © 1999-2021 by the D Language Foundation