Closed
Description
I'm trying to develop the Emacs inferior-julia to have clickable paths in stacktraces. One issue I'm having is that errors from stdlib don't have their correct path shown, e.g.:
julia> rand(3) * rand(4,5)
ERROR: DimensionMismatch("A has dimensions (3,1) but B has dimensions (4,5)")
Stacktrace:
[1] gemm_wrapper!(::Array{Float64,2}, ::Char, ::Char, ::Array{Float64,2}, ::Array{Float64,2}, ::Bool, ::Bool) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/LinearAlgebra/src/matmul.jl:569
[2] mul! at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/LinearAlgebra/src/matmul.jl:169 [inlined]
[3] mul! at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/LinearAlgebra/src/matmul.jl:208 [inlined]
[4] * at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/LinearAlgebra/src/matmul.jl:160 [inlined]
[5] *(::Array{Float64,1}, ::Array{Float64,2}) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4/LinearAlgebra/src/matmul.jl:63
[6] top-level scope at REPL[1]:1
I'm assuming that /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.4
is the directory that the stdlib was in while Julia was being built. On the other hand, packages installed with Pkg
show the correct absolute path even though it's different on each machine, e.g.:
julia> using Unitful; uconvert(u"ft", 1u"inch^2")
ERROR: DimensionError: ft and inch^2 are not dimensionally compatible.
Stacktrace:
[1] #s56#151 at /home/adam/.julia/packages/Unitful/dZYmO/src/conversion.jl:12 [inlined]
[2] #s56#151(::Any, ::Any, ::Any) at ./none:0
[3] (::Core.GeneratedFunctionStub)(::Any, ::Vararg{Any,N} where N) at ./boot.jl:526
[4] uconvert(::Unitful.FreeUnits{(ft,),𝐋,nothing}, ::Quantity{Int64,𝐋^2,Unitful.FreeUnits{(inch^2,),𝐋^2,nothing}}) at /home/adam/.julia/packages/Unitful/dZYmO/src/conversion.jl:74
[5] top-level scope at REPL[2]:1