-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Access to undefined reference when using KrylovKit on a non-concrete vector #69
Comments
Do I infer correctly from the stack trace that this is actually a Julia Base (or actually |
Yeah I find that quite strange. I couldn't reproduce the bug by just calling |
Yeah, so if I make an julia> v = Vector{Complex}(undef, 2)
2-element Vector{Complex}:
#undef
#undef
julia> rmul!(v, false)
ERROR: UndefRefError: access to undefined reference
Stacktrace:
[1] getindex
@ ./essentials.jl:13 [inlined]
[2] macro expansion
@ ~/julia/usr/share/julia/stdlib/v1.9/LinearAlgebra/src/generic.jl:183 [inlined]
[3] macro expansion
@ ./simdloop.jl:77 [inlined]
[4] rmul!(X::Vector{Complex}, s::Bool)
@ LinearAlgebra ~/julia/usr/share/julia/stdlib/v1.9/LinearAlgebra/src/generic.jl:182
[5] top-level scope
@ REPL[2]:1 So maybe the fix would just be to throw a more helpful error before actually hitting |
The problem is that the implementation tries to be completely agnostic about the type of vector. So checking for |
Someone on Slack ran into this issue when they accidentally ran
instead of using a concrete type.
Here's a MWE:
The text was updated successfully, but these errors were encountered: