mirror of
https://github.com/odin-lang/Odin.git
synced 2025-12-30 01:44:36 +00:00
Add mutex guards for signature scopes
This commit is contained in:
@@ -4021,10 +4021,12 @@ void check_did_you_mean_scope(String const &name, Scope *scope) {
|
||||
DidYouMeanAnswers d = did_you_mean_make(heap_allocator(), scope->elements.entries.count, name);
|
||||
defer (did_you_mean_destroy(&d));
|
||||
|
||||
mutex_lock(&scope->mutex);
|
||||
for_array(i, scope->elements.entries) {
|
||||
Entity *e = scope->elements.entries[i].value;
|
||||
did_you_mean_append(&d, e->token.string);
|
||||
}
|
||||
mutex_unlock(&scope->mutex);
|
||||
check_did_you_mean_print(&d);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user