Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/exception.jl
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,9 @@ function pyraise(e::PyError, ::Vector = [])
ccall((@pysym :PyErr_Restore), Cvoid, (PyPtr, PyPtr, PyPtr),
e.T, e.val, e.traceback)
# refs were stolen
setfield!(e.T, :o, C_NULL)
setfield!(e.val, :o, C_NULL)
setfield!(e.traceback, :o, C_NULL)
setfield!(e.T, :o, PyPtr_NULL)
setfield!(e.val, :o, PyPtr_NULL)
setfield!(e.traceback, :o, PyPtr_NULL)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are all PyObject so .o has to be of type PyPtr.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine, but I thought setfield! automatically called convert (JuliaLang/julia#16195)?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like that's not the case JuliaLang/julia#16195 (comment)

end

"""
Expand Down