Skip to content

Update Hash#inspect logic for multibyte keys#8908

Merged
headius merged 2 commits intojruby:masterfrom
headius:inspect_hash_keys
Jul 11, 2025
Merged

Update Hash#inspect logic for multibyte keys#8908
headius merged 2 commits intojruby:masterfrom
headius:inspect_hash_keys

Conversation

@headius
Copy link
Member

@headius headius commented Jul 10, 2025

Update logic from the C impl for inspecting a Hash with symbol keys that are valid multibyte literal symbol characters.

Fixes #8783.

headius added 2 commits July 10, 2025 12:26
Symbol inspect was updated some time ago to avoid escaping multi-
byte characters that do not interfere with emitting a value literal
symbol, but our Hash#inspect logic did not get the same updates.
As a result it continued to escape all but the most trivial symbol
keys, leading to issues like jruby#8783. This updates the
relevant logic based on the C implementation.

Fixes jruby#8783
@headius headius added this to the JRuby 10.0.1.0 milestone Jul 10, 2025
@headius headius merged commit a80335b into jruby:master Jul 11, 2025
71 of 72 checks passed
@headius headius deleted the inspect_hash_keys branch July 11, 2025 00:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Failure in ruby/pp CI in JRuby 10

1 participant