Skip to content

Commit 85fc364

Browse files
committed
Make launch code a little more readable.
1 parent 57ca963 commit 85fc364

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

lib/cudadrv/execution.jl

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,11 +131,10 @@ cudacall(f::F, types::Tuple, args::Vararg{Any,N}; kwargs...) where {N,F} =
131131
cudacall(f, _to_tuple_type(types), args...; kwargs...)
132132

133133
function cudacall(f::F, types::Type{T}, args::Vararg{Any,N}; kwargs...) where {T,N,F}
134-
convert_arguments(
135-
((pointers::Vararg{Any,M},) where {M}) -> launch(f, pointers...; kwargs...),
136-
types,
137-
args...
138-
)
134+
launch_closure = function (pointers::Vararg{Any,N})
135+
launch(f, pointers...; kwargs...)
136+
end
137+
convert_arguments(launch_closure, types, args...)
139138
end
140139

141140
# From `julia/base/reflection.jl`, adjusted to add specialization on `t`.

0 commit comments

Comments
 (0)