-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Error when displaying results of methods
in REPL
#9471
Comments
Thanks for the report. Could you post the output of |
It's the latest master compiled a few hours ago julia> versioninfo()
Julia Version 0.4.0-dev+2272
Commit c9c89a4* (2014-12-26 19:30 UTC)
Platform Info:
System: Linux (x86_64-unknown-linux-gnu)
CPU: Intel(R) Core(TM) i7-4702HQ CPU @ 2.20GHz
WORD_SIZE: 64
BLAS: libblas
LAPACK: liblapack
LIBM: libm
LLVM: libLLVM-3.3 But I also remember seeing this a few days ago as well (with the master at that time). |
I can also reproduce it with d6514f4 but |
Sorry, I've just noticed that this is actually related to me defining another method for I still think it is a bug though. The simplified code that reproduce this on type T
end
function Base.show(io::Base.IO, ::Type{T})
end
println(methods(length)) There isn't any warning/error when defining that method. The error only appears when I try to print the result of |
(Hopefully it isn't very unreasonable to redefine how a custom type (the type itself) should be printed) |
I've tracked down the call chain a little bit more and it looks that it is somehow related to the compiler and I don't think I know enough to track it down further. So here is what I've observed
|
What makes even less sense is that when it throws an error on
The following code does not throw any error.......
WTF?... = = ................ |
I've also just reproduce it on the (out-of-date) version installed on x.dialup.mit.edu (0.3.1-pre+40, release-0.3/795bc31) so it shouldn't be sth wrong with my build. P.S. Anyone mind updating that version?.... |
Yes, I agree this looks like bug. |
This seems to be fixed, on |
Saw this this morning: julia> methods(append!)
# 10 methods for generic function "append!":
append!(A::Array{Bool,1}, items::BitArray{1}) at bitarray.jl:476
append!{T}(a::Array{T,1}, items::AbstractArray{T,1}) at array.jl:445
append!(B::BitArray{1}, items::BitArray{1}) at bitarray.jl:458
append!(B::BitArray{1}, items::AbstractArray{Bool,1}) at bitarray.jl:475
append!Error showing value of type MethodTable:
ERROR: type TypeConstructor has no field name
in show at show.jl:105
in print at strings/io.jl:8
in print_to_string at strings/io.jl:36
in argtype_decl at methodshow.jl:26
in arg_decl_parts at methodshow.jl:38
in show at methodshow.jl:44
in show_method_table at methodshow.jl:69
in show at methodshow.jl:82
in anonymous at show.jl:1278
in with_output_limit at /Users/jacobquinn/julia4/lib/julia/sys.dylib
in showlimited at show.jl:1277
in writemime at replutil.jl:4
in display at REPL.jl:114
in display at REPL.jl:117
in display at multimedia.jl:151
in print_response at REPL.jl:134
in print_response at REPL.jl:121
in anonymous at REPL.jl:624
in run_interface at /Users/jacobquinn/julia4/lib/julia/sys.dylib
in run_frontend at /Users/jacobquinn/julia4/lib/julia/sys.dylib
in run_repl at /Users/jacobquinn/julia4/lib/julia/sys.dylib
in _start at /Users/jacobquinn/julia4/lib/julia/sys.dylib
julia> versioninfo()
Julia Version 0.4.0
Commit 0ff703b* (2015-10-08 06:20 UTC)
Platform Info:
System: Darwin (x86_64-apple-darwin13.4.0)
CPU: Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
LAPACK: libopenblas64_
LIBM: libopenlibm
LLVM: libLLVM-3.3 |
This is fixed at least on latest master and v0.4.1. |
cool, i thought I had seen some stuff going around on it. |
@jakebolewski Do you know which commit/PR fixes this? The original issue was really sensitive to a number of things so I imagine minor tweak of random stuff can easily hide it. Ref #13306 |
There's a weird error when showing the result of
methods
function in REPL.E.g.
The text was updated successfully, but these errors were encountered: