mirror of
https://github.com/odin-lang/Odin.git
synced 2026-06-01 16:31:13 +00:00
Allow @(rodata) on @(static) variables
This commit is contained in:
@@ -1850,7 +1850,9 @@ gb_internal void lb_build_static_variables(lbProcedure *p, AstValueDecl *vd) {
|
||||
LLVMSetInitializer(global, LLVMConstNull(lb_type(p->module, e->type)));
|
||||
if (value.value != nullptr) {
|
||||
LLVMSetInitializer(global, value.value);
|
||||
} else {
|
||||
}
|
||||
if (e->Variable.is_rodata) {
|
||||
LLVMSetGlobalConstant(global, true);
|
||||
}
|
||||
if (e->Variable.thread_local_model != "") {
|
||||
LLVMSetThreadLocal(global, true);
|
||||
|
||||
Reference in New Issue
Block a user