version 1.31, 2001/09/18 14:05:14 |
version 1.32, 2001/09/18 14:10:55 |
|
|
static const char *handledash __P((char *, char *, const char *)); |
static const char *handledash __P((char *, char *, const char *)); |
static void expand_builtin __P((const char *[], int, int)); |
static void expand_builtin __P((const char *[], int, int)); |
static void expand_macro __P((const char *[], int)); |
static void expand_macro __P((const char *[], int)); |
|
static void dump_one_def __P((ndptr)); |
|
|
|
|
/* |
/* |
|
|
} |
} |
} |
} |
|
|
char *dumpfmt = "`%s'\t`%s'\n"; /* format string for dumpdef */ |
|
|
|
/* |
/* |
* expand_macro - user-defined macro expansion |
* expand_macro - user-defined macro expansion |
*/ |
*/ |
|
|
} |
} |
|
|
/* |
/* |
|
* dump_one_def - dump the specified definition. |
|
*/ |
|
static void |
|
dump_one_def(p) |
|
ndptr p; |
|
{ |
|
fprintf(stderr, "`%s'\t`%s'\n", p->name, p->defn); |
|
} |
|
|
|
/* |
* dodumpdef - dump the specified definitions in the hash |
* dodumpdef - dump the specified definitions in the hash |
* table to stderr. If nothing is specified, the entire |
* table to stderr. If nothing is specified, the entire |
* hash table is dumped. |
* hash table is dumped. |
|
|
if (argc > 2) { |
if (argc > 2) { |
for (n = 2; n < argc; n++) |
for (n = 2; n < argc; n++) |
if ((p = lookup(argv[n])) != nil) |
if ((p = lookup(argv[n])) != nil) |
fprintf(stderr, dumpfmt, p->name, |
dump_one_def(p); |
p->defn); |
|
} else { |
} else { |
for (n = 0; n < HASHSIZE; n++) |
for (n = 0; n < HASHSIZE; n++) |
for (p = hashtab[n]; p != nil; p = p->nxtptr) |
for (p = hashtab[n]; p != nil; p = p->nxtptr) |
fprintf(stderr, dumpfmt, p->name, |
dump_one_def(p); |
p->defn); |
|
} |
} |
} |
} |
|
|