{
int i;
MSymbol sym, next;
+ int freed_symbols = 0;
for (i = 0; i < SYMBOL_TABLE_SIZE; i++)
for (sym = symbol_table[i]; sym; sym = sym->next)
M17N_OBJECT_UNREF (sym->plist.next);
}
for (i = 0; i < SYMBOL_TABLE_SIZE; i++)
- for (sym = symbol_table[i]; sym; sym = next)
- {
- next = sym->next;
- free (sym->name);
- free (sym);
- }
+ {
+ for (sym = symbol_table[i]; sym; sym = next)
+ {
+ next = sym->next;
+ free (sym->name);
+ free (sym);
+ freed_symbols++;
+ }
+ symbol_table[i] = NULL;
+ }
+ if (mdebug__flag & MDEBUG_FINI)
+ fprintf (stderr, "%16s %7d %7d %7d\n", "Symbol",
+ num_symbols, freed_symbols, num_symbols - freed_symbols);
+ num_symbols = 0;
}