[Issue 15629] [REG2.066.0] wrong code with "-O -inline" but correct with "-O"
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Wed Apr 13 22:27:02 PDT 2016
https://issues.dlang.org/show_bug.cgi?id=15629
Walter Bright <bugzilla at digitalmars.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |bugzilla at digitalmars.com
--- Comment #6 from Walter Bright <bugzilla at digitalmars.com> ---
Comment 3 further reduces to:
void main() {
int[] a = [3];
int value = a[0] >= 0 ? a[0] : -a[0];
assert(a[0] == 3);
writeln(value, a);
}
void writeln(int v, int[] a) {
}
and only -O is needed (not -inline).
--
More information about the Digitalmars-d-bugs
mailing list