Skip to content

Commit

Permalink
Root the function object in jlcall
Browse files Browse the repository at this point in the history
  • Loading branch information
yuyichao committed Dec 11, 2015
1 parent 7d885e7 commit c1005bf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/codegen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3105,6 +3105,7 @@ static jl_cgval_t emit_call(jl_value_t **args, size_t arglen, jl_codectx_t *ctx,
}
else {
theF = literal_pointer_val((jl_value_t*)f);
jl_add_linfo_root(ctx->linfo, (jl_value_t*)f);
result = emit_call_function_object(f, theF, theFptr, true, args-1, nargs+1, ctx);
}
}
Expand Down Expand Up @@ -3132,6 +3133,7 @@ static jl_cgval_t emit_call(jl_value_t **args, size_t arglen, jl_codectx_t *ctx,
}
else {
theF = literal_pointer_val((jl_value_t*)f);
jl_add_linfo_root(ctx->linfo, (jl_value_t*)f);
}
result = emit_call_function_object(f, theF, theFptr, specialized, args, nargs, ctx);
}
Expand Down

0 comments on commit c1005bf

Please sign in to comment.