[Issue 12224] New: std.algorithm.move does not work for arrays of static length
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Feb 22 05:47:11 PST 2014
https://d.puremagic.com/issues/show_bug.cgi?id=12224
Summary: std.algorithm.move does not work for arrays of static
length
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: Phobos
AssignedTo: nobody at puremagic.com
ReportedBy: simon.buerger at rwth-aachen.de
--- Comment #0 from Simon <simon.buerger at rwth-aachen.de> 2014-02-22 05:47:08 PST ---
std.algorithm.move does not avoid postblit/destructor for arrays of static
length (which are value-types). Both variants of move (one and two parameters)
have this issue.
struct S
{
this(this) { writefln("copy"); }
}
void main()
{
S[1] a, b;
b = move(a); // calls copy-constructor but should not
move(a, b); // ditto
}
--
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list