We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f3f7008 commit 42ea51bCopy full SHA for 42ea51b
test/runtests.jl
@@ -59,7 +59,7 @@ global prefer_threads::Bool = !(IS_CPU_BACKEND && "--cpuKA" in ARGS)
59
60
array_from_host(h_arr::AbstractArray, dtype=nothing) = array_from_host(BACKEND, h_arr, dtype)
61
@static if IS_CPU_BACKEND && prefer_threads
62
- function array_from_host(_, h_arr::AbstractArray, dtype=nothing)
+ function array_from_host(backend, h_arr::AbstractArray, dtype=nothing)
63
d_arr = zeros(isnothing(dtype) ? eltype(h_arr) : dtype, size(h_arr))
64
copyto!(d_arr, h_arr isa Array ? h_arr : Array(h_arr)) # Allow unmaterialised types, e.g. ranges
65
d_arr
0 commit comments