Skip to content

Commit 299f440

Browse files
committed
Add a ReinterpretArray test
1 parent 854a4b8 commit 299f440

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/runtests.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -544,6 +544,13 @@ end
544544
@test @inferred(ArrayInterface.offsets(Op)) === (11, 4, 8)
545545

546546
@test @inferred(ArrayInterface.offsets((1,2,3))) === (StaticInt(1),)
547+
548+
if VERSION v"1.6.0-DEV.1581"
549+
colors = [(R = rand(), G = rand(), B = rand()) for i 1:100];
550+
551+
colormat = reinterpret(reshape, Float64, colors)
552+
@test @inferred(ArrayInterface.strides(colormat)) === (StaticInt(1), StaticInt(3))
553+
end
547554
end
548555

549556
@test ArrayInterface.can_avx(ArrayInterface.can_avx) == false

0 commit comments

Comments
 (0)