mirror of https://github.com/exaloop/codon.git
Fix globals in JIT
parent
010fa3b347
commit
7655e09e83
|
@ -154,7 +154,7 @@ StmtPtr SimplifyVisitor::transformAssignment(ExprPtr lhs, ExprPtr rhs, ExprPtr t
|
|||
|
||||
// Register all toplevel variables as global in JIT mode
|
||||
bool isGlobal =
|
||||
(ctx->cache->isJit && ctx->isGlobal() && getStaticGeneric(type.get()) != 0) ||
|
||||
(ctx->cache->isJit && ctx->isGlobal() && getStaticGeneric(type.get()) == 0) ||
|
||||
(canonical == VAR_ARGV);
|
||||
if (isGlobal && !getStaticGeneric(type.get()))
|
||||
ctx->cache->addGlobal(canonical);
|
||||
|
|
Loading…
Reference in New Issue