mirror of
https://github.com/odin-lang/Odin.git
synced 2026-02-12 14:23:33 +00:00
Make Entity.parent_proc_decl atomic
This commit is contained in:
@@ -2215,8 +2215,10 @@ gb_internal lbValue lb_build_builtin_proc(lbProcedure *p, Ast *expr, TypeAndValu
|
||||
Entity *e = entity_of_node(ident);
|
||||
GB_ASSERT(e != nullptr);
|
||||
|
||||
if (e->parent_proc_decl != nullptr && e->parent_proc_decl->entity != nullptr) {
|
||||
procedure = e->parent_proc_decl->entity.load()->token.string;
|
||||
DeclInfo *parent_proc_decl = e->parent_proc_decl.load(std::memory_order_relaxed);
|
||||
if (parent_proc_decl != nullptr &&
|
||||
parent_proc_decl->entity != nullptr) {
|
||||
procedure = parent_proc_decl->entity.load()->token.string;
|
||||
} else {
|
||||
procedure = str_lit("");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user