diff options
Diffstat (limited to 'src/scope.c')
| -rw-r--r-- | src/scope.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/scope.c b/src/scope.c index 448c883..198e2c0 100644 --- a/src/scope.c +++ b/src/scope.c @@ -185,7 +185,7 @@ int scope_add_var(struct scope *scope, struct ast *var) int scope_add_type(struct scope *scope, char *id, struct ast *type) { - struct ast *exists = file_scope_find_type(scope, id); + struct ast *exists = scope_find_type(scope, id); if (exists) { semantic_error(scope->fctx, type, "type redefined"); semantic_info(scope->fctx, exists, "previously here"); |
