Cleanup iterators
This commit is contained in:
@@ -740,8 +740,8 @@ parse_enum(Token *pos){
|
||||
CORE_Static void
|
||||
add_implicit_import(Ast_Scope *scope, Ast_Scope *to_add){
|
||||
B32 found = false;
|
||||
Iter(&scope->implicit_imports){
|
||||
if(it.item[0] == to_add){
|
||||
For(scope->implicit_imports){
|
||||
if(it == to_add){
|
||||
found = true;
|
||||
break;
|
||||
}
|
||||
@@ -757,8 +757,7 @@ CORE_Static Ast_File *
|
||||
register_ast_file(Token *pos, String absolute_file_path, Ast_Module *module, B32 global_implicit_load){
|
||||
Ast_File *file = 0;
|
||||
|
||||
Iter(&pctx->files){
|
||||
Ast_File *it_file = it.item[0];
|
||||
For_Named(pctx->files, it_file){
|
||||
if(string_compare(it_file->absolute_file_path, absolute_file_path)){
|
||||
if(module == it_file->module){
|
||||
log_trace("%Q :: Returning registered file: %Q\n", module->absolute_file_path, absolute_file_path);
|
||||
|
||||
Reference in New Issue
Block a user