Commit 4255aa9b by Richard Kenner

(xcoff_declare_function): Deal with names created via the __asm__

construct that start with a leading '*'.

From-SVN: r10542
parent 2d43e089
...@@ -462,16 +462,19 @@ xcoffout_declare_function (file, decl, name) ...@@ -462,16 +462,19 @@ xcoffout_declare_function (file, decl, name)
char *n = name; char *n = name;
int i; int i;
for (i = 0; name[i]; ++i) if (*n == '*')
{ n++;
if (name[i] == '[') else
{ for (i = 0; name[i]; ++i)
n = (char *) alloca (i + 1); {
strncpy (n, name, i); if (name[i] == '[')
n[i] = '\0'; {
break; n = (char *) alloca (i + 1);
} strncpy (n, name, i);
} n[i] = '\0';
break;
}
}
/* Any pending .bi or .ei must occur before the .function pseudo op. /* Any pending .bi or .ei must occur before the .function pseudo op.
Otherwise debuggers will think that the function is in the previous Otherwise debuggers will think that the function is in the previous
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment