diff --git a/gen/llvmhelpers.cpp b/gen/llvmhelpers.cpp index f3f7f9ba3da..fd73e201631 100644 --- a/gen/llvmhelpers.cpp +++ b/gen/llvmhelpers.cpp @@ -1055,7 +1055,7 @@ void DtoResolveVariable(VarDeclaration* vd) Logger::println("parent: null"); } - const bool isLLConst = vd->isConst() && vd->init; + const bool isLLConst = (vd->isConst() || vd->isImmutable()) && vd->init; assert(!vd->ir.initialized); vd->ir.initialized = gIR->dmodule;