tccasm: Unify C and asm symbol table

This makes the asm symbols use the same members as the C symbols
for global decls, e.g. using the ELF symbol to hold offset and
section.  That allows us to use only one symbol table for C and
asm symbols and to get rid of hacks to synch between them.

We still need some special handling for symbols that come purely
from asm sources.
This commit is contained in:
Michael Matz
2017-11-27 04:03:03 +01:00
parent 3494e5de3a
commit 9e0d23cc47
8 changed files with 164 additions and 188 deletions

View File

@@ -432,7 +432,6 @@ static TokenSym *tok_alloc_new(TokenSym **pts, const char *str, int len)
ts->sym_label = NULL;
ts->sym_struct = NULL;
ts->sym_identifier = NULL;
ts->sym_asm_label = NULL;
ts->len = len;
ts->hash_next = NULL;
memcpy(ts->str, str, len);