-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
Closed
Closed
Copy link
Labels
bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behaviordisplay and printingAesthetics and correctness of printed representations of objects.Aesthetics and correctness of printed representations of objects.regressionRegression in behavior compared to a previous versionRegression in behavior compared to a previous version
Description
julia> primitive type UInt24 24 end
julia> a = reinterpret(UInt24, UInt8[1, 0, 0, 2, 0, 0, 3, 0, 0, 4, 0, 0])
4-element reinterpret(UInt24, ::Vector{UInt8}):
UInt24(0x000001)
UInt24(0x000002)
UInt24(0x000003)
UInt24(0x000004)
julia> a[1]
UInt24(0x000001)
julia> a[2]
julia> a[3]
UInt24(0x000003)
julia> a[4]
One surprising thing is that if you re-eval a REPL.print_response
method, then everything is again printed as expected:
julia> @eval REPL function print_response(errio::IO, @nospecialize(response), show_value::Bool, have_color::Bool, specialdisplay::Union{AbstractDisplay,Nothing}=nothing)
# ... cf. link above
end;
julia> a[2]
UInt24(0x000002)
This was not an issue in Julia 1.5.
Metadata
Metadata
Assignees
Labels
bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behaviordisplay and printingAesthetics and correctness of printed representations of objects.Aesthetics and correctness of printed representations of objects.regressionRegression in behavior compared to a previous versionRegression in behavior compared to a previous version