Skip to content

Commit 235860a

Browse files
authored
Clarify 3-4-0-preview2 release notes (#3380)
The part about chilled string has changed since preview1. And I also think we should call out the Hash#inspect change.
1 parent 3e7096c commit 235860a

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

en/news/_posts/2024-10-07-ruby-3-4-0-preview2-released.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ Switch the default parser from parse.y to Prism. [[Feature #20564]]
1616

1717
## Language changes
1818

19-
* String literals in files without a `frozen_string_literal` comment now behave
20-
as if they were frozen. If they are mutated a deprecation warning is emitted.
19+
* String literals in files without a `frozen_string_literal` comment now emit a deprecation warning
20+
when they are mutated.
2121
These warnings can be enabled with `-W:deprecated` or by setting `Warning[:deprecated] = true`.
2222
To disable this change, you can run Ruby with the `--disable-frozen-string-literal`
2323
command line argument. [[Feature #20205]]
@@ -66,6 +66,9 @@ Note: Excluding feature bug fixes.
6666
from test.rb:2:in `<main>'
6767
```
6868

69+
* `Hash#inspect` rendering has changed. [[Bug #20433]]
70+
* Symbol keys are displayed using the modern symbol key syntax: `"{user: 1}"`
71+
* Other keys now have spaces around `=>`: `'{"user" => 1}'`, while previously they didn't: `'{"user"=>1}'`
6972

7073
## C API updates
7174

@@ -142,3 +145,4 @@ and is used all over the world especially for web development.
142145
[Feature #20265]: https://bugs.ruby-lang.org/issues/20265
143146
[Feature #20429]: https://bugs.ruby-lang.org/issues/20429
144147
[Feature #20564]: https://bugs.ruby-lang.org/issues/20564
148+
[Bug #20433]: https://bugs.ruby-lang.org/issues/20433

0 commit comments

Comments
 (0)