Further factorise PASS_1 out of specific emit code.

This commit is contained in:
Damien
2013-10-05 13:37:10 +01:00
parent 415eb6f850
commit b05d707b23
13 changed files with 115 additions and 133 deletions

View File

@@ -46,10 +46,10 @@ typedef struct _scope_t {
*/
int num_locals;
int stack_size;
int unique_code_id;
uint unique_code_id;
} scope_t;
scope_t *scope_new(scope_kind_t kind, py_parse_node_t pn);
scope_t *scope_new(scope_kind_t kind, py_parse_node_t pn, uint unique_code_id);
id_info_t *scope_find_or_add_id(scope_t *scope, qstr qstr, bool *added);
id_info_t *scope_find(scope_t *scope, qstr qstr);
id_info_t *scope_find_global(scope_t *scope, qstr qstr);