http://d.puremagic.com/issues/show_bug.cgi?id=3983
Don changed:
What|Removed |Added
Keywords||patch
--- Comment #1 from Don 2010-06-11 02:36:12 PDT ---
Problem is in struct.c, StructDeclaration::semantic(), line 497:
it tries to find an opEquals() function, and if not present, it builds one.
It should look for a template opEquals() also. If there's a template opEquals,
then creating a non-template opEquals will inevitably cause a naming conflict.
Dsymbol *s = search_function(this, Id::eq);
FuncDeclaration *fdx = s ? s->isFuncDeclaration() : NULL;
+TemplateDeclaration *td = s ? s->isTemplateDeclaration() : NULL;
if (fdx)
{
eq = fdx->overloadExactMatch(tfeqptr);
if (!eq)
fdx->error("type signature should be %s not %s",
tfeqptr->toChars(), fdx->type->toChars());
}
-if (!eq)
+if (!eq && !td)
eq = buildOpEquals(sc2);
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---