My codes work in Julia 0.7.0, but when I tried to run them in Julia 1.0.5, I got the following error. It seems this error happens for multiple common Julia functions such as “findall” and etc… Any suggestions?
ERROR: TypeError: non-boolean (Int64) used in boolean context
Stacktrace:
[1] iterate at ./iterators.jl:434 [inlined]
[2] iterate at ./generator.jl:44 [inlined]
[3] grow_to!(::Array{Int64,1}, ::Base.Generator{Base.Iterators.Filter{typeof(last),Base.Iterators.Pairs{Int64,Int64,LinearIndices{1,Tuple{Base.OneTo{Int64}}},Array{Int64,1}}},typeof(first)}) at ./array.jl:674
[4] collect at ./array.jl:617 [inlined]
[5] findall(::Array{Int64,1}) at ./array.jl:2008
If it errors in v1, then you should get a warning in v0.7. Do you not see any?
Without seeing your code, I have to guess a bit, but it looks like you are calling findall on a vector of Int64, and that won’t work. What are you trying to locate in that vector? If it’s non- zero values, then you can try