Skip to content

Commit dbbaf8e

Browse files
authored
fix tests failures on Julia nightly (#492)
1 parent 38025d7 commit dbbaf8e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

test/interpret.jl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,11 @@ end
299299
# issue #76
300300
let TT = Union{UInt8, Int8}
301301
a = TT[0x0, 0x1]
302-
pa = pointer(a)
303-
@interpret unsafe_store!(pa, 0x1, 2)
302+
pa = Ptr{UInt8}(pointer(a))
303+
GC.@preserve a begin
304+
@interpret unsafe_store!(pa, 0x2, 2)
305+
end
306+
@test a == TT[0x0, 0x2]
304307
end
305308

306309
# issue #92

0 commit comments

Comments
 (0)