Skip to content

Commit 2b7705f

Browse files
authored
define 2-arg Base.hash
1 parent b4528b7 commit 2b7705f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Py.jl

+1-1
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ end
366366

367367
Base.in(v, x::Py) = pycontains(x, v)
368368

369-
Base.hash(x::Py) = reinterpret(UInt, Int(pyhash(x)))
369+
Base.hash(x::Py, h::UInt) = reinterpret(UInt, Int(pyhash(x))) - 3h
370370

371371
(f::Py)(args...; kwargs...) = pycall(f, args...; kwargs...)
372372

0 commit comments

Comments
 (0)