Skip to content

Commit

Permalink
fixup! Test that serialization of ForeignObj fail
Browse files Browse the repository at this point in the history
  • Loading branch information
vchuravy committed Nov 25, 2022
1 parent 4e53bd2 commit 4d1fd2c
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 0 deletions.
14 changes: 14 additions & 0 deletions test/gcext/DependsOnForeign/Manifest.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# This file is machine-generated - editing it directly is not advised

julia_version = "1.8.3"
manifest_format = "2.0"
project_hash = "e7199d961a5f4ebad68a3deaf5beaa7406a0afcb"

[[deps.Foreign]]
deps = ["Libdl"]
path = "../Foreign"
uuid = "de1f6f7a-d7b3-400f-91c2-33f248ee89c4"
version = "0.1.0"

[[deps.Libdl]]
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
6 changes: 6 additions & 0 deletions test/gcext/DependsOnForeign/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name = "DependsOnForeign"
uuid = "4b0716e0-dfb5-4e00-8b44-e2685a41517f"
version = "0.1.0"

[deps]
Foreign = "de1f6f7a-d7b3-400f-91c2-33f248ee89c4"
14 changes: 14 additions & 0 deletions test/gcext/DependsOnForeign/src/DependsOnForeign.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
module DependsOnForeign

using Foreign

f(obj::FObj) = Base.pointer_from_objref(obj)
precompile(f, (FObj,))

const FObjRef = Ref{FObj}()

function __init__()
FObjRef[] = FObj()
end

end # module DependsOnForeign
14 changes: 14 additions & 0 deletions test/gcext/ForeignObjSerialization/Manifest.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# This file is machine-generated - editing it directly is not advised

julia_version = "1.8.3"
manifest_format = "2.0"
project_hash = "e7199d961a5f4ebad68a3deaf5beaa7406a0afcb"

[[deps.Foreign]]
deps = ["Libdl"]
path = "../Foreign"
uuid = "de1f6f7a-d7b3-400f-91c2-33f248ee89c4"
version = "0.1.0"

[[deps.Libdl]]
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
6 changes: 6 additions & 0 deletions test/gcext/ForeignObjSerialization/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name = "ForeignObjSerialization"
uuid = "2c015d96-a6ca-42f0-bc68-f9090de6bc2c"
version = "0.1.0"

[deps]
Foreign = "de1f6f7a-d7b3-400f-91c2-33f248ee89c4"
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module ForeignObjSerialization

using Foreign
const FObjRef = Ref{FObj}(FObj())

end # module ForeignObjSerialization

0 comments on commit 4d1fd2c

Please sign in to comment.