Initialize current_symtab in class_init() when necessary.

If an objective-qc symbol is the first token to be read, class_init() is
called before the parser gets a chance to perform the initialization
action. However, class_init() setting current_symtab if the first
objective-qc symbol is seen in a function body would be bad.
This commit is contained in:
Bill Currie 2011-02-08 22:26:35 +09:00
parent c01f742b7b
commit da14c95bb8

View file

@ -277,6 +277,8 @@ class_init (void)
{
symbol_t *sym;
if (!current_symtab)
current_symtab = pr.symtab;
init_classes ();
init_objective_structs ();