[Issue 19796] New: PR#1982 broke array ops
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Apr 9 04:28:37 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=19796
Issue ID: 19796
Summary: PR#1982 broke array ops
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Severity: regression
Priority: P1
Component: druntime
Assignee: nobody at puremagic.com
Reporter: hsteoh at quickfur.ath.cx
Code:
-------
import std.stdio;
void main() {
double[] data = [ 0.5 ];
writefln("data=%s", data);
double[] result;
result.length = data.length;
result[] = -data[];
import std.stdio;writefln("result=%s", result);
}
-------
Output:
-------
data=[0.5]
result=[0]
-------
Expected output:
-------
data=[0.5]
result=[-0.5]
-------
This regression was introduced by commit
d7b99e91e2de6cb9476e4826d5404d431b39dafd.
--
More information about the Digitalmars-d-bugs
mailing list