Skip to content

Commit

Permalink
julia 1.10: add cast for jl_apply_tuple_type(_v)
Browse files Browse the repository at this point in the history
this was changed in JuliaLang/julia#49111

for older julia versions this cast should be a no-op
  • Loading branch information
benlorenz authored and barche committed May 3, 2023
1 parent ff88912 commit 4c1d2bd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions include/jlcxx/tuple.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ namespace detail
{
concrete_types[i] = jl_typeof(args[i]);
}
concrete_dt = jl_apply_tuple_type_v(concrete_types, tup_sz);
concrete_dt = (jl_datatype_t*) jl_apply_tuple_type_v(concrete_types, tup_sz);
JL_GC_POP();
}
result = jl_new_structv(concrete_dt, args, tup_sz);
Expand Down Expand Up @@ -87,7 +87,7 @@ template<typename... TypesT> struct julia_type_factory<std::tuple<TypesT...>, Tu
jl_datatype_t* result = nullptr;
JL_GC_PUSH1(&params);
params = jl_svec(sizeof...(TypesT), jlcxx::julia_type<TypesT>()...);
result = jl_apply_tuple_type(params);
result = (jl_datatype_t*) jl_apply_tuple_type(params);
JL_GC_POP();
return result;
}
Expand Down Expand Up @@ -134,7 +134,7 @@ struct julia_type_factory<NTuple<N,T>>
create_if_not_exists<T>();
jl_value_t* t[2] = { ::jlcxx::julia_type<T>(), ::jlcxx::julia_type<N>() };
jl_value_t* type = apply_type((jl_value_t*)jl_vararg_type, t, 2);
return jl_apply_tuple_type_v(&type, 1);
return (jl_datatype_t*) jl_apply_tuple_type_v(&type, 1);
}
};

Expand Down

0 comments on commit 4c1d2bd

Please sign in to comment.