mirror of
https://github.com/odin-lang/Odin.git
synced 2026-10-11 15:27:06 -04:00
Allow map indices to be referenced &m[key] and return a valid pointer if it exists otherwise nil
This commit is contained in:
1 parent
d57fbf48f0
commit
da703edbf4
2 files changed
+18
-2
No files matched your search
+4
-1
@@ -1648,8 +1648,11 @@ bool check_is_not_addressable(CheckerContext *c, Operand *o) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
||||
}
|
||||
if (o->mode == Addressing_MapIndex) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (o->mode != Addressing_Variable) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user