Skip to content

Conversation

@rfourquet
Copy link
Member

In #53959, an new LimitIO object was defined to display at the REPL, but it hid the displaysize of the underlying io. This patch just forwards this information.

Before:

julia> Dict(1 => fill(UInt(0), 4))
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x000000000…

After:

Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000]

In #53959, an new `LimitIO` object was defined to display at the REPL, but it hid
the displaysize of the underlying `io`. This patch just forwards this information.

Before:
```
julia> Dict(1 => fill(UInt(0), 4))
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x000000000…
```
After:
```
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000]
```
@rfourquet rfourquet added bugfix This change fixes an existing bug display and printing Aesthetics and correctness of printed representations of objects. backport 1.12 Change should be backported to release-1.12 labels Apr 15, 2025
@KristofferC KristofferC mentioned this pull request Apr 16, 2025
51 tasks
@KristofferC KristofferC mentioned this pull request Apr 29, 2025
53 tasks
@rfourquet
Copy link
Member Author

rfourquet commented May 2, 2025

@ericphanson does this fix looks good to you?

@ericphanson
Copy link
Contributor

I don't really know the displaysize system, should it forward to just Base.displaysize instead of _displaysize?

@vtjnash
Copy link
Member

vtjnash commented May 2, 2025

_displaysize is just a local type-asserted call to displaysize, which is fine

@vtjnash vtjnash merged commit 35bfba9 into master May 2, 2025
10 checks passed
@vtjnash vtjnash deleted the rf/repl-displaysize branch May 2, 2025 15:23
KristofferC pushed a commit that referenced this pull request May 5, 2025
In #53959, an new `LimitIO` object was defined to display at the REPL,
but it hid the displaysize of the underlying `io`. This patch just
forwards this information.

Before:
```
julia> Dict(1 => fill(UInt(0), 4))
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x000000000…
```
After:
```
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000]
```

(cherry picked from commit 35bfba9)
@KristofferC KristofferC removed the backport 1.12 Change should be backported to release-1.12 label May 9, 2025
charleskawczynski pushed a commit to charleskawczynski/julia that referenced this pull request May 12, 2025
)

In JuliaLang#53959, an new `LimitIO` object was defined to display at the REPL,
but it hid the displaysize of the underlying `io`. This patch just
forwards this information.

Before:
```
julia> Dict(1 => fill(UInt(0), 4))
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x000000000…
```
After:
```
Dict{Int64, Vector{UInt64}} with 1 entry:
  1 => [0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000]
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix This change fixes an existing bug display and printing Aesthetics and correctness of printed representations of objects.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants