http://d.puremagic.com/issues/show_bug.cgi?id=3397
Summary: Unintended function call to static opCall
Product: D
Version: 1.048
Platform: Other
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from Moritz Warning <[email protected]> 2009-10-14 06:27:15
PDT ---
Tested with DMD 1.049 and svn r208.
It's a blocker for Tango.
Error: cannot implicitly convert expression (stack.pop()) of type Pair!(uint)
to uint
struct Pair(T)
{
static Pair opCall(T a, T b)
{
return Pair.init;
}
}
struct Stack(T)
{
T pop()
{
return T.init;
}
}
void main()
{
Stack!(Pair!(uint)) stack;
Pair!(uint) item = stack.pop; //this line fails, works with stack.pop() or
auto
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------