Skip to content

Commit c5f3c74

Browse files
authored
Force specialization of dimension_mismatch_fail() on type argument. (#1245)
* Force specialization of dimension_mismatch_fail() on type argument. This should improve GPU-compatibility. Original discussion: https://discourse.julialang.org/t/problems-with-linearalgebra-functions-within-kernelabstractions-and-cuda/97566/5 * bump patch version -> 1.9.3
1 parent ff8ed9b commit c5f3c74

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Project.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "StaticArrays"
22
uuid = "90137ffa-7385-5640-81b9-e52037218182"
3-
version = "1.9.2"
3+
version = "1.9.3"
44

55
[deps]
66
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"

src/convert.jl

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ AbstractArray{T,N}(sa::StaticArray{S,U,N}) where {S,T,U,N} = similar_type(typeof
192192
# Constructing a Tuple from a StaticArray
193193
@inline Tuple(a::StaticArray) = unroll_tuple(a, Length(a))
194194

195-
@noinline function dimension_mismatch_fail(SA::Type, a::AbstractArray)
195+
@noinline function dimension_mismatch_fail(::Type{SA}, a::AbstractArray) where {SA <: StaticArray}
196196
throw(DimensionMismatch("expected input array of length $(length(SA)), got length $(length(a))"))
197197
end
198198

0 commit comments

Comments
 (0)