mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-02-11 01:13:14 +01:00
Merged DMD commit 8999f902485d9930332010aeb9db6d44b16bcd4c:
Brad's fix for fail278 regression
This commit is contained in:
18
dmd/mangle.c
18
dmd/mangle.c
@@ -216,7 +216,6 @@ char *ClassDeclaration::mangle()
|
||||
char *TemplateInstance::mangle()
|
||||
{
|
||||
OutBuffer buf;
|
||||
char *id;
|
||||
|
||||
#if 0
|
||||
printf("TemplateInstance::mangle() %s", toChars());
|
||||
@@ -224,16 +223,19 @@ char *TemplateInstance::mangle()
|
||||
printf(" parent = %s %s", parent->kind(), parent->toChars());
|
||||
printf("\n");
|
||||
#endif
|
||||
id = ident ? ident->toChars() : toChars();
|
||||
Dsymbol *par = isnested || isTemplateMixin() ? parent : tempdecl->parent;
|
||||
char *id = ident ? ident->toChars() : toChars();
|
||||
if (!tempdecl)
|
||||
error("is not defined");
|
||||
else if (par)
|
||||
else
|
||||
{
|
||||
char *p = par->mangle();
|
||||
if (p[0] == '_' && p[1] == 'D')
|
||||
p += 2;
|
||||
buf.writestring(p);
|
||||
Dsymbol *par = isnested || isTemplateMixin() ? parent : tempdecl->parent;
|
||||
if (par)
|
||||
{
|
||||
char *p = par->mangle();
|
||||
if (p[0] == '_' && p[1] == 'D')
|
||||
p += 2;
|
||||
buf.writestring(p);
|
||||
}
|
||||
}
|
||||
buf.printf("%zu%s", strlen(id), id);
|
||||
id = buf.toChars();
|
||||
|
||||
Reference in New Issue
Block a user