Skip to content

Commit

Permalink
fix argtypes of kwsorter when on the heap (#35995)
Browse files Browse the repository at this point in the history
  • Loading branch information
vtjnash committed Jun 2, 2020
1 parent 0164101 commit 8c8f7a6
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/builtins.c
Original file line number Diff line number Diff line change
Expand Up @@ -1038,18 +1038,19 @@ JL_CALLABLE(jl_f_invoke_kwsorter)
size_t i, nt = jl_nparams(argtypes) + 2;
if (nt < jl_page_size/sizeof(jl_value_t*)) {
jl_value_t **types = (jl_value_t**)alloca(nt*sizeof(jl_value_t*));
types[0] = (jl_value_t*)jl_namedtuple_type; types[1] = jl_typeof(func);
for(i=2; i < nt; i++)
types[i] = jl_tparam(argtypes,i-2);
types[0] = (jl_value_t*)jl_namedtuple_type;
types[1] = jl_typeof(func);
for (i = 2; i < nt; i++)
types[i] = jl_tparam(argtypes, i - 2);
argtypes = (jl_value_t*)jl_apply_tuple_type_v(types, nt);
}
else {
jl_svec_t *types = jl_alloc_svec_uninit(nt);
JL_GC_PUSH1(&types);
jl_svecset(types, 0, jl_array_any_type);
jl_svecset(types, 0, jl_namedtuple_type);
jl_svecset(types, 1, jl_typeof(func));
for(i=2; i < nt; i++)
jl_svecset(types, i, jl_tparam(argtypes,i-2));
for (i = 2; i < nt; i++)
jl_svecset(types, i, jl_tparam(argtypes, i - 2));
argtypes = (jl_value_t*)jl_apply_tuple_type(types);
JL_GC_POP();
}
Expand Down

2 comments on commit 8c8f7a6

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Executing the daily package evaluation, I will reply here when finished:

@nanosoldier runtests(ALL, isdaily = true)

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your package evaluation job has completed - possible new issues were detected. A full report can be found here. cc @maleadt

Please sign in to comment.