diff --git a/src/compiler/sema_name_resolution.c b/src/compiler/sema_name_resolution.c index 451a8ac4a..764956e34 100644 --- a/src/compiler/sema_name_resolution.c +++ b/src/compiler/sema_name_resolution.c @@ -319,7 +319,15 @@ static Decl *sema_find_decl_in_global_new(CompilationUnit *unit, DeclTable *tabl maybe_decl = candidate; continue; } - if (!ambiguous) + if (ambiguous) + { + if (candidate->is_autoimport && !decl->is_autoimport) + { + ambiguous = NULL; + decl = candidate; + } + } + else { ambiguous = decl; decl = candidate; diff --git a/src/compiler/sema_passes.c b/src/compiler/sema_passes.c index fd14fd2e4..99c71d8fc 100644 --- a/src/compiler/sema_passes.c +++ b/src/compiler/sema_passes.c @@ -317,10 +317,6 @@ void sema_process_includes(CompilationUnit *unit) void sema_analysis_pass_register_global_declarations(Module *module) { DEBUG_LOG("Pass: Register globals for module '%s'.", module->name->module); - if (str_eq("std::core::env", module->name->module)) - { - printf(""); - } VECEACH(module->units, index) { CompilationUnit *unit = module->units[index]; diff --git a/src/version.h b/src/version.h index 0f61eb8af..f8bbe3f47 100644 --- a/src/version.h +++ b/src/version.h @@ -1 +1 @@ -#define COMPILER_VERSION "0.4.633" \ No newline at end of file +#define COMPILER_VERSION "0.4.634" \ No newline at end of file