2005-11-29 04:05:42 +00:00
|
|
|
#include <u.h>
|
|
|
|
|
#include <libc.h>
|
|
|
|
|
#include <bio.h>
|
|
|
|
|
#include <mach.h>
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
main(void)
|
|
|
|
|
{
|
|
|
|
|
Biobuf b, bout;
|
|
|
|
|
char *p, *s;
|
|
|
|
|
char buf[100000];
|
2020-01-10 14:44:21 +00:00
|
|
|
|
2005-11-29 04:05:42 +00:00
|
|
|
Binit(&b, 0, OREAD);
|
|
|
|
|
Binit(&bout, 1, OWRITE);
|
2020-01-10 14:44:21 +00:00
|
|
|
|
2005-11-29 04:05:42 +00:00
|
|
|
while((p = Brdline(&b, '\n')) != nil){
|
|
|
|
|
p[Blinelen(&b)-1] = 0;
|
|
|
|
|
werrstr("no error");
|
|
|
|
|
s = demanglegcc2(p, buf);
|
|
|
|
|
if(s == p)
|
|
|
|
|
Bprint(&bout, "# %s (%r)\n", p);
|
|
|
|
|
else
|
|
|
|
|
Bprint(&bout, "%s\t%s\n", p, s);
|
|
|
|
|
}
|
|
|
|
|
Bflush(&bout);
|
|
|
|
|
exits(0);
|
|
|
|
|
}
|