← Back to index
|
Original Bugzilla link
Bug 13920 – DMD crash when trying to set a delegate from __traits(getOverloads)
Status
RESOLVED
Resolution
FIXED
Severity
major
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-01-01T11:18:15Z
Last change time
2020-03-21T03:56:36Z
Keywords
ice, pull
Assigned to
Kenji Hara
Creator
Basile-z
Comments
Comment #0
by b2.temp — 2015-01-01T11:18:15Z
import std.stdio; struct get{} struct set{} mixin template attrAna(){ private void Ana() { foreach(m; __traits(allMembers, typeof(this))) foreach(o; __traits(getOverloads, typeof(this), m)) foreach(attr; __traits(getAttributes, o)) static if (is(attr == get)){ o; auto ICE = &o; //comment = no crash } } } class Foo{ mixin attrAna; this(A...)(A a){Ana;} private uint _prop; public @get uint propA(){writeln("o");return _prop;} public @set void propA(uint aValue){_prop = aValue;} } void main(string args[]){ auto foo = new Foo; } Maybe related to 9552
Comment #1
by k.hara.pg — 2015-01-19T09:37:41Z
My pull request will handle every overloads correctly, then automatically fix the ICE issue.
https://github.com/D-Programming-Language/dmd/pull/2130
Comment #2
by k.hara.pg — 2015-04-14T13:26:28Z
*** Issue 14448 has been marked as a duplicate of this issue. ***
Comment #3
by k.hara.pg — 2015-04-14T13:30:32Z
https://github.com/D-Programming-Language/dmd/pull/4589
Comment #4
by github-bugzilla — 2015-04-17T05:18:09Z
Commits pushed to master at
https://github.com/D-Programming-Language/dmd
https://github.com/D-Programming-Language/dmd/commit/c8173f3a87a14312f734f584af80fa686b4333f3
fix Issue 13920 - DMD crash when trying to set a delegate from __traits(getOverloads)
https://github.com/D-Programming-Language/dmd/commit/bb7947b2d64286118e79197a06cc78441bb302b2
Merge pull request #4589 from 9rnsr/fix13920 Issue 13920 - DMD crash when trying to set a delegate from __traits(getOverloads)
Comment #5
by github-bugzilla — 2015-06-17T21:04:47Z
Commits pushed to stable at
https://github.com/D-Programming-Language/dmd
https://github.com/D-Programming-Language/dmd/commit/c8173f3a87a14312f734f584af80fa686b4333f3
fix Issue 13920 - DMD crash when trying to set a delegate from __traits(getOverloads)
https://github.com/D-Programming-Language/dmd/commit/bb7947b2d64286118e79197a06cc78441bb302b2
Merge pull request #4589 from 9rnsr/fix13920