mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-27 07:51:49 -07:00
Make static an attribute rather than a keyword prefix
This commit is contained in:
+10
-1
@@ -8166,7 +8166,16 @@ void ir_build_stmt_internal(irProcedure *proc, Ast *node) {
|
||||
if (vd->is_mutable) {
|
||||
irModule *m = proc->module;
|
||||
|
||||
if (vd->is_static) {
|
||||
bool is_static = false;
|
||||
if (vd->names.count > 0) {
|
||||
Entity *e = entity_of_ident(vd->names[0]);
|
||||
if (e->flags & EntityFlag_Static) {
|
||||
// NOTE(bill): If one of the entities is static, they all are
|
||||
is_static = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (is_static) {
|
||||
for_array(i, vd->names) {
|
||||
irValue *value = nullptr;
|
||||
if (vd->values.count > 0) {
|
||||
|
||||
Reference in New Issue
Block a user