https://issues.dlang.org/show_bug.cgi?id=15256
Issue ID: 15256
Summary: Data races with arrays allowed in @safe code
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Keywords: accepts-invalid, safe
Severity: critical
Priority: P1
Component: dmd
Assignee: [email protected]
Reporter: [email protected]
@safe:
shared string s;
void f() @safe
{
s="s";
}
A slice is stored with two mov instructions, so when the global variable is
modified concurrently, it can end up with pointer from one array and length
from another.
--