Thread overview | |||||
---|---|---|---|---|---|
|
November 13, 2013 [Issue 11427] anonymous unions break structs in @safe code | ||||
---|---|---|---|---|
| ||||
https://d.puremagic.com/issues/show_bug.cgi?id=11427 Kenji Hara <k.hara.pg@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |pull --- Comment #2 from Rainer Schuetze <r.sagitario@gmx.de> 2013-11-03 01:52:10 PST --- Compile this code /////////////////// struct S { union { ubyte a; int x; } void[] arr; } int foo() @safe { S s1 = S(); S s2; return 0; } //////////////////// with "dmd -c test.d" fails with test.d(14): Error: variable test.foo.s2 unions containing pointers are not allowed in @safe functions Please note that the first variable s1 is ok! This is also triggered in std.format with this code: import std.format; import std.array; void foo() { FormatSpec!char spec = FormatSpec!char(); auto s = appender!string; formattedWrite(s, "%s", "hello"); } --- Comment #3 from Kenji Hara <k.hara.pg@gmail.com> 2013-11-13 07:35:24 PST --- https://github.com/D-Programming-Language/dmd/pull/2757 -- Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
December 16, 2013 [Issue 11427] anonymous unions break structs in @safe code | ||||
---|---|---|---|---|
| ||||
https://d.puremagic.com/issues/show_bug.cgi?id=11427 --- Comment #4 from github-bugzilla@puremagic.com 2013-12-16 11:21:17 PST --- Commit pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/090abe1096b94e091e5541cd8ae772624f718a5c fix Issue 11427 - anonymous unions break structs in @safe code -- Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
December 17, 2013 [Issue 11427] anonymous unions break structs in @safe code | ||||
---|---|---|---|---|
| ||||
https://d.puremagic.com/issues/show_bug.cgi?id=11427 Kenji Hara <k.hara.pg@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED -- Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation