Bug 9552 – DMD crashed when taking member delegate from __traits(getOverloads)
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-02-20T08:47:00Z
Last change time
2013-02-23T11:38:51Z
Keywords
ice, pull
Assigned to
nobody
Creator
gor.f.gyolchanyan
Comments
Comment #0 by gor.f.gyolchanyan — 2013-02-20T08:47:17Z
class Test
{
void f() { }
}
void main()
{
auto test = new Test;
auto method = &(__traits(getOverloads, test, "f")[0]); // DMD crashes
}
Comment #1 by maxim — 2013-02-21T06:13:18Z
This compiles in 2.058 and not in 2.059
Comment #2 by maxim — 2013-02-21T07:05:53Z
Seems to be:
e0e17a035726252b1ec61be2a64aa58cc30d528c is the first bad commit
commit e0e17a035726252b1ec61be2a64aa58cc30d528c
Author: k-hara <[email protected]>
Date: Sun Jun 5 12:45:21 2011 +0900
fix Issue 7552 - Cannot get and combine a part of overloaded functions
FuncAliasDeclaration now has flag that its member funcalias is overloaded.
And it is used as an element of __traits(getOverloads) due to represent the function symbol isn't overloaded.
:040000 040000 a7f72c89f631bb0ae5ce2105d114141897e5061b 1aa8c2b9741ff16c1f33b9b9bf613c0b78817e28 M src
:040000 040000 e080b17e5d32a423553f4f7dcf0edd5af0ee012d 83836298f6b8376175a4f34987788cbd11c0b91d M test