Store the initializer expression in the def.

Initially, this will be used for collecting the targets of a jumpb
instruction.
This commit is contained in:
Bill Currie 2012-11-03 18:12:44 +09:00
parent d7177a78e9
commit ffa08a99c2
2 changed files with 2 additions and 0 deletions

View File

@ -44,6 +44,7 @@ typedef struct def_s {
struct def_s *alias;
struct reloc_s *relocs; ///< for relocations
struct expr_s *initializer; ///< initialer expression
unsigned offset_reloc:1; ///< use *_def_ofs relocs
unsigned initialized:1;

View File

@ -527,4 +527,5 @@ initialize_def (symbol_t *sym, type_t *type, expr_t *init, defspace_t *space,
sym->s.def->nosave = 1;
}
}
sym->s.def->initializer = init;
}