Skip to content

Commit

Permalink
Comparing against nothing should be done with ===
Browse files Browse the repository at this point in the history
  • Loading branch information
fingolfin committed Feb 4, 2020
1 parent 81495fa commit b4f61cc
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/GAPJulia/JuliaInterface/example/orbits.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ function bahn( element, generators, action )
for g in generators
c = action(b, g)
x = get(dict, c, nothing)
if x == nothing
if x === nothing
push!( orb, c )
dict[c] = length(orb)
end
Expand Down
2 changes: 1 addition & 1 deletion src/ccalls.jl
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ function getproperty(funcobj::GlobalsType, name::Symbol)

v = ccall(:ValGVar, Ptr{Cvoid}, (Cuint,), gvar)
v = RAW_GAP_TO_JULIA(v)
if v == nothing
if v === nothing
error("GAP variable ", name, " not bound")
end
return v
Expand Down
2 changes: 1 addition & 1 deletion src/julia_to_gap.jl
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function julia_to_gap(obj::Array{T,1}, recursive::Val{Recursive}=Val(false), rec
end
for i in 1:len
x = obj[i]
if x == nothing
if x === nothing
continue
end
if Recursive
Expand Down

0 comments on commit b4f61cc

Please sign in to comment.