mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-08-19 04:40:04 +02:00
Fix overload resolution issue in dmd bug 313/314 fix.
This commit is contained in:
@@ -369,6 +369,7 @@ AliasDeclaration::AliasDeclaration(Loc loc, Identifier *id, Type *type)
|
||||
#endif
|
||||
this->overnext = NULL;
|
||||
this->inSemantic = 0;
|
||||
this->importprot = PROTundefined;
|
||||
assert(type);
|
||||
}
|
||||
|
||||
@@ -501,15 +502,16 @@ void AliasDeclaration::semantic(Scope *sc)
|
||||
FuncDeclaration *f = s->toAlias()->isFuncDeclaration();
|
||||
if (f)
|
||||
{
|
||||
FuncAliasDeclaration *fa = new FuncAliasDeclaration(f);
|
||||
fa->importprot = importprot;
|
||||
if (overnext)
|
||||
{
|
||||
FuncAliasDeclaration *fa = new FuncAliasDeclaration(f);
|
||||
if (!fa->overloadInsert(overnext))
|
||||
ScopeDsymbol::multiplyDefined(0, f, overnext);
|
||||
overnext = NULL;
|
||||
s = fa;
|
||||
s->parent = sc->parent;
|
||||
}
|
||||
s = fa;
|
||||
s->parent = sc->parent;
|
||||
}
|
||||
if (overnext)
|
||||
ScopeDsymbol::multiplyDefined(0, s, overnext);
|
||||
|
||||
Reference in New Issue
Block a user