Skip to content
Snippets Groups Projects
Commit 5953728b authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

change julia wrapper of ivectorpair so that it doesn't lead to undefined...

change julia wrapper of ivectorpair so that it doesn't lead to undefined behavior in the case of wrong input data (cf. #629)
parent 298fd5a6
No related branches found
No related tags found
No related merge requests found
......@@ -186,8 +186,9 @@ def ivectorpair(name, value=None, python_value=None, julia_value=None):
a.python_pre = api_name + ", " + api_name_n + " = _ivectorpair(" + name + ")"
a.python_arg = api_name + ", " + api_name_n
a.julia_ctype = "Ptr{Cint}, Csize_t"
a.julia_arg = ("convert(Vector{Cint}, collect(Cint, Iterators.flatten(" + name + "))), " +
"2 * length(" + name + ")")
a.julia_pre = (api_name + " = collect(Cint, Iterators.flatten(" + name + "))\n " +
api_name_n + " = length(" + api_name + ")")
a.julia_arg = (api_name + ", " + api_name_n)
return a
def ivectorvectorint(name, value=None, python_value=None, julia_value=None):
......
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment