rss_feed_plus 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rspec +3 -0
- data/.rubocop.yml +11 -0
- data/CHANGELOG.md +5 -0
- data/LICENSE.txt +21 -0
- data/README.md +82 -0
- data/Rakefile +6 -0
- data/lib/rss_feed/dynamic_object.rb +58 -0
- data/lib/rss_feed/feed/base.rb +41 -0
- data/lib/rss_feed/feed/channel.rb +47 -0
- data/lib/rss_feed/feed/item.rb +42 -0
- data/lib/rss_feed/feed/namespace.rb +75 -0
- data/lib/rss_feed/object.rb +47 -0
- data/lib/rss_feed/parser.rb +209 -0
- data/lib/rss_feed/version.rb +3 -0
- data/lib/rss_feed.rb +5 -0
- data/parser.rb +29 -0
- data/rbs_collection.lock.yaml +84 -0
- data/rbs_collection.yaml +19 -0
- data/rss_example/news.rss +1843 -0
- data/rss_example/prog.xml +84 -0
- data/rss_feed.gemspec +47 -0
- data/sig/dynamic_object.rbs +9 -0
- data/sig/rss_feed/feed/base.rbs +18 -0
- data/sig/rss_feed/feed/channel.rbs +15 -0
- data/sig/rss_feed/feed/item.rbs +15 -0
- data/sig/rss_feed/feed/namespace.rbs +21 -0
- data/sig/rss_feed/parser.rbs +51 -0
- data/sig/rss_feeds.rbs +4 -0
- metadata +83 -0
@@ -0,0 +1,1843 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
|
3
|
+
|
4
|
+
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
|
5
|
+
<channel>
|
6
|
+
<title>Ruby News</title>
|
7
|
+
<link>https://www.ruby-lang.org/en/feeds/news.rss</link>
|
8
|
+
<language>en-US</language>
|
9
|
+
<ttl>40</ttl>
|
10
|
+
<description>The latest news from ruby-lang.org.</description>
|
11
|
+
|
12
|
+
<item>
|
13
|
+
<title>CVE-2024-27281: RCE vulnerability with .rdoc_options in RDoc</title>
|
14
|
+
<description><p>We have released the RDoc gem version 6.3.4.1, 6.4.1.1, 6.5.1.1 and 6.6.3.1 that have a security fix for a RCE vulnerability.
|
15
|
+
This vulnerability has been assigned the CVE identifier <a href="https://www.cve.org/CVERecord?id=CVE-2024-27281">CVE-2024-27281</a>.</p>
|
16
|
+
|
17
|
+
<h2>Details</h2>
|
18
|
+
|
19
|
+
<p>An issue was discovered in RDoc 6.3.3 through 6.6.2, as distributed in Ruby 3.x through 3.3.0.</p>
|
20
|
+
|
21
|
+
<p>When parsing <code class="language-plaintext highlighter-rouge">.rdoc_options</code> (used for configuration in RDoc) as a YAML file, object injection and resultant remote code execution are possible because there are no restrictions on the classes that can be restored.</p>
|
22
|
+
|
23
|
+
<p>When loading the documentation cache, object injection and resultant remote code execution are also possible if there were a crafted cache.</p>
|
24
|
+
|
25
|
+
<h2>Recommended action</h2>
|
26
|
+
|
27
|
+
<p>We recommend to update the RDoc gem to version 6.6.3.1 or later. In order to ensure compatibility with bundled version in older Ruby series, you may update as follows instead:</p>
|
28
|
+
|
29
|
+
<ul>
|
30
|
+
<li>For Ruby 3.0 users: Update to <code class="language-plaintext highlighter-rouge">rdoc</code> 6.3.4.1</li>
|
31
|
+
<li>For Ruby 3.1 users: Update to <code class="language-plaintext highlighter-rouge">rdoc</code> 6.4.1.1</li>
|
32
|
+
<li>For Ruby 3.2 users: Update to <code class="language-plaintext highlighter-rouge">rdoc</code> 6.5.1.1</li>
|
33
|
+
</ul>
|
34
|
+
|
35
|
+
<p>You can use <code class="language-plaintext highlighter-rouge">gem update rdoc</code> to update it. If you are using bundler, please add <code class="language-plaintext highlighter-rouge">gem "rdoc", "&gt;= 6.6.3.1"</code> to your <code class="language-plaintext highlighter-rouge">Gemfile</code>.</p>
|
36
|
+
|
37
|
+
<p>Note: 6.3.4, 6.4.1, 6.5.1 and 6.6.3 have a incorrect fix. We recommend to upgrade 6.3.4.1, 6.4.1.1, 6.5.1.1 and 6.6.3.1 instead of them.</p>
|
38
|
+
|
39
|
+
<h2>Affected versions</h2>
|
40
|
+
|
41
|
+
<ul>
|
42
|
+
<li>Ruby 3.0.6 or lower</li>
|
43
|
+
<li>Ruby 3.1.4 or lower</li>
|
44
|
+
<li>Ruby 3.2.3 or lower</li>
|
45
|
+
<li>Ruby 3.3.0</li>
|
46
|
+
<li>RDoc gem 6.3.3 or lower, 6.4.0 through 6.6.2 without the patch versions (6.3.4, 6.4.1, 6.5.1)</li>
|
47
|
+
</ul>
|
48
|
+
|
49
|
+
<h2>Credits</h2>
|
50
|
+
|
51
|
+
<p>Thanks to <a href="https://hackerone.com/ooooooo_q?type=user">ooooooo_q</a> for discovering this issue.</p>
|
52
|
+
|
53
|
+
<h2>History</h2>
|
54
|
+
|
55
|
+
<ul>
|
56
|
+
<li>Originally published at 2024-03-21 4:00:00 (UTC)</li>
|
57
|
+
</ul>
|
58
|
+
|
59
|
+
<p>Posted by hsbt on 21 Mar 2024</p></description>
|
60
|
+
<pubDate>Thu, 21 Mar 2024 04:00:00 +0000</pubDate>
|
61
|
+
<guid>https://www.ruby-lang.org/en/news/2024/03/21/rce-rdoc-cve-2024-27281/</guid>
|
62
|
+
<link>https://www.ruby-lang.org/en/news/2024/03/21/rce-rdoc-cve-2024-27281/</link>
|
63
|
+
</item>
|
64
|
+
|
65
|
+
<item>
|
66
|
+
<title>CVE-2024-27280: Buffer overread vulnerability in StringIO</title>
|
67
|
+
<description><p>We have released the StringIO gem version 3.0.1.1 and 3.0.1.2 that have a security fix for a buffer overread vulnerability.
|
68
|
+
This vulnerability has been assigned the CVE identifier <a href="https://www.cve.org/CVERecord?id=CVE-2024-27280">CVE-2024-27280</a>.</p>
|
69
|
+
|
70
|
+
<h2>Details</h2>
|
71
|
+
|
72
|
+
<p>An issue was discovered in StringIO 3.0.1, as distributed in Ruby 3.0.x through 3.0.6 and 3.1.x through 3.1.4.</p>
|
73
|
+
|
74
|
+
<p>The <code class="language-plaintext highlighter-rouge">ungetbyte</code> and <code class="language-plaintext highlighter-rouge">ungetc</code> methods on a StringIO can read past the end of a string, and a subsequent call to <code class="language-plaintext highlighter-rouge">StringIO.gets</code> may return the memory value.</p>
|
75
|
+
|
76
|
+
<p>This vulnerability is not affected StringIO 3.0.3 and later, and Ruby 3.2.x and later.</p>
|
77
|
+
|
78
|
+
<h2>Recommended action</h2>
|
79
|
+
|
80
|
+
<p>We recommend to update the StringIO gem to version 3.0.3 or later. In order to ensure compatibility with bundled version in older Ruby series, you may update as follows instead:</p>
|
81
|
+
|
82
|
+
<ul>
|
83
|
+
<li>For Ruby 3.0 users: Update to <code class="language-plaintext highlighter-rouge">stringio</code> 3.0.1.1</li>
|
84
|
+
<li>For Ruby 3.1 users: Update to <code class="language-plaintext highlighter-rouge">stringio</code> 3.0.1.2</li>
|
85
|
+
</ul>
|
86
|
+
|
87
|
+
<p>Note: that StringIO 3.0.1.2 contains not only the fix for this vulnerability but also a bugfix for <a href="https://github.com/ruby/ruby/commit/1d24a931c458c93463da1d5885f33edef3677cc2">[Bug #19389]</a>.</p>
|
88
|
+
|
89
|
+
<p>You can use <code class="language-plaintext highlighter-rouge">gem update stringio</code> to update it. If you are using bundler, please add <code class="language-plaintext highlighter-rouge">gem "stringio", "&gt;= 3.0.1.2"</code> to your <code class="language-plaintext highlighter-rouge">Gemfile</code>.</p>
|
90
|
+
|
91
|
+
<h2>Affected versions</h2>
|
92
|
+
|
93
|
+
<ul>
|
94
|
+
<li>Ruby 3.0.6 or lower</li>
|
95
|
+
<li>Ruby 3.1.4 or lower</li>
|
96
|
+
<li>StringIO gem 3.0.2 or lower</li>
|
97
|
+
</ul>
|
98
|
+
|
99
|
+
<h2>Credits</h2>
|
100
|
+
|
101
|
+
<p>Thanks to <a href="https://hackerone.com/david_h1?type=user">david_h1</a> for discovering this issue.</p>
|
102
|
+
|
103
|
+
<h2>History</h2>
|
104
|
+
|
105
|
+
<ul>
|
106
|
+
<li>Originally published at 2024-03-21 4:00:00 (UTC)</li>
|
107
|
+
</ul>
|
108
|
+
|
109
|
+
<p>Posted by hsbt on 21 Mar 2024</p></description>
|
110
|
+
<pubDate>Thu, 21 Mar 2024 04:00:00 +0000</pubDate>
|
111
|
+
<guid>https://www.ruby-lang.org/en/news/2024/03/21/buffer-overread-cve-2024-27280/</guid>
|
112
|
+
<link>https://www.ruby-lang.org/en/news/2024/03/21/buffer-overread-cve-2024-27280/</link>
|
113
|
+
</item>
|
114
|
+
|
115
|
+
<item>
|
116
|
+
<title>Ruby 3.2.3 Released</title>
|
117
|
+
<description><p>Ruby 3.2.3 has been released.</p>
|
118
|
+
|
119
|
+
<p>This release includes many bug-fixes.
|
120
|
+
See the <a href="https://github.com/ruby/ruby/releases/tag/v3_2_3">GitHub releases</a> for further details.</p>
|
121
|
+
|
122
|
+
<p>This release also includes the update of uri.gem to 0.12.2 which contains the security fix.
|
123
|
+
Please check the topics below for details.</p>
|
124
|
+
|
125
|
+
<ul>
|
126
|
+
<li><a href="/en/news/2023/06/29/redos-in-uri-CVE-2023-36617/">CVE-2023-36617: ReDoS vulnerability in URI</a></li>
|
127
|
+
</ul>
|
128
|
+
|
129
|
+
<h2>Download</h2>
|
130
|
+
|
131
|
+
<ul>
|
132
|
+
<li>
|
133
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.tar.gz</a></p>
|
134
|
+
|
135
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 20577155
|
136
|
+
SHA1: 7f553e514cb42751a61c3a560a7e8d727c6931ca
|
137
|
+
SHA256: af7f1757d9ddb630345988139211f1fd570ff5ba830def1cc7c468ae9b65c9ba
|
138
|
+
SHA512: 75aecd9cf87f1fa66b24ecda8837a53162071b4f8801dcfd79119a24c6e81df3e3e2ba478e1cc48c60103dfaab12a00cfa2039a621f8651298eba8bd8d576360
|
139
|
+
</code></pre></div> </div>
|
140
|
+
</li>
|
141
|
+
<li>
|
142
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.tar.xz</a></p>
|
143
|
+
|
144
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 15163960
|
145
|
+
SHA1: 08e0016c8b96103930aaa3b2323081d8f5756e25
|
146
|
+
SHA256: cfb231954b8c241043a538a4c682a1cca0b2016d835fee0b9e4a0be3ceba476b
|
147
|
+
SHA512: d2a1897c2f4e801a28acb869322abfee76775115016252cecad90639485ed51deda1446cb16edb387f10a2e188602d646ef9b008b57f27bd745071277c535f3b
|
148
|
+
</code></pre></div> </div>
|
149
|
+
</li>
|
150
|
+
<li>
|
151
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.zip">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.3.zip</a></p>
|
152
|
+
|
153
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 24734275
|
154
|
+
SHA1: e305dfe36229c5328d231ea0ac03ae5e05bfaca6
|
155
|
+
SHA256: 42aa39f74e5be9e24e4db47e7bfb15dc7e095f7e2295859b355edccf6fab96a2
|
156
|
+
SHA512: fd89a0a833df4b5cb1734a7ffc86a8cf7cb3a8e25944331db674d3ad7732f615867e7e214e1fdd61e44e9c9c856b461b46219b340de7c87a758f28f3a99dd172
|
157
|
+
</code></pre></div> </div>
|
158
|
+
</li>
|
159
|
+
</ul>
|
160
|
+
|
161
|
+
<h2>Release Comment</h2>
|
162
|
+
|
163
|
+
<p>Many committers, developers, and users who provided bug reports helped us make this release.
|
164
|
+
Thanks for their contributions.</p>
|
165
|
+
|
166
|
+
<p>Posted by nagachika on 18 Jan 2024</p></description>
|
167
|
+
<pubDate>Thu, 18 Jan 2024 09:00:00 +0000</pubDate>
|
168
|
+
<guid>https://www.ruby-lang.org/en/news/2024/01/18/ruby-3-2-3-released/</guid>
|
169
|
+
<link>https://www.ruby-lang.org/en/news/2024/01/18/ruby-3-2-3-released/</link>
|
170
|
+
</item>
|
171
|
+
|
172
|
+
<item>
|
173
|
+
<title>Ruby 3.3.0 Released</title>
|
174
|
+
<description>
|
175
|
+
<p>We are pleased to announce the release of Ruby 3.3.0. Ruby 3.3 adds a new parser named Prism, uses Lrama as a parser generator, adds a new pure-Ruby JIT compiler named RJIT, and many performance improvements especially YJIT.</p>
|
176
|
+
|
177
|
+
<h2>Prism</h2>
|
178
|
+
|
179
|
+
<ul>
|
180
|
+
<li>Introduced <a href="https://github.com/ruby/prism">the Prism parser</a> as a default gem
|
181
|
+
<ul>
|
182
|
+
<li>Prism is a portable, error tolerant, and maintainable recursive descent parser for the Ruby language</li>
|
183
|
+
</ul>
|
184
|
+
</li>
|
185
|
+
<li>Prism is production ready and actively maintained, you can use it in place of Ripper
|
186
|
+
<ul>
|
187
|
+
<li>There is <a href="https://ruby.github.io/prism/">extensive documentation</a> on how to use Prism</li>
|
188
|
+
<li>Prism is both a C library that will be used internally by CRuby and a Ruby gem that can be used by any tooling which needs to parse Ruby code</li>
|
189
|
+
<li>Notable methods in the Prism API are:
|
190
|
+
<ul>
|
191
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse(source)</code> which returns the AST as part of a parse result object</li>
|
192
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse_comments(source)</code> which returns the comments</li>
|
193
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse_success?(source)</code> which returns true if there are no errors</li>
|
194
|
+
</ul>
|
195
|
+
</li>
|
196
|
+
</ul>
|
197
|
+
</li>
|
198
|
+
<li>You can make pull requests or issues directly on <a href="https://github.com/ruby/prism">the Prism repository</a> if you are interested in contributing</li>
|
199
|
+
<li>You can now use <code class="language-plaintext highlighter-rouge">ruby --parser=prism</code> or <code class="language-plaintext highlighter-rouge">RUBYOPT="--parser=prism"</code> to experiment with the Prism compiler. Please note that this flag is for debugging only.</li>
|
200
|
+
</ul>
|
201
|
+
|
202
|
+
<h2>Use Lrama instead of Bison</h2>
|
203
|
+
|
204
|
+
<ul>
|
205
|
+
<li>Replace Bison with <a href="https://github.com/ruby/lrama">Lrama LALR parser generator</a> <a href="https://bugs.ruby-lang.org/issues/19637">[Feature #19637]</a>
|
206
|
+
<ul>
|
207
|
+
<li>If you have interest, please see <a href="https://rubykaigi.org/2023/presentations/spikeolaf.html">The future vision of Ruby Parser</a></li>
|
208
|
+
<li>Lrama internal parser is replaced with LR parser generated by Racc for maintainability</li>
|
209
|
+
<li>Parameterizing Rules <code class="language-plaintext highlighter-rouge">(?, *, +)</code> are supported, it will be used in Ruby parse.y</li>
|
210
|
+
</ul>
|
211
|
+
</li>
|
212
|
+
</ul>
|
213
|
+
|
214
|
+
<h2>YJIT</h2>
|
215
|
+
|
216
|
+
<ul>
|
217
|
+
<li>Major performance improvements over Ruby 3.2
|
218
|
+
<ul>
|
219
|
+
<li>Support for splat and rest arguments has been improved.</li>
|
220
|
+
<li>Registers are allocated for stack operations of the virtual machine.</li>
|
221
|
+
<li>More calls with optional arguments are compiled. Exception handlers are also compiled.</li>
|
222
|
+
<li>Unsupported call types and megamorphic call sites no longer exit to the interpreter.</li>
|
223
|
+
<li>Basic methods like Rails <code class="language-plaintext highlighter-rouge">#blank?</code> and
|
224
|
+
<a href="https://github.com/rails/rails/pull/49909">specialized <code class="language-plaintext highlighter-rouge">#present?</code></a> are inlined.</li>
|
225
|
+
<li><code class="language-plaintext highlighter-rouge">Integer#*</code>, <code class="language-plaintext highlighter-rouge">Integer#!=</code>, <code class="language-plaintext highlighter-rouge">String#!=</code>, <code class="language-plaintext highlighter-rouge">String#getbyte</code>,
|
226
|
+
<code class="language-plaintext highlighter-rouge">Kernel#block_given?</code>, <code class="language-plaintext highlighter-rouge">Kernel#is_a?</code>, <code class="language-plaintext highlighter-rouge">Kernel#instance_of?</code>, and <code class="language-plaintext highlighter-rouge">Module#===</code>
|
227
|
+
are specially optimized.</li>
|
228
|
+
<li>Compilation speed is now slightly faster than Ruby 3.2.</li>
|
229
|
+
<li>Now more than 3x faster than the interpreter on Optcarrot!</li>
|
230
|
+
</ul>
|
231
|
+
</li>
|
232
|
+
<li>Significantly improved memory usage over Ruby 3.2
|
233
|
+
<ul>
|
234
|
+
<li>Metadata for compiled code uses a lot less memory.</li>
|
235
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-call-threshold</code> is automatically raised from 30 to 120
|
236
|
+
when the application has more than 40,000 ISEQs.</li>
|
237
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-cold-threshold</code> is added to skip compiling cold ISEQs.</li>
|
238
|
+
<li>More compact code is generated on Arm64.</li>
|
239
|
+
</ul>
|
240
|
+
</li>
|
241
|
+
<li>Code GC is now disabled by default
|
242
|
+
<ul>
|
243
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-exec-mem-size</code> is treated as a hard limit where compilation of new code stops.</li>
|
244
|
+
<li>No sudden drops in performance due to code GC.
|
245
|
+
Better copy-on-write behavior on servers reforking with
|
246
|
+
<a href="https://github.com/shopify/pitchfork">Pitchfork</a>.</li>
|
247
|
+
<li>You can still enable code GC if desired with <code class="language-plaintext highlighter-rouge">--yjit-code-gc</code></li>
|
248
|
+
</ul>
|
249
|
+
</li>
|
250
|
+
<li>Add <code class="language-plaintext highlighter-rouge">RubyVM::YJIT.enable</code> that can enable YJIT at run-time
|
251
|
+
<ul>
|
252
|
+
<li>You can start YJIT without modifying command-line arguments or environment variables.
|
253
|
+
Rails 7.2 will <a href="https://github.com/rails/rails/pull/49947">enable YJIT by default</a>
|
254
|
+
using this method.</li>
|
255
|
+
<li>This can also be used to enable YJIT only once your application is
|
256
|
+
done booting. <code class="language-plaintext highlighter-rouge">--yjit-disable</code> can be used if you want to use other
|
257
|
+
YJIT options while disabling YJIT at boot.</li>
|
258
|
+
</ul>
|
259
|
+
</li>
|
260
|
+
<li>More YJIT stats are available by default
|
261
|
+
<ul>
|
262
|
+
<li><code class="language-plaintext highlighter-rouge">yjit_alloc_size</code> and several more metadata-related stats are now available by default.</li>
|
263
|
+
<li><code class="language-plaintext highlighter-rouge">ratio_in_yjit</code> stat produced by <code class="language-plaintext highlighter-rouge">--yjit-stats</code> is now available in release builds,
|
264
|
+
a special stats or dev build is no longer required to access most stats.</li>
|
265
|
+
</ul>
|
266
|
+
</li>
|
267
|
+
<li>Add more profiling capabilities
|
268
|
+
<ul>
|
269
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-perf</code> is added to facilitate profiling with Linux perf.</li>
|
270
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-trace-exits</code> now supports sampling with <code class="language-plaintext highlighter-rouge">--yjit-trace-exits-sample-rate=N</code></li>
|
271
|
+
</ul>
|
272
|
+
</li>
|
273
|
+
<li>More thorough testing and multiple bug fixes</li>
|
274
|
+
</ul>
|
275
|
+
|
276
|
+
<h2>RJIT</h2>
|
277
|
+
|
278
|
+
<ul>
|
279
|
+
<li>Introduced a pure-Ruby JIT compiler RJIT and replaced MJIT.
|
280
|
+
<ul>
|
281
|
+
<li>RJIT supports only x86-64 architecture on Unix platforms.</li>
|
282
|
+
<li>Unlike MJIT, it doesn’t require a C compiler at runtime.</li>
|
283
|
+
</ul>
|
284
|
+
</li>
|
285
|
+
<li>RJIT exists only for experimental purposes.
|
286
|
+
<ul>
|
287
|
+
<li>You should keep using YJIT in production.</li>
|
288
|
+
</ul>
|
289
|
+
</li>
|
290
|
+
<li>If you are interested in developing JIT for Ruby, please check out <a href="https://rubykaigi.org/2023/presentations/k0kubun.html#day3">k0kubun’s presentation on Day 3 of RubyKaigi</a>.</li>
|
291
|
+
</ul>
|
292
|
+
|
293
|
+
<h2>M:N thread scheduler</h2>
|
294
|
+
|
295
|
+
<ul>
|
296
|
+
<li>M:N thread scheduler was introduced. <a href="https://bugs.ruby-lang.org/issues/19842">[Feature #19842]</a>
|
297
|
+
<ul>
|
298
|
+
<li>M Ruby threads are managed by N native threads (OS threads) so the thread creation and management cost are reduced.</li>
|
299
|
+
<li>It can break C-extension compatibility so that M:N thread scheduler is disabled on the main Ractor by default.
|
300
|
+
<ul>
|
301
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MN_THREADS=1</code> environment variable enables M:N threads on the main Ractor.</li>
|
302
|
+
<li>M:N threads are always enabled on non-main Ractors.</li>
|
303
|
+
</ul>
|
304
|
+
</li>
|
305
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU=n</code> environment variable sets maximum number of <code class="language-plaintext highlighter-rouge">N</code> (maximum number of native threads). The default value is 8.
|
306
|
+
<ul>
|
307
|
+
<li>Since only one Ruby thread per Ractor can run at the same time, the number of native threads will be used, which is the smaller of the number specified in <code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU</code> and the number of running Ractors. So that single Ractor applications (most of applications) will only use 1 native thread.</li>
|
308
|
+
<li>To support blocking operations, more than <code class="language-plaintext highlighter-rouge">N</code> native threads can be used.</li>
|
309
|
+
</ul>
|
310
|
+
</li>
|
311
|
+
</ul>
|
312
|
+
</li>
|
313
|
+
</ul>
|
314
|
+
|
315
|
+
<h2>Performance improvements</h2>
|
316
|
+
|
317
|
+
<ul>
|
318
|
+
<li><code class="language-plaintext highlighter-rouge">defined?(@ivar)</code> is optimized with Object Shapes.</li>
|
319
|
+
<li>Name resolution such as <code class="language-plaintext highlighter-rouge">Socket.getaddrinfo</code> can now be interrupted (in environments where pthreads are available). <a href="https://bugs.ruby-lang.org/issues/19965">[Feature #19965]</a></li>
|
320
|
+
<li>Several performance improvements to the Garbage Collector
|
321
|
+
<ul>
|
322
|
+
<li>Young objects referenced by old objects are no longer immediately
|
323
|
+
promoted to the old generation. This significantly reduces the frequency of
|
324
|
+
major GC collections. <a href="https://bugs.ruby-lang.org/issues/19678">[Feature #19678]</a></li>
|
325
|
+
<li>A new <code class="language-plaintext highlighter-rouge">REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO</code> tuning variable was
|
326
|
+
introduced to control the number of unprotected objects cause a major GC
|
327
|
+
collection to trigger. The default is set to <code class="language-plaintext highlighter-rouge">0.01</code> (1%). This significantly
|
328
|
+
reduces the frequency of major GC collection. <a href="https://bugs.ruby-lang.org/issues/19571">[Feature #19571]</a></li>
|
329
|
+
<li>Write Barriers were implemented for many core types that were missing them,
|
330
|
+
notably <code class="language-plaintext highlighter-rouge">Time</code>, <code class="language-plaintext highlighter-rouge">Enumerator</code>, <code class="language-plaintext highlighter-rouge">MatchData</code>, <code class="language-plaintext highlighter-rouge">Method</code>, <code class="language-plaintext highlighter-rouge">File::Stat</code>, <code class="language-plaintext highlighter-rouge">BigDecimal</code>
|
331
|
+
and several others. This significantly reduces minor GC collection time and major
|
332
|
+
GC collection frequency.</li>
|
333
|
+
<li>Most core classes are now using Variable Width Allocation, notably <code class="language-plaintext highlighter-rouge">Hash</code>, <code class="language-plaintext highlighter-rouge">Time</code>,
|
334
|
+
<code class="language-plaintext highlighter-rouge">Thread::Backtrace</code>, <code class="language-plaintext highlighter-rouge">Thread::Backtrace::Location</code>, <code class="language-plaintext highlighter-rouge">File::Stat</code>, <code class="language-plaintext highlighter-rouge">Method</code>.
|
335
|
+
This makes these classes faster to allocate and free, use less memory and reduce
|
336
|
+
heap fragmentation.</li>
|
337
|
+
<li>Support for weak references has been added to the garbage collector. <a href="https://bugs.ruby-lang.org/issues/19783">[Feature #19783]</a></li>
|
338
|
+
</ul>
|
339
|
+
</li>
|
340
|
+
</ul>
|
341
|
+
|
342
|
+
<h2>Other notable changes since 3.2</h2>
|
343
|
+
|
344
|
+
<h3>IRB</h3>
|
345
|
+
|
346
|
+
<p>IRB has received several enhancements, including but not limited to:</p>
|
347
|
+
|
348
|
+
<ul>
|
349
|
+
<li>Advanced <code class="language-plaintext highlighter-rouge">irb:rdbg</code> integration that provides an equivalent debugging experience to <code class="language-plaintext highlighter-rouge">pry-byebug</code> (<a href="https://github.com/ruby/irb#debugging-with-irb">doc</a>).</li>
|
350
|
+
<li>Pager support for <code class="language-plaintext highlighter-rouge">ls</code>, <code class="language-plaintext highlighter-rouge">show_source</code> and <code class="language-plaintext highlighter-rouge">show_cmds</code> commands.</li>
|
351
|
+
<li>More accurate and helpful information provided by the <code class="language-plaintext highlighter-rouge">ls</code> and <code class="language-plaintext highlighter-rouge">show_source</code> commands.</li>
|
352
|
+
<li>Experimental autocompletion using type analysis (<a href="https://github.com/ruby/irb#type-based-completion">doc</a>).</li>
|
353
|
+
<li>It is now possible to change the font color and font style in the completion dialog by a newly introduced class Reline::Face (<a href="https://github.com/ruby/ruby/blob/master/doc/reline/face.md">doc</a>)</li>
|
354
|
+
</ul>
|
355
|
+
|
356
|
+
<p>In addition, IRB has also undergone extensive refactoring and received dozens of bug fixes to facilitate easier future enhancements.</p>
|
357
|
+
|
358
|
+
<p>For more detailed updates, please refer to <a href="https://railsatscale.com/2023-12-19-irb-for-ruby-3-3/">Unveiling the big leap in Ruby 3.3’s IRB</a>.</p>
|
359
|
+
|
360
|
+
<h2>Compatibility issues</h2>
|
361
|
+
|
362
|
+
<p>Note: Excluding feature bug fixes.</p>
|
363
|
+
|
364
|
+
<ul>
|
365
|
+
<li><code class="language-plaintext highlighter-rouge">it</code> calls without arguments in a block with no ordinary parameters are
|
366
|
+
deprecated. <code class="language-plaintext highlighter-rouge">it</code> will be a reference to the first block parameter in Ruby 3.4.
|
367
|
+
<a href="https://bugs.ruby-lang.org/issues/18980">[Feature #18980]</a></li>
|
368
|
+
</ul>
|
369
|
+
|
370
|
+
<h3>Removed environment variables</h3>
|
371
|
+
|
372
|
+
<p>The following deprecated methods are removed.</p>
|
373
|
+
|
374
|
+
<ul>
|
375
|
+
<li>Environment variable <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_INIT_SLOTS</code> has been deprecated and is a no-op. Please use environment variables <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_{0,1,2,3,4}_INIT_SLOTS</code> instead. <a href="https://bugs.ruby-lang.org/issues/19785">[Feature #19785]</a></li>
|
376
|
+
</ul>
|
377
|
+
|
378
|
+
<h2>Stdlib compatibility issues</h2>
|
379
|
+
|
380
|
+
<h3><code class="language-plaintext highlighter-rouge">ext/readline</code> is retired</h3>
|
381
|
+
|
382
|
+
<ul>
|
383
|
+
<li>We have <code class="language-plaintext highlighter-rouge">reline</code> that is pure Ruby implementation compatible with <code class="language-plaintext highlighter-rouge">ext/readline</code> API. We rely on <code class="language-plaintext highlighter-rouge">reline</code> in the future. If you need to use <code class="language-plaintext highlighter-rouge">ext/readline</code>, you can install <code class="language-plaintext highlighter-rouge">ext/readline</code> via rubygems.org with <code class="language-plaintext highlighter-rouge">gem install readline-ext</code>.</li>
|
384
|
+
<li>We no longer need to install libraries like <code class="language-plaintext highlighter-rouge">libreadline</code> or <code class="language-plaintext highlighter-rouge">libedit</code>.</li>
|
385
|
+
</ul>
|
386
|
+
|
387
|
+
<h2>Standard library updates</h2>
|
388
|
+
|
389
|
+
<p>RubyGems and Bundler warn if users do <code class="language-plaintext highlighter-rouge">require</code> the following gems without adding them to Gemfile or gemspec. This is because they will become the bundled gems in the future version of Ruby.</p>
|
390
|
+
|
391
|
+
<p>This warning is suppressed if you use bootsnap gem. We recommend to run your application with <code class="language-plaintext highlighter-rouge">DISABLE_BOOTSNAP=1</code> environment variable at least once. This is limitation of this version.</p>
|
392
|
+
|
393
|
+
<p>Targeted libraries are:</p>
|
394
|
+
<ul>
|
395
|
+
<li>abbrev</li>
|
396
|
+
<li>base64</li>
|
397
|
+
<li>bigdecimal</li>
|
398
|
+
<li>csv</li>
|
399
|
+
<li>drb</li>
|
400
|
+
<li>getoptlong</li>
|
401
|
+
<li>mutex_m</li>
|
402
|
+
<li>nkf</li>
|
403
|
+
<li>observer</li>
|
404
|
+
<li>racc</li>
|
405
|
+
<li>resolv-replace</li>
|
406
|
+
<li>rinda</li>
|
407
|
+
<li>syslog</li>
|
408
|
+
</ul>
|
409
|
+
|
410
|
+
<p>The following default gem is added.</p>
|
411
|
+
|
412
|
+
<ul>
|
413
|
+
<li>prism 0.19.0</li>
|
414
|
+
</ul>
|
415
|
+
|
416
|
+
<p>The following default gems are updated.</p>
|
417
|
+
|
418
|
+
<ul>
|
419
|
+
<li>RubyGems 3.5.3</li>
|
420
|
+
<li>abbrev 0.1.2</li>
|
421
|
+
<li>base64 0.2.0</li>
|
422
|
+
<li>benchmark 0.3.0</li>
|
423
|
+
<li>bigdecimal 3.1.5</li>
|
424
|
+
<li>bundler 2.5.3</li>
|
425
|
+
<li>cgi 0.4.1</li>
|
426
|
+
<li>csv 3.2.8</li>
|
427
|
+
<li>date 3.3.4</li>
|
428
|
+
<li>delegate 0.3.1</li>
|
429
|
+
<li>drb 2.2.0</li>
|
430
|
+
<li>english 0.8.0</li>
|
431
|
+
<li>erb 4.0.3</li>
|
432
|
+
<li>error_highlight 0.6.0</li>
|
433
|
+
<li>etc 1.4.3</li>
|
434
|
+
<li>fcntl 1.1.0</li>
|
435
|
+
<li>fiddle 1.1.2</li>
|
436
|
+
<li>fileutils 1.7.2</li>
|
437
|
+
<li>find 0.2.0</li>
|
438
|
+
<li>getoptlong 0.2.1</li>
|
439
|
+
<li>io-console 0.7.1</li>
|
440
|
+
<li>io-nonblock 0.3.0</li>
|
441
|
+
<li>io-wait 0.3.1</li>
|
442
|
+
<li>ipaddr 1.2.6</li>
|
443
|
+
<li>irb 1.11.0</li>
|
444
|
+
<li>json 2.7.1</li>
|
445
|
+
<li>logger 1.6.0</li>
|
446
|
+
<li>mutex_m 0.2.0</li>
|
447
|
+
<li>net-http 0.4.0</li>
|
448
|
+
<li>net-protocol 0.2.2</li>
|
449
|
+
<li>nkf 0.1.3</li>
|
450
|
+
<li>observer 0.1.2</li>
|
451
|
+
<li>open-uri 0.4.1</li>
|
452
|
+
<li>open3 0.2.1</li>
|
453
|
+
<li>openssl 3.2.0</li>
|
454
|
+
<li>optparse 0.4.0</li>
|
455
|
+
<li>ostruct 0.6.0</li>
|
456
|
+
<li>pathname 0.3.0</li>
|
457
|
+
<li>pp 0.5.0</li>
|
458
|
+
<li>prettyprint 0.2.0</li>
|
459
|
+
<li>pstore 0.1.3</li>
|
460
|
+
<li>psych 5.1.2</li>
|
461
|
+
<li>rdoc 6.6.2</li>
|
462
|
+
<li>readline 0.0.4</li>
|
463
|
+
<li>reline 0.4.1</li>
|
464
|
+
<li>resolv 0.3.0</li>
|
465
|
+
<li>rinda 0.2.0</li>
|
466
|
+
<li>securerandom 0.3.1</li>
|
467
|
+
<li>set 1.1.0</li>
|
468
|
+
<li>shellwords 0.2.0</li>
|
469
|
+
<li>singleton 0.2.0</li>
|
470
|
+
<li>stringio 3.1.0</li>
|
471
|
+
<li>strscan 3.0.7</li>
|
472
|
+
<li>syntax_suggest 2.0.0</li>
|
473
|
+
<li>syslog 0.1.2</li>
|
474
|
+
<li>tempfile 0.2.1</li>
|
475
|
+
<li>time 0.3.0</li>
|
476
|
+
<li>timeout 0.4.1</li>
|
477
|
+
<li>tmpdir 0.2.0</li>
|
478
|
+
<li>tsort 0.2.0</li>
|
479
|
+
<li>un 0.3.0</li>
|
480
|
+
<li>uri 0.13.0</li>
|
481
|
+
<li>weakref 0.1.3</li>
|
482
|
+
<li>win32ole 1.8.10</li>
|
483
|
+
<li>yaml 0.3.0</li>
|
484
|
+
<li>zlib 3.1.0</li>
|
485
|
+
</ul>
|
486
|
+
|
487
|
+
<p>The following bundled gem is promoted from default gems.</p>
|
488
|
+
|
489
|
+
<ul>
|
490
|
+
<li>racc 1.7.3</li>
|
491
|
+
</ul>
|
492
|
+
|
493
|
+
<p>The following bundled gems are updated.</p>
|
494
|
+
|
495
|
+
<ul>
|
496
|
+
<li>minitest 5.20.0</li>
|
497
|
+
<li>rake 13.1.0</li>
|
498
|
+
<li>test-unit 3.6.1</li>
|
499
|
+
<li>rexml 3.2.6</li>
|
500
|
+
<li>rss 0.3.0</li>
|
501
|
+
<li>net-ftp 0.3.3</li>
|
502
|
+
<li>net-imap 0.4.9</li>
|
503
|
+
<li>net-smtp 0.4.0</li>
|
504
|
+
<li>rbs 3.4.0</li>
|
505
|
+
<li>typeprof 0.21.9</li>
|
506
|
+
<li>debug 1.9.1</li>
|
507
|
+
</ul>
|
508
|
+
|
509
|
+
<p>See GitHub releases like <a href="https://github.com/ruby/logger/releases">Logger</a> or
|
510
|
+
changelog for details of the default gems or bundled gems.</p>
|
511
|
+
|
512
|
+
<p>See <a href="https://github.com/ruby/ruby/blob/v3_3_0/NEWS.md">NEWS</a>
|
513
|
+
or <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0">commit logs</a>
|
514
|
+
for more details.</p>
|
515
|
+
|
516
|
+
<p>With those changes, <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0#file_bucket">5532 files changed, 326851 insertions(+), 185793 deletions(-)</a>
|
517
|
+
since Ruby 3.2.0!</p>
|
518
|
+
|
519
|
+
<p>Merry Christmas, Happy Holidays, and enjoy programming with Ruby 3.3!</p>
|
520
|
+
|
521
|
+
<h2>Download</h2>
|
522
|
+
|
523
|
+
<ul>
|
524
|
+
<li>
|
525
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.gz</a></p>
|
526
|
+
|
527
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 22065999
|
528
|
+
SHA1: 1a7e56851bf29bda1183aca99b3b323c58e0187b
|
529
|
+
SHA256: 96518814d9832bece92a85415a819d4893b307db5921ae1f0f751a9a89a56b7d
|
530
|
+
SHA512: 26074009b501fc793d71a74e419f34a6033c9353433919ca74ba2d24a3de432dbb11fd92c2bc285f0e4d951a6d6c74bf5b69a2ab36200c8c26e871746d6e0fc6
|
531
|
+
</code></pre></div> </div>
|
532
|
+
</li>
|
533
|
+
<li>
|
534
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.tar.xz</a></p>
|
535
|
+
|
536
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 16345456
|
537
|
+
SHA1: c8f68e1b0a114b90460a0b44165a3b2f540fa5b6
|
538
|
+
SHA256: 676b65a36e637e90f982b57b059189b3276b9045034dcd186a7e9078847b975b
|
539
|
+
SHA512: 7959c5753bfa0bfc4d6d74060869aabbe9815c1c97930659da11b917ee0803ddbbd80e869e00c48b8694b4ba48709c3b6493fd045568e36e902616c35ababf01
|
540
|
+
</code></pre></div> </div>
|
541
|
+
</li>
|
542
|
+
<li>
|
543
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.zip">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0.zip</a></p>
|
544
|
+
|
545
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 26935108
|
546
|
+
SHA1: a433eef1d7f96daeaf3b4cb842d0ed2dd82e7dc1
|
547
|
+
SHA256: 0e6563f679dd3694732eb3addf9de681c67b584602ac574376b60e7a509d2cd8
|
548
|
+
SHA512: a94a85937a14b217c1f4b90d24185289ed4aee79239c4f3eecf8034d3fd34e65ee8d66869473857ed153067188adc9b70c0471e4ebe842c9f98ef60c34090450
|
549
|
+
</code></pre></div> </div>
|
550
|
+
</li>
|
551
|
+
</ul>
|
552
|
+
|
553
|
+
<h2>What is Ruby</h2>
|
554
|
+
|
555
|
+
<p>Ruby was first developed by Matz (Yukihiro Matsumoto) in 1993,
|
556
|
+
and is now developed as Open Source. It runs on multiple platforms
|
557
|
+
and is used all over the world especially for web development.</p>
|
558
|
+
|
559
|
+
<p>Posted by naruse on 25 Dec 2023</p></description>
|
560
|
+
<pubDate>Mon, 25 Dec 2023 00:00:00 +0000</pubDate>
|
561
|
+
<guid>https://www.ruby-lang.org/en/news/2023/12/25/ruby-3-3-0-released/</guid>
|
562
|
+
<link>https://www.ruby-lang.org/en/news/2023/12/25/ruby-3-3-0-released/</link>
|
563
|
+
</item>
|
564
|
+
|
565
|
+
<item>
|
566
|
+
<title>Ruby 3.3.0-rc1 Released</title>
|
567
|
+
<description>
|
568
|
+
<p>We are pleased to announce the release of Ruby 3.3.0-rc1. Ruby 3.3 adds a new parser named Prism, uses Lrama as a parser generator, adds a new pure-Ruby JIT compiler named RJIT, and many performance improvements especially YJIT.</p>
|
569
|
+
|
570
|
+
<p>After the release of RC1, we will avoid introducing ABI incompatibilities wherever possible. If we need to do, we’ll announce it in the release note.</p>
|
571
|
+
|
572
|
+
<h2>Prism</h2>
|
573
|
+
|
574
|
+
<ul>
|
575
|
+
<li>Introduced <a href="https://github.com/ruby/prism">the Prism parser</a> as a default gem
|
576
|
+
<ul>
|
577
|
+
<li>Prism is a portable, error tolerant, and maintainable recursive descent parser for the Ruby language</li>
|
578
|
+
</ul>
|
579
|
+
</li>
|
580
|
+
<li>Prism is production ready and actively maintained, you can use it in place of Ripper
|
581
|
+
<ul>
|
582
|
+
<li>There is <a href="https://ruby.github.io/prism/">extensive documentation</a> on how to use Prism</li>
|
583
|
+
<li>Prism is both a C library that will be used internally by CRuby and a Ruby gem that can be used by any tooling which needs to parse Ruby code</li>
|
584
|
+
<li>Notable methods in the Prism API are:
|
585
|
+
<ul>
|
586
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse(source)</code> which returns the AST as part of a ParseResult</li>
|
587
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.dump(source)</code> which returns the serialized AST as a String</li>
|
588
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse_comments(source)</code> which returns the comments</li>
|
589
|
+
</ul>
|
590
|
+
</li>
|
591
|
+
</ul>
|
592
|
+
</li>
|
593
|
+
<li>You can make pull requests or issues directly on <a href="https://github.com/ruby/prism">the Prism repository</a> if you are interested in contributing</li>
|
594
|
+
</ul>
|
595
|
+
|
596
|
+
<h2>Use Lrama instead of Bison</h2>
|
597
|
+
|
598
|
+
<ul>
|
599
|
+
<li>Replace Bison with <a href="https://github.com/ruby/lrama">Lrama LALR parser generator</a> <a href="https://bugs.ruby-lang.org/issues/19637">Feature #19637</a>
|
600
|
+
<ul>
|
601
|
+
<li>If you have interest, please see <a href="https://rubykaigi.org/2023/presentations/spikeolaf.html">The future vision of Ruby Parser</a></li>
|
602
|
+
<li>Lrama internal parser is replaced with LR parser generated by Racc for maintainability</li>
|
603
|
+
<li>Parameterizing Rules <code class="language-plaintext highlighter-rouge">(?, *, +)</code> are supported, it will be used in Ruby parse.y</li>
|
604
|
+
</ul>
|
605
|
+
</li>
|
606
|
+
</ul>
|
607
|
+
|
608
|
+
<h2>RJIT</h2>
|
609
|
+
|
610
|
+
<ul>
|
611
|
+
<li>Introduced a pure-Ruby JIT compiler RJIT and replaced MJIT.
|
612
|
+
<ul>
|
613
|
+
<li>RJIT supports only x86-64 architecture on Unix platforms.</li>
|
614
|
+
<li>Unlike MJIT, it doesn’t require a C compiler at runtime.</li>
|
615
|
+
</ul>
|
616
|
+
</li>
|
617
|
+
<li>RJIT exists only for experimental purposes.
|
618
|
+
<ul>
|
619
|
+
<li>You should keep using YJIT in production.</li>
|
620
|
+
</ul>
|
621
|
+
</li>
|
622
|
+
<li>If you are interested in developing JIT for Ruby, please check out <a href="https://rubykaigi.org/2023/presentations/k0kubun.html#day3">k0kubun’s presentation on Day 3 of RubyKaigi</a>.</li>
|
623
|
+
</ul>
|
624
|
+
|
625
|
+
<h2>YJIT</h2>
|
626
|
+
|
627
|
+
<ul>
|
628
|
+
<li>Major performance improvements over 3.2
|
629
|
+
<ul>
|
630
|
+
<li>Support for splat and rest arguments has been improved.</li>
|
631
|
+
<li>Registers are allocated for stack operations of the virtual machine.</li>
|
632
|
+
<li>More calls with optional arguments are compiled.</li>
|
633
|
+
<li>Exception handlers are also compiled.</li>
|
634
|
+
<li>Instance variables no longer exit to the interpreter
|
635
|
+
with megamorphic object shapes.</li>
|
636
|
+
<li>Unsupported call types no longer exit to the interpreter.</li>
|
637
|
+
<li><code class="language-plaintext highlighter-rouge">Integer#!=</code>, <code class="language-plaintext highlighter-rouge">String#!=</code>, <code class="language-plaintext highlighter-rouge">Kernel#block_given?</code>, <code class="language-plaintext highlighter-rouge">Kernel#is_a?</code>,
|
638
|
+
<code class="language-plaintext highlighter-rouge">Kernel#instance_of?</code>, <code class="language-plaintext highlighter-rouge">Module#===</code> are specially optimized.</li>
|
639
|
+
<li>Now more than 3x faster than the interpreter on optcarrot!</li>
|
640
|
+
</ul>
|
641
|
+
</li>
|
642
|
+
<li>Significantly improved memory usage over 3.2
|
643
|
+
<ul>
|
644
|
+
<li>Metadata for compiled code uses a lot less memory.</li>
|
645
|
+
<li>Generate more compact code on ARM64</li>
|
646
|
+
</ul>
|
647
|
+
</li>
|
648
|
+
<li>Compilation speed is now slightly faster than 3.2.</li>
|
649
|
+
<li>Add <code class="language-plaintext highlighter-rouge">RubyVM::YJIT.enable</code> that can enable YJIT at run-time
|
650
|
+
<ul>
|
651
|
+
<li>You can start YJIT without modifying command-line arguments or environment variables.</li>
|
652
|
+
<li>This can also be used to enable YJIT only once your application is
|
653
|
+
done booting. <code class="language-plaintext highlighter-rouge">--yjit-disable</code> can be used if you want to use other
|
654
|
+
YJIT options while disabling YJIT at boot.</li>
|
655
|
+
</ul>
|
656
|
+
</li>
|
657
|
+
<li>Code GC is now disabled by default, and <code class="language-plaintext highlighter-rouge">--yjit-exec-mem-size</code> is treated
|
658
|
+
as a hard limit where compilation of new code stops.
|
659
|
+
<ul>
|
660
|
+
<li>Better copy-on-write behavior on servers using unicorn and forking</li>
|
661
|
+
<li>No sudden drops in performance due to code GC.</li>
|
662
|
+
<li>You can still enable code GC if desired with <code class="language-plaintext highlighter-rouge">--yjit-code-gc</code></li>
|
663
|
+
</ul>
|
664
|
+
</li>
|
665
|
+
<li><code class="language-plaintext highlighter-rouge">ratio_in_yjit</code> stat produced by <code class="language-plaintext highlighter-rouge">--yjit-stats</code> is now available in release builds,
|
666
|
+
a special stats or dev build is no longer required to access most stats.</li>
|
667
|
+
<li>Exit tracing option now supports sampling
|
668
|
+
<ul>
|
669
|
+
<li><code class="language-plaintext highlighter-rouge">--trace-exits-sample-rate=N</code></li>
|
670
|
+
</ul>
|
671
|
+
</li>
|
672
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-perf</code> is added to facilitate profiling with Linux perf.</li>
|
673
|
+
<li>More thorough testing and multiple bug fixes</li>
|
674
|
+
</ul>
|
675
|
+
|
676
|
+
<h3>M:N thread scheduler</h3>
|
677
|
+
|
678
|
+
<ul>
|
679
|
+
<li>M:N thread scheduler was introduced. <a href="https://bugs.ruby-lang.org/issues/19842">[Feature #19842]</a>
|
680
|
+
<ul>
|
681
|
+
<li>M Ruby threads are managed by N native threads (OS threads) so the thread creation and management cost are reduced.</li>
|
682
|
+
<li>It can break C-extension compatibility so that M:N thread scheduler is disabled on the main Ractor by default.
|
683
|
+
<ul>
|
684
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MN_THREADS=1</code> environment variable enables M:N threads on the main Ractor.</li>
|
685
|
+
<li>M:N threads are enabled on non-main Ractors.</li>
|
686
|
+
</ul>
|
687
|
+
</li>
|
688
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU=n</code> environment variable sets maximum number of <code class="language-plaintext highlighter-rouge">N</code> (maximum number of native threads). The default value is 8.
|
689
|
+
<ul>
|
690
|
+
<li>Since only one Ruby thread per Ractor can run at the same time, the number of native threads will be used, which is the smaller of the number specified in <code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU</code> and the number of running Ractors. So that single Ractor applications (most of applications) will use 1 native thread.</li>
|
691
|
+
<li>To support blocking operations, more than <code class="language-plaintext highlighter-rouge">N</code> native threads can be used.</li>
|
692
|
+
</ul>
|
693
|
+
</li>
|
694
|
+
</ul>
|
695
|
+
</li>
|
696
|
+
</ul>
|
697
|
+
|
698
|
+
<h2>Other Notable New Features</h2>
|
699
|
+
|
700
|
+
<h3>Language</h3>
|
701
|
+
|
702
|
+
<h2>Performance improvements</h2>
|
703
|
+
|
704
|
+
<ul>
|
705
|
+
<li><code class="language-plaintext highlighter-rouge">defined?(@ivar)</code> is optimized with Object Shapes.</li>
|
706
|
+
<li>Name resolution such as <code class="language-plaintext highlighter-rouge">Socket.getaddrinfo</code> can now be interrupted (in environments where pthreads are available). <a href="https://bugs.ruby-lang.org/issues/19965">Feature #19965</a>
|
707
|
+
<ul>
|
708
|
+
<li>For this purpose, a pthread is now created whenever calling getaddrinfo or getnameinfo. This incurs some overhead in name resolution (about 2.5x in our experiments). We do not expect the name resolution overhead to be a problem for most applications, but if you observe such, or if you see unexpected affects that you believe are due to this change, please report them.</li>
|
709
|
+
</ul>
|
710
|
+
</li>
|
711
|
+
<li>Several performance improvements to the Garbage Collector
|
712
|
+
<ul>
|
713
|
+
<li>Young objects referenced by old objects are no longer immediately
|
714
|
+
promoted to the old generation. This significantly reduces the frequency of
|
715
|
+
major GC collections. <a href="https://bugs.ruby-lang.org/issues/19678">[Feature #19678]</a></li>
|
716
|
+
<li>A new <code class="language-plaintext highlighter-rouge">REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO</code> tuning variable was
|
717
|
+
introduced to control the number of unprotected objects cause a major GC
|
718
|
+
collection to trigger. The default is set to <code class="language-plaintext highlighter-rouge">0.01</code> (1%). This significantly
|
719
|
+
reduces the frequency of major GC collection. <a href="https://bugs.ruby-lang.org/issues/19571">[Feature #19571]</a></li>
|
720
|
+
<li>Write Barriers were implemented for many core types that were missing them,
|
721
|
+
notably <code class="language-plaintext highlighter-rouge">Time</code>, <code class="language-plaintext highlighter-rouge">Enumerator</code>, <code class="language-plaintext highlighter-rouge">MatchData</code>, <code class="language-plaintext highlighter-rouge">Method</code>, <code class="language-plaintext highlighter-rouge">File::Stat</code>, <code class="language-plaintext highlighter-rouge">BigDecimal</code>
|
722
|
+
and several others. This significantly reduces minor GC collection time and major
|
723
|
+
GC collection frequency.</li>
|
724
|
+
<li>Most core classes are now using Variable Width Allocation, notably <code class="language-plaintext highlighter-rouge">Hash</code>, <code class="language-plaintext highlighter-rouge">Time</code>,
|
725
|
+
<code class="language-plaintext highlighter-rouge">Thread::Backtrace</code>, <code class="language-plaintext highlighter-rouge">Thread::Backtrace::Location</code>, <code class="language-plaintext highlighter-rouge">File::Stat</code>, <code class="language-plaintext highlighter-rouge">Method</code>.
|
726
|
+
This makes these classes faster to allocate and free, use less memory and reduce
|
727
|
+
heap fragmentation.</li>
|
728
|
+
<li>Support for weak references has been added to the garbage collector. <a href="https://bugs.ruby-lang.org/issues/19783">[Feature #19783]</a></li>
|
729
|
+
</ul>
|
730
|
+
</li>
|
731
|
+
</ul>
|
732
|
+
|
733
|
+
<h2>Other notable changes since 3.2</h2>
|
734
|
+
|
735
|
+
<h3>IRB</h3>
|
736
|
+
|
737
|
+
<p>IRB has received several enhancements, including but not limited to:</p>
|
738
|
+
|
739
|
+
<ul>
|
740
|
+
<li>Advanced <code class="language-plaintext highlighter-rouge">irb:rdbg</code> integration that provides an equivalent debugging experience to <code class="language-plaintext highlighter-rouge">pry-byebug</code> (<a href="https://github.com/ruby/irb#debugging-with-irb">doc</a>).</li>
|
741
|
+
<li>Pager support for <code class="language-plaintext highlighter-rouge">ls</code>, <code class="language-plaintext highlighter-rouge">show_source</code> and <code class="language-plaintext highlighter-rouge">show_cmds</code> commands.</li>
|
742
|
+
<li>More accurate and helpful information provided by the <code class="language-plaintext highlighter-rouge">ls</code> and <code class="language-plaintext highlighter-rouge">show_source</code> commands.</li>
|
743
|
+
<li>Experimental autocompletion using type analysis (<a href="https://github.com/ruby/irb#type-based-completion">doc</a>).</li>
|
744
|
+
<li>It is now possible to change the font color and font style in the completion dialog by a newly introduced class Reline::Face (<a href="https://github.com/ruby/ruby/blob/master/doc/reline/face.md">doc</a>)</li>
|
745
|
+
</ul>
|
746
|
+
|
747
|
+
<p>In addition, IRB has also undergone extensive refactoring and received dozens of bug fixes to facilitate easier future enhancements.</p>
|
748
|
+
|
749
|
+
<h2>Compatibility issues</h2>
|
750
|
+
|
751
|
+
<p>Note: Excluding feature bug fixes.</p>
|
752
|
+
|
753
|
+
<ul>
|
754
|
+
<li><code class="language-plaintext highlighter-rouge">it</code> calls without arguments in a block with no ordinary parameters are
|
755
|
+
deprecated. <code class="language-plaintext highlighter-rouge">it</code> will be a reference to the first block parameter in Ruby 3.4.
|
756
|
+
<a href="https://bugs.ruby-lang.org/issues/18980">Feature #18980</a></li>
|
757
|
+
</ul>
|
758
|
+
|
759
|
+
<h3>Removed constants</h3>
|
760
|
+
|
761
|
+
<p>The following deprecated constants are removed.</p>
|
762
|
+
|
763
|
+
<h3>Removed methods</h3>
|
764
|
+
|
765
|
+
<p>The following deprecated methods are removed.</p>
|
766
|
+
|
767
|
+
<h3>Removed environment variables</h3>
|
768
|
+
|
769
|
+
<p>The following deprecated environment variables are removed.</p>
|
770
|
+
|
771
|
+
<ul>
|
772
|
+
<li>Environment variable <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_INIT_SLOTS</code> has been deprecated and is a no-op. Please use environment variables <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_{0,1,2,3,4}_INIT_SLOTS</code> instead. <a href="https://bugs.ruby-lang.org/issues/19785">Feature #19785</a></li>
|
773
|
+
</ul>
|
774
|
+
|
775
|
+
<h2>Stdlib compatibility issues</h2>
|
776
|
+
|
777
|
+
<h3><code class="language-plaintext highlighter-rouge">ext/readline</code> is retired</h3>
|
778
|
+
|
779
|
+
<ul>
|
780
|
+
<li>We have <code class="language-plaintext highlighter-rouge">reline</code> that is pure Ruby implementation compatible with <code class="language-plaintext highlighter-rouge">ext/readline</code> API. We rely on <code class="language-plaintext highlighter-rouge">reline</code> in the future. If you need to use <code class="language-plaintext highlighter-rouge">ext/readline</code>, you can install <code class="language-plaintext highlighter-rouge">ext/readline</code> via rubygems.org with <code class="language-plaintext highlighter-rouge">gem install readline-ext</code>.</li>
|
781
|
+
<li>We no longer need to install libraries like <code class="language-plaintext highlighter-rouge">libreadline</code> or <code class="language-plaintext highlighter-rouge">libedit</code>.</li>
|
782
|
+
</ul>
|
783
|
+
|
784
|
+
<h2>C API updates</h2>
|
785
|
+
|
786
|
+
<h3>Updated C APIs</h3>
|
787
|
+
|
788
|
+
<p>The following APIs are updated.</p>
|
789
|
+
|
790
|
+
<h3>Removed C APIs</h3>
|
791
|
+
|
792
|
+
<p>The following deprecated APIs are removed.</p>
|
793
|
+
|
794
|
+
<h2>Standard library updates</h2>
|
795
|
+
|
796
|
+
<p>RubyGems and Bundler warn if users require gem that is scheduled to become the bundled gems in the future version of Ruby.</p>
|
797
|
+
|
798
|
+
<p>Targeted libraries are:</p>
|
799
|
+
<ul>
|
800
|
+
<li>abbrev</li>
|
801
|
+
<li>base64</li>
|
802
|
+
<li>bigdecimal</li>
|
803
|
+
<li>csv</li>
|
804
|
+
<li>drb</li>
|
805
|
+
<li>getoptlong</li>
|
806
|
+
<li>mutex_m</li>
|
807
|
+
<li>nkf</li>
|
808
|
+
<li>observer</li>
|
809
|
+
<li>racc</li>
|
810
|
+
<li>resolv-replace</li>
|
811
|
+
<li>rinda</li>
|
812
|
+
<li>syslog</li>
|
813
|
+
</ul>
|
814
|
+
|
815
|
+
<p>The following default gem is added.</p>
|
816
|
+
|
817
|
+
<ul>
|
818
|
+
<li>prism 0.15.1</li>
|
819
|
+
</ul>
|
820
|
+
|
821
|
+
<p>The following default gems are updated.</p>
|
822
|
+
|
823
|
+
<ul>
|
824
|
+
<li>RubyGems 3.5.0.dev</li>
|
825
|
+
<li>base64 0.2.0</li>
|
826
|
+
<li>benchmark 0.3.0</li>
|
827
|
+
<li>bigdecimal 3.1.5</li>
|
828
|
+
<li>bundler 2.5.0.dev</li>
|
829
|
+
<li>cgi 0.4.0</li>
|
830
|
+
<li>csv 3.2.8</li>
|
831
|
+
<li>date 3.3.4</li>
|
832
|
+
<li>delegate 0.3.1</li>
|
833
|
+
<li>drb 2.2.0</li>
|
834
|
+
<li>english 0.8.0</li>
|
835
|
+
<li>erb 4.0.3</li>
|
836
|
+
<li>etc 1.4.3.dev.1</li>
|
837
|
+
<li>fcntl 1.1.0</li>
|
838
|
+
<li>fiddle 1.1.2</li>
|
839
|
+
<li>fileutils 1.7.2</li>
|
840
|
+
<li>find 0.2.0</li>
|
841
|
+
<li>getoptlong 0.2.1</li>
|
842
|
+
<li>io-console 0.6.1.dev</li>
|
843
|
+
<li>irb 1.8.3</li>
|
844
|
+
<li>logger 1.6.0</li>
|
845
|
+
<li>mutex_m 0.2.0</li>
|
846
|
+
<li>net-http 0.4.0</li>
|
847
|
+
<li>net-protocol 0.2.2</li>
|
848
|
+
<li>nkf 0.1.3</li>
|
849
|
+
<li>observer 0.1.2</li>
|
850
|
+
<li>open-uri 0.4.0</li>
|
851
|
+
<li>open3 0.2.0</li>
|
852
|
+
<li>openssl 3.2.0</li>
|
853
|
+
<li>optparse 0.4.0</li>
|
854
|
+
<li>ostruct 0.6.0</li>
|
855
|
+
<li>pathname 0.3.0</li>
|
856
|
+
<li>pp 0.5.0</li>
|
857
|
+
<li>prettyprint 0.2.0</li>
|
858
|
+
<li>pstore 0.1.3</li>
|
859
|
+
<li>psych 5.1.1.1</li>
|
860
|
+
<li>rdoc 6.6.0</li>
|
861
|
+
<li>reline 0.3.9</li>
|
862
|
+
<li>rinda 0.2.0</li>
|
863
|
+
<li>securerandom 0.3.0</li>
|
864
|
+
<li>shellwords 0.2.0</li>
|
865
|
+
<li>singleton 0.2.0</li>
|
866
|
+
<li>stringio 3.0.9</li>
|
867
|
+
<li>strscan 3.0.7</li>
|
868
|
+
<li>syntax_suggest 1.1.0</li>
|
869
|
+
<li>tempfile 0.2.0</li>
|
870
|
+
<li>time 0.3.0</li>
|
871
|
+
<li>timeout 0.4.1</li>
|
872
|
+
<li>tmpdir 0.2.0</li>
|
873
|
+
<li>tsort 0.2.0</li>
|
874
|
+
<li>un 0.3.0</li>
|
875
|
+
<li>uri 0.13.0</li>
|
876
|
+
<li>weakref 0.1.3</li>
|
877
|
+
<li>win32ole 1.8.10</li>
|
878
|
+
<li>yaml 0.3.0</li>
|
879
|
+
<li>zlib 3.1.0</li>
|
880
|
+
</ul>
|
881
|
+
|
882
|
+
<p>The following bundled gem is promoted from default gems.</p>
|
883
|
+
|
884
|
+
<ul>
|
885
|
+
<li>racc 1.7.3</li>
|
886
|
+
</ul>
|
887
|
+
|
888
|
+
<p>The following bundled gems are updated.</p>
|
889
|
+
|
890
|
+
<ul>
|
891
|
+
<li>minitest 5.20.0</li>
|
892
|
+
<li>rake 13.1.0</li>
|
893
|
+
<li>test-unit 3.6.1</li>
|
894
|
+
<li>rexml 3.2.6</li>
|
895
|
+
<li>rss 0.3.0</li>
|
896
|
+
<li>net-imap 0.4.4</li>
|
897
|
+
<li>net-smtp 0.4.0</li>
|
898
|
+
<li>rbs 3.2.2</li>
|
899
|
+
<li>typeprof 0.21.8</li>
|
900
|
+
<li>debug 1.8.0</li>
|
901
|
+
</ul>
|
902
|
+
|
903
|
+
<p>See GitHub releases like <a href="https://github.com/ruby/logger/releases">Logger</a> or
|
904
|
+
changelog for details of the default gems or bundled gems.</p>
|
905
|
+
|
906
|
+
<p>See <a href="https://github.com/ruby/ruby/blob/v3_3_0_rc1/NEWS.md">NEWS</a>
|
907
|
+
or <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_rc1">commit logs</a>
|
908
|
+
for more details.</p>
|
909
|
+
|
910
|
+
<p>With those changes, <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_rc1#file_bucket">5414 files changed, 306141 insertions(+), 183575 deletions(-)</a>
|
911
|
+
since Ruby 3.2.0!</p>
|
912
|
+
|
913
|
+
<h2>Download</h2>
|
914
|
+
|
915
|
+
<ul>
|
916
|
+
<li>
|
917
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.tar.gz</a></p>
|
918
|
+
|
919
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 21783575
|
920
|
+
SHA1: c75a860e06f27b7f69b874757417277c21d1d3f4
|
921
|
+
SHA256: c4ff82395a90ef76c7f906b7687026e0ab96b094dcf3a532d9ab97784a073222
|
922
|
+
SHA512: 265fb2ffe55af47d8349edffcebe749cc170291227cef55529fe4e67363e4e84b88daa34ffb5364a99c8a0e32110266a34c9a11d62f3bd6f6d47fa76eca641f4
|
923
|
+
</code></pre></div> </div>
|
924
|
+
</li>
|
925
|
+
<li>
|
926
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.tar.xz</a></p>
|
927
|
+
|
928
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 16163884
|
929
|
+
SHA1: 26503f9bdc7d0a05aaa9836f54d3aa9e74a9ead9
|
930
|
+
SHA256: 051815637f1fa75a1edf2c54b66d5d5b69563daad777da8dc39543b7754b5290
|
931
|
+
SHA512: 82f4acfaad1dc47db27ee3eb952481a95b3474a98059e9e9f5ceb035b690d1faabe99f2ec52371c4089ed1615eb10c395f029088418fec4d26399b65b4f259b9
|
932
|
+
</code></pre></div> </div>
|
933
|
+
</li>
|
934
|
+
<li>
|
935
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.zip">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-rc1.zip</a></p>
|
936
|
+
|
937
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 26735443
|
938
|
+
SHA1: 35583453a7734216b08829ef0ec9ea1bc0d4ae7f
|
939
|
+
SHA256: 56dd82e1dd714f2889ca975ae7befbe005675de08839c2cc4a484de2ae65201c
|
940
|
+
SHA512: 7fbe414c230aedc9f364512bcbc213038f8f6e4268929a559d2527e2f3e32a140b394e37098ab7e59161236eca8b89cc9e52d73a3be8d7bd44faa91681483f5d
|
941
|
+
</code></pre></div> </div>
|
942
|
+
</li>
|
943
|
+
</ul>
|
944
|
+
|
945
|
+
<h2>What is Ruby</h2>
|
946
|
+
|
947
|
+
<p>Ruby was first developed by Matz (Yukihiro Matsumoto) in 1993,
|
948
|
+
and is now developed as Open Source. It runs on multiple platforms
|
949
|
+
and is used all over the world especially for web development.</p>
|
950
|
+
|
951
|
+
<p>Posted by naruse on 11 Dec 2023</p></description>
|
952
|
+
<pubDate>Mon, 11 Dec 2023 00:00:00 +0000</pubDate>
|
953
|
+
<guid>https://www.ruby-lang.org/en/news/2023/12/11/ruby-3-3-0-rc1-released/</guid>
|
954
|
+
<link>https://www.ruby-lang.org/en/news/2023/12/11/ruby-3-3-0-rc1-released/</link>
|
955
|
+
</item>
|
956
|
+
|
957
|
+
<item>
|
958
|
+
<title>Ruby 3.3.0-preview3 Released</title>
|
959
|
+
<description>
|
960
|
+
<p>We are pleased to announce the release of Ruby 3.3.0-preview3. Ruby 3.3 adds a new parser named Prism, uses Lrama as a parser generator, adds a new pure-Ruby JIT compiler named RJIT, and many performance improvements especially YJIT.</p>
|
961
|
+
|
962
|
+
<h2>Prism</h2>
|
963
|
+
|
964
|
+
<ul>
|
965
|
+
<li>Introduced <a href="https://github.com/ruby/prism">the Prism parser</a> as a default gem
|
966
|
+
<ul>
|
967
|
+
<li>Prism is a portable, error tolerant, and maintainable recursive descent parser for the Ruby language</li>
|
968
|
+
</ul>
|
969
|
+
</li>
|
970
|
+
<li>Prism is production ready and actively maintained, you can use it in place of Ripper
|
971
|
+
<ul>
|
972
|
+
<li>There is <a href="https://ruby.github.io/prism/">extensive documentation</a> on how to use Prism</li>
|
973
|
+
<li>Prism is both a C library that will be used internally by CRuby and a Ruby gem that can be used by any tooling which needs to parse Ruby code</li>
|
974
|
+
<li>Notable methods in the Prism API are:
|
975
|
+
<ul>
|
976
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse(source)</code> which returns the AST as part of a ParseResult</li>
|
977
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.dump(source)</code> which returns the serialized AST as a String</li>
|
978
|
+
<li><code class="language-plaintext highlighter-rouge">Prism.parse_comments(source)</code> which returns the comments</li>
|
979
|
+
</ul>
|
980
|
+
</li>
|
981
|
+
</ul>
|
982
|
+
</li>
|
983
|
+
<li>You can make pull requests or issues directly on <a href="https://github.com/ruby/prism">the Prism repository</a> if you are interested in contributing</li>
|
984
|
+
</ul>
|
985
|
+
|
986
|
+
<h2>Use Lrama instead of Bison</h2>
|
987
|
+
|
988
|
+
<ul>
|
989
|
+
<li>Replace Bison with <a href="https://github.com/yui-knk/lrama">Lrama LALR parser generator</a> <a href="https://bugs.ruby-lang.org/issues/19637">Feature #19637</a>
|
990
|
+
<ul>
|
991
|
+
<li>If you have interest, please see <a href="https://rubykaigi.org/2023/presentations/spikeolaf.html">The future vision of Ruby Parser</a></li>
|
992
|
+
<li>Lrama internal parser is replaced with LR parser generated by Racc for maintainability</li>
|
993
|
+
<li>Parameterizing Rules <code class="language-plaintext highlighter-rouge">(?, *, +)</code> are supported, it will be used in Ruby parse.y</li>
|
994
|
+
</ul>
|
995
|
+
</li>
|
996
|
+
</ul>
|
997
|
+
|
998
|
+
<h2>RJIT</h2>
|
999
|
+
|
1000
|
+
<ul>
|
1001
|
+
<li>Introduced a pure-Ruby JIT compiler RJIT and replaced MJIT.
|
1002
|
+
<ul>
|
1003
|
+
<li>RJIT supports only x86-64 architecture on Unix platforms.</li>
|
1004
|
+
<li>Unlike MJIT, it doesn’t require a C compiler at runtime.</li>
|
1005
|
+
</ul>
|
1006
|
+
</li>
|
1007
|
+
<li>RJIT exists only for experimental purposes.
|
1008
|
+
<ul>
|
1009
|
+
<li>You should keep using YJIT in production.</li>
|
1010
|
+
</ul>
|
1011
|
+
</li>
|
1012
|
+
<li>If you are interested in developing JIT for Ruby, please check out <a href="https://rubykaigi.org/2023/presentations/k0kubun.html#day3">k0kubun’s presentation on Day 3 of RubyKaigi</a>.</li>
|
1013
|
+
</ul>
|
1014
|
+
|
1015
|
+
<h2>YJIT</h2>
|
1016
|
+
|
1017
|
+
<ul>
|
1018
|
+
<li>Major performance improvements over 3.2
|
1019
|
+
<ul>
|
1020
|
+
<li>Support for splat and rest arguments has been improved.</li>
|
1021
|
+
<li>Registers are allocated for stack operations of the virtual machine.</li>
|
1022
|
+
<li>More calls with optional arguments are compiled.</li>
|
1023
|
+
<li>Exception handlers are also compiled.</li>
|
1024
|
+
<li>Instance variables no longer exit to the interpreter
|
1025
|
+
with megamorphic object shapes.</li>
|
1026
|
+
<li>Unsupported call types no longer exit to the interpreter.</li>
|
1027
|
+
<li><code class="language-plaintext highlighter-rouge">Integer#!=</code>, <code class="language-plaintext highlighter-rouge">String#!=</code>, <code class="language-plaintext highlighter-rouge">Kernel#block_given?</code>, <code class="language-plaintext highlighter-rouge">Kernel#is_a?</code>,
|
1028
|
+
<code class="language-plaintext highlighter-rouge">Kernel#instance_of?</code>, <code class="language-plaintext highlighter-rouge">Module#===</code> are specially optimized.</li>
|
1029
|
+
<li>Now more than 3x faster than the interpreter on optcarrot!</li>
|
1030
|
+
</ul>
|
1031
|
+
</li>
|
1032
|
+
<li>Significantly improved memory usage over 3.2
|
1033
|
+
<ul>
|
1034
|
+
<li>Metadata for compiled code uses a lot less memory.</li>
|
1035
|
+
<li>Generate more compact code on ARM64</li>
|
1036
|
+
</ul>
|
1037
|
+
</li>
|
1038
|
+
<li>Compilation speed is now slightly faster than 3.2.</li>
|
1039
|
+
<li>Add <code class="language-plaintext highlighter-rouge">RubyVM::YJIT.enable</code> that can enable YJIT at run-time
|
1040
|
+
<ul>
|
1041
|
+
<li>You can start YJIT without modifying command-line arguments or environment variables.</li>
|
1042
|
+
<li>This can also be used to enable YJIT only once your application is
|
1043
|
+
done booting. <code class="language-plaintext highlighter-rouge">--yjit-disable</code> can be used if you want to use other
|
1044
|
+
YJIT options while disabling YJIT at boot.</li>
|
1045
|
+
</ul>
|
1046
|
+
</li>
|
1047
|
+
<li>Option to disable code GC and treat <code class="language-plaintext highlighter-rouge">--yjit-exec-mem-size</code> as a hard limit
|
1048
|
+
<ul>
|
1049
|
+
<li>Can produce better copy-on-write behavior on servers using unicorn and forking</li>
|
1050
|
+
</ul>
|
1051
|
+
</li>
|
1052
|
+
<li><code class="language-plaintext highlighter-rouge">ratio_in_yjit</code> stat produced by <code class="language-plaintext highlighter-rouge">--yjit-stats</code> is now available in release builds,
|
1053
|
+
a special stats or dev build is no longer required to access most stats.</li>
|
1054
|
+
<li>Exit tracing option now supports sampling
|
1055
|
+
<ul>
|
1056
|
+
<li><code class="language-plaintext highlighter-rouge">--trace-exits-sample-rate=N</code></li>
|
1057
|
+
</ul>
|
1058
|
+
</li>
|
1059
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-perf</code> is added to facilitate profiling with Linux perf.</li>
|
1060
|
+
<li>More thorough testing and multiple bug fixes</li>
|
1061
|
+
</ul>
|
1062
|
+
|
1063
|
+
<h3>M:N thread scheduler</h3>
|
1064
|
+
|
1065
|
+
<ul>
|
1066
|
+
<li>M:N thread scheduler was introduced. <a href="https://bugs.ruby-lang.org/issues/19842">[Feature #19842]</a>
|
1067
|
+
<ul>
|
1068
|
+
<li>M Ruby threads are managed by N native threads (OS threads) so the thread creation and management cost are reduced.</li>
|
1069
|
+
<li>It can break C-extension compatibility so that M:N thread scheduler is disabled on the main Ractor by default.
|
1070
|
+
<ul>
|
1071
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MN_THREADS=1</code> environment variable enables M:N threads on the main Ractor.</li>
|
1072
|
+
<li>M:N threads are enabled on non-main Ractors.</li>
|
1073
|
+
</ul>
|
1074
|
+
</li>
|
1075
|
+
<li><code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU=n</code> environment variable sets maximum number of <code class="language-plaintext highlighter-rouge">N</code> (maximum number of native threads). The default value is 8.
|
1076
|
+
<ul>
|
1077
|
+
<li>Since only one Ruby thread per Ractor can run at the same time, the number of native threads will be used, which is the smaller of the number specified in <code class="language-plaintext highlighter-rouge">RUBY_MAX_CPU</code> and the number of running Ractors. So that single Ractor applications (most of applications) will use 1 native thread.</li>
|
1078
|
+
<li>To support blocking operations, more than <code class="language-plaintext highlighter-rouge">N</code> native threads can be used.</li>
|
1079
|
+
</ul>
|
1080
|
+
</li>
|
1081
|
+
</ul>
|
1082
|
+
</li>
|
1083
|
+
</ul>
|
1084
|
+
|
1085
|
+
<h2>Other Notable New Features</h2>
|
1086
|
+
|
1087
|
+
<h3>Language</h3>
|
1088
|
+
|
1089
|
+
<h2>Performance improvements</h2>
|
1090
|
+
|
1091
|
+
<ul>
|
1092
|
+
<li><code class="language-plaintext highlighter-rouge">defined?(@ivar)</code> is optimized with Object Shapes.</li>
|
1093
|
+
<li>Name resolution such as <code class="language-plaintext highlighter-rouge">Socket.getaddrinfo</code> can now be interrupted (in environments where pthreads are available). <a href="https://bugs.ruby-lang.org/issues/19965">Feature #19965</a>
|
1094
|
+
<ul>
|
1095
|
+
<li>For this purpose, a pthread is now created whenever calling getaddrinfo or getnameinfo. This incurs some overhead in name resolution (about 2.5x in our experiments). We do not expect the name resolution overhead to be a problem for most applications, but if you observe such, or if you see unexpected affects that you believe are due to this change, please report them.</li>
|
1096
|
+
</ul>
|
1097
|
+
</li>
|
1098
|
+
<li>Environment variable <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_REMEMBERED_WB_UNPROTECTED_OBJECTS_LIMIT_RATIO</code> has been added. <a href="https://bugs.ruby-lang.org/issues/19571">Feature #19571</a></li>
|
1099
|
+
<li>Children of old objects are no longer immediately promoted to the old generation in the garbage collector. <a href="https://bugs.ruby-lang.org/issues/19678">Feature #19678</a></li>
|
1100
|
+
<li>Support for weak references has been added to the garbage collector. <a href="https://bugs.ruby-lang.org/issues/19783">Feature #19783</a></li>
|
1101
|
+
</ul>
|
1102
|
+
|
1103
|
+
<h2>Other notable changes since 3.2</h2>
|
1104
|
+
|
1105
|
+
<h3>IRB</h3>
|
1106
|
+
|
1107
|
+
<p>IRB has received several enhancements, including but not limited to:</p>
|
1108
|
+
|
1109
|
+
<ul>
|
1110
|
+
<li>Advanced <code class="language-plaintext highlighter-rouge">irb:rdbg</code> integration that provides an equivalent debugging experience to <code class="language-plaintext highlighter-rouge">pry-byebug</code> (<a href="https://github.com/ruby/irb#debugging-with-irb">doc</a>).</li>
|
1111
|
+
<li>Pager support for <code class="language-plaintext highlighter-rouge">ls</code>, <code class="language-plaintext highlighter-rouge">show_source</code> and <code class="language-plaintext highlighter-rouge">show_cmds</code> commands.</li>
|
1112
|
+
<li>More accurate and helpful information provided by the <code class="language-plaintext highlighter-rouge">ls</code> and <code class="language-plaintext highlighter-rouge">show_source</code> commands.</li>
|
1113
|
+
<li>Experimental autocompletion using type analysis (<a href="https://github.com/ruby/irb#type-based-completion">doc</a>).</li>
|
1114
|
+
<li>It is now possible to change the font color and font style in the completion dialog by a newly introduced class Reline::Face (<a href="https://github.com/ruby/ruby/blob/master/doc/reline/face.md">doc</a>)</li>
|
1115
|
+
</ul>
|
1116
|
+
|
1117
|
+
<p>In addition, IRB has also undergone extensive refactoring and received dozens of bug fixes to facilitate easier future enhancements.</p>
|
1118
|
+
|
1119
|
+
<h2>Compatibility issues</h2>
|
1120
|
+
|
1121
|
+
<p>Note: Excluding feature bug fixes.</p>
|
1122
|
+
|
1123
|
+
<h3>Removed constants</h3>
|
1124
|
+
|
1125
|
+
<p>The following deprecated constants are removed.</p>
|
1126
|
+
|
1127
|
+
<h3>Removed methods</h3>
|
1128
|
+
|
1129
|
+
<p>The following deprecated methods are removed.</p>
|
1130
|
+
|
1131
|
+
<h3>Removed environment variables</h3>
|
1132
|
+
|
1133
|
+
<p>The following deprecated environment variables are removed.</p>
|
1134
|
+
|
1135
|
+
<ul>
|
1136
|
+
<li>Environment variable <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_INIT_SLOTS</code> has been deprecated and is a no-op. Please use environment variables <code class="language-plaintext highlighter-rouge">RUBY_GC_HEAP_{0,1,2,3,4}_INIT_SLOTS</code> instead. <a href="https://bugs.ruby-lang.org/issues/19785">Feature #19785</a></li>
|
1137
|
+
</ul>
|
1138
|
+
|
1139
|
+
<h2>Stdlib compatibility issues</h2>
|
1140
|
+
|
1141
|
+
<h3><code class="language-plaintext highlighter-rouge">ext/readline</code> is retired</h3>
|
1142
|
+
|
1143
|
+
<ul>
|
1144
|
+
<li>We have <code class="language-plaintext highlighter-rouge">reline</code> that is pure Ruby implementation compatible with <code class="language-plaintext highlighter-rouge">ext/readline</code> API. We rely on <code class="language-plaintext highlighter-rouge">reline</code> in the future. If you need to use <code class="language-plaintext highlighter-rouge">ext/readline</code>, you can install <code class="language-plaintext highlighter-rouge">ext/readline</code> via rubygems.org with <code class="language-plaintext highlighter-rouge">gem install readline-ext</code>.</li>
|
1145
|
+
<li>We no longer need to install libraries like <code class="language-plaintext highlighter-rouge">libreadline</code> or <code class="language-plaintext highlighter-rouge">libedit</code>.</li>
|
1146
|
+
</ul>
|
1147
|
+
|
1148
|
+
<h2>C API updates</h2>
|
1149
|
+
|
1150
|
+
<h3>Updated C APIs</h3>
|
1151
|
+
|
1152
|
+
<p>The following APIs are updated.</p>
|
1153
|
+
|
1154
|
+
<h3>Removed C APIs</h3>
|
1155
|
+
|
1156
|
+
<p>The following deprecated APIs are removed.</p>
|
1157
|
+
|
1158
|
+
<h2>Standard library updates</h2>
|
1159
|
+
|
1160
|
+
<p>RubyGems and Bundler warn if users require gem that is scheduled to become the bundled gems in the future version of Ruby.</p>
|
1161
|
+
|
1162
|
+
<p>Targeted libraries are:</p>
|
1163
|
+
<ul>
|
1164
|
+
<li>abbrev</li>
|
1165
|
+
<li>base64</li>
|
1166
|
+
<li>bigdecimal</li>
|
1167
|
+
<li>csv</li>
|
1168
|
+
<li>drb</li>
|
1169
|
+
<li>getoptlong</li>
|
1170
|
+
<li>mutex_m</li>
|
1171
|
+
<li>nkf</li>
|
1172
|
+
<li>observer</li>
|
1173
|
+
<li>racc</li>
|
1174
|
+
<li>resolv-replace</li>
|
1175
|
+
<li>rinda</li>
|
1176
|
+
<li>syslog</li>
|
1177
|
+
</ul>
|
1178
|
+
|
1179
|
+
<p>The following default gem is added.</p>
|
1180
|
+
|
1181
|
+
<ul>
|
1182
|
+
<li>prism 0.15.1</li>
|
1183
|
+
</ul>
|
1184
|
+
|
1185
|
+
<p>The following default gems are updated.</p>
|
1186
|
+
|
1187
|
+
<ul>
|
1188
|
+
<li>RubyGems 3.5.0.dev</li>
|
1189
|
+
<li>base64 0.2.0</li>
|
1190
|
+
<li>benchmark 0.3.0</li>
|
1191
|
+
<li>bigdecimal 3.1.5</li>
|
1192
|
+
<li>bundler 2.5.0.dev</li>
|
1193
|
+
<li>cgi 0.4.0</li>
|
1194
|
+
<li>csv 3.2.8</li>
|
1195
|
+
<li>date 3.3.4</li>
|
1196
|
+
<li>delegate 0.3.1</li>
|
1197
|
+
<li>drb 2.2.0</li>
|
1198
|
+
<li>english 0.8.0</li>
|
1199
|
+
<li>erb 4.0.3</li>
|
1200
|
+
<li>etc 1.4.3.dev.1</li>
|
1201
|
+
<li>fcntl 1.1.0</li>
|
1202
|
+
<li>fiddle 1.1.2</li>
|
1203
|
+
<li>fileutils 1.7.2</li>
|
1204
|
+
<li>find 0.2.0</li>
|
1205
|
+
<li>getoptlong 0.2.1</li>
|
1206
|
+
<li>io-console 0.6.1.dev</li>
|
1207
|
+
<li>irb 1.8.3</li>
|
1208
|
+
<li>logger 1.6.0</li>
|
1209
|
+
<li>mutex_m 0.2.0</li>
|
1210
|
+
<li>net-http 0.4.0</li>
|
1211
|
+
<li>net-protocol 0.2.2</li>
|
1212
|
+
<li>nkf 0.1.3</li>
|
1213
|
+
<li>observer 0.1.2</li>
|
1214
|
+
<li>open-uri 0.4.0</li>
|
1215
|
+
<li>open3 0.2.0</li>
|
1216
|
+
<li>openssl 3.2.0</li>
|
1217
|
+
<li>optparse 0.4.0</li>
|
1218
|
+
<li>ostruct 0.6.0</li>
|
1219
|
+
<li>pathname 0.3.0</li>
|
1220
|
+
<li>pp 0.5.0</li>
|
1221
|
+
<li>prettyprint 0.2.0</li>
|
1222
|
+
<li>pstore 0.1.3</li>
|
1223
|
+
<li>psych 5.1.1.1</li>
|
1224
|
+
<li>rdoc 6.6.0</li>
|
1225
|
+
<li>reline 0.3.9</li>
|
1226
|
+
<li>rinda 0.2.0</li>
|
1227
|
+
<li>securerandom 0.3.0</li>
|
1228
|
+
<li>shellwords 0.2.0</li>
|
1229
|
+
<li>singleton 0.2.0</li>
|
1230
|
+
<li>stringio 3.0.9</li>
|
1231
|
+
<li>strscan 3.0.7</li>
|
1232
|
+
<li>syntax_suggest 1.1.0</li>
|
1233
|
+
<li>tempfile 0.2.0</li>
|
1234
|
+
<li>time 0.3.0</li>
|
1235
|
+
<li>timeout 0.4.1</li>
|
1236
|
+
<li>tmpdir 0.2.0</li>
|
1237
|
+
<li>tsort 0.2.0</li>
|
1238
|
+
<li>un 0.3.0</li>
|
1239
|
+
<li>uri 0.13.0</li>
|
1240
|
+
<li>weakref 0.1.3</li>
|
1241
|
+
<li>win32ole 1.8.10</li>
|
1242
|
+
<li>yaml 0.3.0</li>
|
1243
|
+
<li>zlib 3.1.0</li>
|
1244
|
+
</ul>
|
1245
|
+
|
1246
|
+
<p>The following bundled gem is promoted from default gems.</p>
|
1247
|
+
|
1248
|
+
<ul>
|
1249
|
+
<li>racc 1.7.3</li>
|
1250
|
+
</ul>
|
1251
|
+
|
1252
|
+
<p>The following bundled gems are updated.</p>
|
1253
|
+
|
1254
|
+
<ul>
|
1255
|
+
<li>minitest 5.20.0</li>
|
1256
|
+
<li>rake 13.1.0</li>
|
1257
|
+
<li>test-unit 3.6.1</li>
|
1258
|
+
<li>rexml 3.2.6</li>
|
1259
|
+
<li>rss 0.3.0</li>
|
1260
|
+
<li>net-imap 0.4.4</li>
|
1261
|
+
<li>net-smtp 0.4.0</li>
|
1262
|
+
<li>rbs 3.2.2</li>
|
1263
|
+
<li>typeprof 0.21.8</li>
|
1264
|
+
<li>debug 1.8.0</li>
|
1265
|
+
</ul>
|
1266
|
+
|
1267
|
+
<p>See GitHub releases like <a href="https://github.com/ruby/logger/releases">Logger</a> or
|
1268
|
+
changelog for details of the default gems or bundled gems.</p>
|
1269
|
+
|
1270
|
+
<p>See <a href="https://github.com/ruby/ruby/blob/v3_3_0_preview3/NEWS.md">NEWS</a>
|
1271
|
+
or <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview3">commit logs</a>
|
1272
|
+
for more details.</p>
|
1273
|
+
|
1274
|
+
<p>With those changes, <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview3#file_bucket">5207 files changed, 284820 insertions(+), 174773 deletions(-)</a>
|
1275
|
+
since Ruby 3.2.0!</p>
|
1276
|
+
|
1277
|
+
<h2>Download</h2>
|
1278
|
+
|
1279
|
+
<ul>
|
1280
|
+
<li>
|
1281
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.tar.gz</a></p>
|
1282
|
+
|
1283
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 21550473
|
1284
|
+
SHA1: 2811f191d66dffee0206771873bd990857ae4ed6
|
1285
|
+
SHA256: 0969141be92e67e0edb84a8fb354acc98f01bd78e602a23a0f136045c82f4809
|
1286
|
+
SHA512: 94db07a6958c09809b2e5b597fa55a121074e8bacb3bf588c83cf0d35b07a8b070172035a49d1abf0d8ee364a9ace824f34e677f7327ffe1acdbab0938ac49c4
|
1287
|
+
</code></pre></div> </div>
|
1288
|
+
</li>
|
1289
|
+
<li>
|
1290
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.tar.xz</a></p>
|
1291
|
+
|
1292
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 15970144
|
1293
|
+
SHA1: 496600612605f8ebeb955255e98bac73a4cbc045
|
1294
|
+
SHA256: f79afcf122dc7d04fe26cfa4436b9c488b21766fc54b0d2dfb2ba41cd0cdd355
|
1295
|
+
SHA512: d7ab0d703e7884efd31045933409cd68fac1d9941963537ccc8e309ca7c8bee8500a68182135acba22cbdbf4a8ae99f39bf7f0925273eb4fbc3728c0c1ba0c19
|
1296
|
+
</code></pre></div> </div>
|
1297
|
+
</li>
|
1298
|
+
<li>
|
1299
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.zip">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview3.zip</a></p>
|
1300
|
+
|
1301
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 26618303
|
1302
|
+
SHA1: 6a13e08c7e484d42037c1e2c87c5d0e220f893a0
|
1303
|
+
SHA256: c35bf637a647c2f60148368ffb374db5c258570911794f46b6dfdb98ebfe95d9
|
1304
|
+
SHA512: c4ef2cdcdadeb85ad1d42aedc97f9f3d609b3b01eea2319451cf92c81bd31ae8129b7c91fc68571469dd888c01ea0f48f73234b965db17f6a87404ca382f7794
|
1305
|
+
</code></pre></div> </div>
|
1306
|
+
</li>
|
1307
|
+
</ul>
|
1308
|
+
|
1309
|
+
<h2>What is Ruby</h2>
|
1310
|
+
|
1311
|
+
<p>Ruby was first developed by Matz (Yukihiro Matsumoto) in 1993,
|
1312
|
+
and is now developed as Open Source. It runs on multiple platforms
|
1313
|
+
and is used all over the world especially for web development.</p>
|
1314
|
+
|
1315
|
+
<p>Posted by naruse on 12 Nov 2023</p></description>
|
1316
|
+
<pubDate>Sun, 12 Nov 2023 00:00:00 +0000</pubDate>
|
1317
|
+
<guid>https://www.ruby-lang.org/en/news/2023/11/12/ruby-3-3-0-preview3-released/</guid>
|
1318
|
+
<link>https://www.ruby-lang.org/en/news/2023/11/12/ruby-3-3-0-preview3-released/</link>
|
1319
|
+
</item>
|
1320
|
+
|
1321
|
+
<item>
|
1322
|
+
<title>Ruby 3.3.0-preview2 Released</title>
|
1323
|
+
<description>
|
1324
|
+
<p>We are pleased to announce the release of Ruby 3.3.0-preview2. Ruby 3.3 adds a new pure-Ruby JIT compiler named RJIT, uses Lrama as a parser generator, and many performance improvements especially YJIT.</p>
|
1325
|
+
|
1326
|
+
<h2>RJIT</h2>
|
1327
|
+
|
1328
|
+
<ul>
|
1329
|
+
<li>Introduced a pure-Ruby JIT compiler RJIT and replaced MJIT.
|
1330
|
+
<ul>
|
1331
|
+
<li>RJIT supports only x86_64 architecture on Unix platforms.</li>
|
1332
|
+
<li>Unlike MJIT, it doesn’t require a C compiler at runtime.</li>
|
1333
|
+
</ul>
|
1334
|
+
</li>
|
1335
|
+
<li>RJIT exists only for experimental purposes.
|
1336
|
+
<ul>
|
1337
|
+
<li>You should keep using YJIT in production.</li>
|
1338
|
+
</ul>
|
1339
|
+
</li>
|
1340
|
+
<li>If you are interested in developing JIT for Ruby, please check out <a href="https://rubykaigi.org/2023/presentations/k0kubun.html#day3">k0kubun’s presentation on Day 3 of RubyKaigi</a>.</li>
|
1341
|
+
</ul>
|
1342
|
+
|
1343
|
+
<h2>Use Lrama instead of Bison</h2>
|
1344
|
+
|
1345
|
+
<ul>
|
1346
|
+
<li>Replace Bison with <a href="https://github.com/yui-knk/lrama">Lrama LALR parser generator</a> <a href="https://bugs.ruby-lang.org/issues/19637">Feature #19637</a>
|
1347
|
+
<ul>
|
1348
|
+
<li>If you have interest, please see <a href="https://rubykaigi.org/2023/presentations/spikeolaf.html">The future vision of Ruby Parser</a></li>
|
1349
|
+
</ul>
|
1350
|
+
</li>
|
1351
|
+
</ul>
|
1352
|
+
|
1353
|
+
<h2>YJIT</h2>
|
1354
|
+
|
1355
|
+
<ul>
|
1356
|
+
<li>Major performance improvements over 3.2
|
1357
|
+
<ul>
|
1358
|
+
<li>Support for splat and rest arguments has been improved.</li>
|
1359
|
+
<li>Registers are allocated for stack operations of the virtual machine.</li>
|
1360
|
+
<li>More calls with optional arguments are compiled.</li>
|
1361
|
+
<li>Exception handlers are also compiled.</li>
|
1362
|
+
<li>Instance variables no longer exit to the interpreter
|
1363
|
+
with megamorphic Object Shapes.</li>
|
1364
|
+
<li>Unsupported call types no longer exit to the interpreter.</li>
|
1365
|
+
<li><code class="language-plaintext highlighter-rouge">Integer#!=</code>, <code class="language-plaintext highlighter-rouge">String#!=</code>, <code class="language-plaintext highlighter-rouge">Kernel#block_given?</code>, <code class="language-plaintext highlighter-rouge">Kernel#is_a?</code>,
|
1366
|
+
<code class="language-plaintext highlighter-rouge">Kernel#instance_of?</code>, <code class="language-plaintext highlighter-rouge">Module#===</code> are specially optimized.</li>
|
1367
|
+
<li>Now more than 3x faster than the interpreter on optcarrot!</li>
|
1368
|
+
</ul>
|
1369
|
+
</li>
|
1370
|
+
<li>Metadata for compiled code uses a lot less memory.</li>
|
1371
|
+
<li>Generate more compact code on ARM64</li>
|
1372
|
+
<li>Option to start YJIT in paused mode and then later enable it manually
|
1373
|
+
<ul>
|
1374
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-pause</code> and <code class="language-plaintext highlighter-rouge">RubyVM::YJIT.resume</code></li>
|
1375
|
+
<li>This can be used to enable YJIT only once your application is done booting</li>
|
1376
|
+
</ul>
|
1377
|
+
</li>
|
1378
|
+
<li><code class="language-plaintext highlighter-rouge">ratio_in_yjit</code> stat produced by <code class="language-plaintext highlighter-rouge">--yjit-stats</code> is now available in release builds,
|
1379
|
+
a special stats or dev build is no longer required.</li>
|
1380
|
+
<li>Exit tracing option now supports sampling
|
1381
|
+
<ul>
|
1382
|
+
<li><code class="language-plaintext highlighter-rouge">--trace-exits-sample-rate=N</code></li>
|
1383
|
+
</ul>
|
1384
|
+
</li>
|
1385
|
+
<li>More thorough testing and multiple bug fixes</li>
|
1386
|
+
</ul>
|
1387
|
+
|
1388
|
+
<h2>Other Notable New Features</h2>
|
1389
|
+
|
1390
|
+
<h3>Language</h3>
|
1391
|
+
|
1392
|
+
<h2>Performance improvements</h2>
|
1393
|
+
|
1394
|
+
<ul>
|
1395
|
+
<li><code class="language-plaintext highlighter-rouge">defined?(@ivar)</code> is optimized with Object Shapes.</li>
|
1396
|
+
</ul>
|
1397
|
+
|
1398
|
+
<h2>Other notable changes since 3.2</h2>
|
1399
|
+
|
1400
|
+
<h3>IRB</h3>
|
1401
|
+
|
1402
|
+
<p>IRB has received several enhancements, including but not limited to:</p>
|
1403
|
+
|
1404
|
+
<ul>
|
1405
|
+
<li>Advanced <code class="language-plaintext highlighter-rouge">irb:rdbg</code> integration that provides an equivalent debugging experience to <code class="language-plaintext highlighter-rouge">pry-byebug</code> (<a href="https://github.com/ruby/irb#debugging-with-irb">doc</a>).</li>
|
1406
|
+
<li>Pager support for commands like <code class="language-plaintext highlighter-rouge">ls</code> and <code class="language-plaintext highlighter-rouge">show_cmds</code>.</li>
|
1407
|
+
<li>More accurate and helpful information provided by the <code class="language-plaintext highlighter-rouge">ls</code> and <code class="language-plaintext highlighter-rouge">show_source</code> commands.</li>
|
1408
|
+
</ul>
|
1409
|
+
|
1410
|
+
<p>In addition, IRB has also undergone extensive refactoring and received dozens of bug fixes to facilitate easier future enhancements.</p>
|
1411
|
+
|
1412
|
+
<h2>Compatibility issues</h2>
|
1413
|
+
|
1414
|
+
<p>Note: Excluding feature bug fixes.</p>
|
1415
|
+
|
1416
|
+
<h3>Removed constants</h3>
|
1417
|
+
|
1418
|
+
<p>The following deprecated constants are removed.</p>
|
1419
|
+
|
1420
|
+
<h3>Removed methods</h3>
|
1421
|
+
|
1422
|
+
<p>The following deprecated methods are removed.</p>
|
1423
|
+
|
1424
|
+
<h2>Stdlib compatibility issues</h2>
|
1425
|
+
|
1426
|
+
<h3><code class="language-plaintext highlighter-rouge">ext/readline</code> is retired</h3>
|
1427
|
+
|
1428
|
+
<ul>
|
1429
|
+
<li>We have <code class="language-plaintext highlighter-rouge">reline</code> that is pure Ruby implementation compatible with <code class="language-plaintext highlighter-rouge">ext/readline</code> API. We rely on <code class="language-plaintext highlighter-rouge">reline</code> in the future. If you need to use <code class="language-plaintext highlighter-rouge">ext/readline</code>, you can install <code class="language-plaintext highlighter-rouge">ext/readline</code> via rubygems.org with <code class="language-plaintext highlighter-rouge">gem install readline-ext</code>.</li>
|
1430
|
+
<li>We no longer need to install libraries like <code class="language-plaintext highlighter-rouge">libreadline</code> or <code class="language-plaintext highlighter-rouge">libedit</code>.</li>
|
1431
|
+
</ul>
|
1432
|
+
|
1433
|
+
<h2>C API updates</h2>
|
1434
|
+
|
1435
|
+
<h3>Updated C APIs</h3>
|
1436
|
+
|
1437
|
+
<p>The following APIs are updated.</p>
|
1438
|
+
|
1439
|
+
<h3>Removed C APIs</h3>
|
1440
|
+
|
1441
|
+
<p>The following deprecated APIs are removed.</p>
|
1442
|
+
|
1443
|
+
<h2>Standard library updates</h2>
|
1444
|
+
|
1445
|
+
<p>RubyGems and Bundler warn if users require gem that is scheduled to become the bundled gems in the future version of Ruby.</p>
|
1446
|
+
|
1447
|
+
<p>The following default gems are updated.</p>
|
1448
|
+
|
1449
|
+
<ul>
|
1450
|
+
<li>RubyGems 3.5.0.dev</li>
|
1451
|
+
<li>bigdecimal 3.1.4</li>
|
1452
|
+
<li>bundler 2.5.0.dev</li>
|
1453
|
+
<li>csv 3.2.8</li>
|
1454
|
+
<li>erb 4.0.3</li>
|
1455
|
+
<li>fiddle 1.1.2</li>
|
1456
|
+
<li>fileutils 1.7.1</li>
|
1457
|
+
<li>irb 1.7.4</li>
|
1458
|
+
<li>nkf 0.1.3</li>
|
1459
|
+
<li>optparse 0.4.0.pre.1</li>
|
1460
|
+
<li>psych 5.1.0</li>
|
1461
|
+
<li>reline 0.3.8</li>
|
1462
|
+
<li>stringio 3.0.9</li>
|
1463
|
+
<li>strscan 3.0.7</li>
|
1464
|
+
<li>syntax_suggest 1.1.0</li>
|
1465
|
+
<li>time 0.2.2</li>
|
1466
|
+
<li>timeout 0.4.0</li>
|
1467
|
+
<li>uri 0.12.2</li>
|
1468
|
+
<li>yarp 0.9.0</li>
|
1469
|
+
</ul>
|
1470
|
+
|
1471
|
+
<p>The following bundled gems are updated.</p>
|
1472
|
+
|
1473
|
+
<ul>
|
1474
|
+
<li>minitest 5.19.0</li>
|
1475
|
+
<li>test-unit 3.6.1</li>
|
1476
|
+
<li>rexml 3.2.6</li>
|
1477
|
+
<li>rss 0.3.0</li>
|
1478
|
+
<li>net-imap 0.3.7</li>
|
1479
|
+
<li>rbs 3.2.1</li>
|
1480
|
+
<li>typeprof 0.21.8</li>
|
1481
|
+
<li>debug 1.8.0</li>
|
1482
|
+
</ul>
|
1483
|
+
|
1484
|
+
<p>The following default gem is now bundled.</p>
|
1485
|
+
|
1486
|
+
<ul>
|
1487
|
+
<li>racc 1.7.1</li>
|
1488
|
+
</ul>
|
1489
|
+
|
1490
|
+
<p>See GitHub releases like <a href="https://github.com/ruby/logger/releases">Logger</a> or
|
1491
|
+
changelog for details of the default gems or bundled gems.</p>
|
1492
|
+
|
1493
|
+
<p>See <a href="https://github.com/ruby/ruby/blob/v3_3_0_preview2/NEWS.md">NEWS</a>
|
1494
|
+
or <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview2">commit logs</a>
|
1495
|
+
for more details.</p>
|
1496
|
+
|
1497
|
+
<p>With those changes, <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview2#file_bucket">4970 files changed, 239635 insertions(+), 165275 deletions(-)</a>
|
1498
|
+
since Ruby 3.2.0!</p>
|
1499
|
+
|
1500
|
+
<h2>Download</h2>
|
1501
|
+
|
1502
|
+
<ul>
|
1503
|
+
<li>
|
1504
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.tar.gz</a></p>
|
1505
|
+
|
1506
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 21074209
|
1507
|
+
SHA1: cf7329019235dc36b8e3f382a8b8b744922b1163
|
1508
|
+
SHA256: 30ce8b0fe11b37b5ac088f5a5765744b935eac45bb89a9e381731533144f5991
|
1509
|
+
SHA512: 1c5a13e519e8487fd40d932b96d14fa729521925c288e7841ab5eada628e506ceca2605bae36eea1aa505d9253383d53cd933b7a4bff96e6de5b1130c7c558e6
|
1510
|
+
</code></pre></div> </div>
|
1511
|
+
</li>
|
1512
|
+
<li>
|
1513
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.tar.xz</a></p>
|
1514
|
+
|
1515
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 15600992
|
1516
|
+
SHA1: 606d6423137a24eef4f6b07d167596b63c7aaa17
|
1517
|
+
SHA256: 62b1c4f586c70bf1cb58f2d909d0d824506315782e835f9dd3fcc0b659a70fc1
|
1518
|
+
SHA512: 5ff609a66b7359006df0d87477cf70e6e26c5f40ced81b8254f8154f4fc82c77fed297471b55706c1a4466f2a4257999e933b2ed085f695ace265757ab9500a2
|
1519
|
+
</code></pre></div> </div>
|
1520
|
+
</li>
|
1521
|
+
<li>
|
1522
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.zip">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview2.zip</a></p>
|
1523
|
+
|
1524
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 26095651
|
1525
|
+
SHA1: 4441cd0db23d133e6e2f7dea28f931a68dac6ca5
|
1526
|
+
SHA256: c9771d24c9b1eab532c04ed076087285601693e4d1c63f131fd078c47c5c0cea
|
1527
|
+
SHA512: bfeed21d011f891fe22510fe7242992c98f7fd2ce863d8be5740f56a34b726134cb3f5304e8b2dcd468fbc939648f10aae482eee15c1bf6c64b705484ed9e197
|
1528
|
+
</code></pre></div> </div>
|
1529
|
+
</li>
|
1530
|
+
</ul>
|
1531
|
+
|
1532
|
+
<h2>What is Ruby</h2>
|
1533
|
+
|
1534
|
+
<p>Ruby was first developed by Matz (Yukihiro Matsumoto) in 1993,
|
1535
|
+
and is now developed as Open Source. It runs on multiple platforms
|
1536
|
+
and is used all over the world especially for web development.</p>
|
1537
|
+
|
1538
|
+
<p>Posted by naruse on 14 Sep 2023</p></description>
|
1539
|
+
<pubDate>Thu, 14 Sep 2023 00:00:00 +0000</pubDate>
|
1540
|
+
<guid>https://www.ruby-lang.org/en/news/2023/09/14/ruby-3-3-0-preview2-released/</guid>
|
1541
|
+
<link>https://www.ruby-lang.org/en/news/2023/09/14/ruby-3-3-0-preview2-released/</link>
|
1542
|
+
</item>
|
1543
|
+
|
1544
|
+
<item>
|
1545
|
+
<title>CVE-2023-36617: ReDoS vulnerability in URI</title>
|
1546
|
+
<description><p>We have released the uri gem version 0.12.2, 0.10.3 that has a security fix for a ReDoS vulnerability.
|
1547
|
+
This vulnerability has been assigned the CVE identifier <a href="https://www.cve.org/CVERecord?id=CVE-2023-36617">CVE-2023-36617</a>.</p>
|
1548
|
+
|
1549
|
+
<h2>Details</h2>
|
1550
|
+
|
1551
|
+
<p>A ReDoS issue was discovered in the URI component through 0.12.1 for Ruby. The URI parser mishandles invalid URLs that have specific characters. There is an increase in execution time for parsing strings to URI objects with rfc2396_parser.rb and rfc3986_parser.rb.</p>
|
1552
|
+
|
1553
|
+
<p>NOTE: this issue exists because of an incomplete fix for <a href="https://www.ruby-lang.org/en/news/2023/03/28/redos-in-uri-cve-2023-28755/">CVE-2023-28755</a>.</p>
|
1554
|
+
|
1555
|
+
<p>The <code class="language-plaintext highlighter-rouge">uri</code> gem version 0.12.1 and all versions prior 0.12.1 are vulnerable for this vulnerability.</p>
|
1556
|
+
|
1557
|
+
<h2>Recommended action</h2>
|
1558
|
+
|
1559
|
+
<p>We recommend to update the <code class="language-plaintext highlighter-rouge">uri</code> gem to 0.12.2. In order to ensure compatibility with bundled version in older Ruby series, you may update as follows instead:</p>
|
1560
|
+
|
1561
|
+
<ul>
|
1562
|
+
<li>For Ruby 3.0: Update to <code class="language-plaintext highlighter-rouge">uri</code> 0.10.3</li>
|
1563
|
+
<li>For Ruby 3.1: Update to <code class="language-plaintext highlighter-rouge">uri</code> 0.12.2</li>
|
1564
|
+
<li>For Ruby 3.2: Update to <code class="language-plaintext highlighter-rouge">uri</code> 0.12.2, or update to Ruby 3.2.3</li>
|
1565
|
+
</ul>
|
1566
|
+
|
1567
|
+
<p>You can use <code class="language-plaintext highlighter-rouge">gem update uri</code> to update it. If you are using bundler, please add <code class="language-plaintext highlighter-rouge">gem "uri", "&gt;= 0.12.2"</code> (or other version mentioned above) to your <code class="language-plaintext highlighter-rouge">Gemfile</code>.</p>
|
1568
|
+
|
1569
|
+
<h2>Affected versions</h2>
|
1570
|
+
|
1571
|
+
<ul>
|
1572
|
+
<li>uri gem 0.12.1 or before</li>
|
1573
|
+
</ul>
|
1574
|
+
|
1575
|
+
<h2>Credits</h2>
|
1576
|
+
|
1577
|
+
<p>Thanks to <a href="https://hackerone.com/ooooooo_q">ooooooo_q</a> for discovering this issue.</p>
|
1578
|
+
|
1579
|
+
<p>Thanks to <a href="https://github.com/nobu">nobu</a> for fixing this issue.</p>
|
1580
|
+
|
1581
|
+
<h2>History</h2>
|
1582
|
+
|
1583
|
+
<ul>
|
1584
|
+
<li>Added a new recommended action for Ruby 3.2 at 2024-01-18 12:00:00 (UTC)</li>
|
1585
|
+
<li>Originally published at 2023-06-29 01:00:00 (UTC)</li>
|
1586
|
+
</ul>
|
1587
|
+
|
1588
|
+
<p>Posted by hsbt on 29 Jun 2023</p></description>
|
1589
|
+
<pubDate>Thu, 29 Jun 2023 01:00:00 +0000</pubDate>
|
1590
|
+
<guid>https://www.ruby-lang.org/en/news/2023/06/29/redos-in-uri-CVE-2023-36617/</guid>
|
1591
|
+
<link>https://www.ruby-lang.org/en/news/2023/06/29/redos-in-uri-CVE-2023-36617/</link>
|
1592
|
+
</item>
|
1593
|
+
|
1594
|
+
<item>
|
1595
|
+
<title>Ruby 3.3.0-preview1 Released</title>
|
1596
|
+
<description>
|
1597
|
+
<p>We are pleased to announce the release of Ruby 3.3.0-preview1. Ruby 3.3 adds a new pure-Ruby JIT compiler named RJIT, uses Lrama as a parser generator, and many performance improvements especially YJIT.</p>
|
1598
|
+
|
1599
|
+
<h2>RJIT</h2>
|
1600
|
+
|
1601
|
+
<ul>
|
1602
|
+
<li>Introduced a pure-Ruby JIT compiler RJIT and replaced MJIT.
|
1603
|
+
<ul>
|
1604
|
+
<li>RJIT supports only x86_64 architecture on Unix platforms.</li>
|
1605
|
+
<li>Unlike MJIT, it doesn’t require a C compiler at runtime.</li>
|
1606
|
+
</ul>
|
1607
|
+
</li>
|
1608
|
+
<li>RJIT exists only for experimental purposes.
|
1609
|
+
<ul>
|
1610
|
+
<li>You should keep using YJIT in production.</li>
|
1611
|
+
</ul>
|
1612
|
+
</li>
|
1613
|
+
<li>If you are interested in developing JIT for Ruby, please check out <a href="https://rubykaigi.org/2023/presentations/k0kubun.html#day3">k0kubun’s presentation on Day 3 of RubyKaigi</a>.</li>
|
1614
|
+
</ul>
|
1615
|
+
|
1616
|
+
<h2>Use Lrama instead of Bison</h2>
|
1617
|
+
|
1618
|
+
<ul>
|
1619
|
+
<li>Replace Bison with <a href="https://github.com/yui-knk/lrama">Lrama LALR parser generator</a> <a href="https://bugs.ruby-lang.org/issues/19637">Feature #19637</a>
|
1620
|
+
<ul>
|
1621
|
+
<li>If you have interest, please see <a href="https://rubykaigi.org/2023/presentations/spikeolaf.html">The future vision of Ruby Parser</a></li>
|
1622
|
+
</ul>
|
1623
|
+
</li>
|
1624
|
+
</ul>
|
1625
|
+
|
1626
|
+
<h2>YJIT</h2>
|
1627
|
+
|
1628
|
+
<ul>
|
1629
|
+
<li>Significant performance improvements over 3.2
|
1630
|
+
<ul>
|
1631
|
+
<li>Splat and rest arguments support has been improved.</li>
|
1632
|
+
<li>Registers are allocated for stack operations of the virtual machine.</li>
|
1633
|
+
<li>More calls with optional arguments are compiled.</li>
|
1634
|
+
<li><code class="language-plaintext highlighter-rouge">Integer#!=</code>, <code class="language-plaintext highlighter-rouge">String#!=</code>, <code class="language-plaintext highlighter-rouge">Kernel#block_given?</code>, <code class="language-plaintext highlighter-rouge">Kernel#is_a?</code>,
|
1635
|
+
<code class="language-plaintext highlighter-rouge">Kernel#instance_of?</code>, <code class="language-plaintext highlighter-rouge">Module#===</code> are specially optimized.</li>
|
1636
|
+
<li>Instance variables no longer exit to the interpreter
|
1637
|
+
with megamorphic Object Shapes.</li>
|
1638
|
+
</ul>
|
1639
|
+
</li>
|
1640
|
+
<li>Metadata for compiled code uses a lot less memory.</li>
|
1641
|
+
<li>Improved code generation on ARM64</li>
|
1642
|
+
<li>Option to start YJIT in paused mode and then later enable it manually
|
1643
|
+
<ul>
|
1644
|
+
<li><code class="language-plaintext highlighter-rouge">--yjit-pause</code> and <code class="language-plaintext highlighter-rouge">RubyVM::YJIT.resume</code></li>
|
1645
|
+
<li>This can be used to enable YJIT only once your application is done booting</li>
|
1646
|
+
</ul>
|
1647
|
+
</li>
|
1648
|
+
<li>Exit tracing option now supports sampling
|
1649
|
+
<ul>
|
1650
|
+
<li><code class="language-plaintext highlighter-rouge">--trace-exits-sample-rate=N</code></li>
|
1651
|
+
</ul>
|
1652
|
+
</li>
|
1653
|
+
<li>Multiple bug fixes</li>
|
1654
|
+
</ul>
|
1655
|
+
|
1656
|
+
<h2>Other Notable New Features</h2>
|
1657
|
+
|
1658
|
+
<h3>Language</h3>
|
1659
|
+
|
1660
|
+
<h2>Performance improvements</h2>
|
1661
|
+
|
1662
|
+
<ul>
|
1663
|
+
<li><code class="language-plaintext highlighter-rouge">defined?(@ivar)</code> is optimized with Object Shapes.</li>
|
1664
|
+
</ul>
|
1665
|
+
|
1666
|
+
<h2>Other notable changes since 3.2</h2>
|
1667
|
+
|
1668
|
+
<h2>Compatibility issues</h2>
|
1669
|
+
|
1670
|
+
<p>Note: Excluding feature bug fixes.</p>
|
1671
|
+
|
1672
|
+
<h3>Removed constants</h3>
|
1673
|
+
|
1674
|
+
<p>The following deprecated constants are removed.</p>
|
1675
|
+
|
1676
|
+
<h3>Removed methods</h3>
|
1677
|
+
|
1678
|
+
<p>The following deprecated methods are removed.</p>
|
1679
|
+
|
1680
|
+
<h2>Stdlib compatibility issues</h2>
|
1681
|
+
|
1682
|
+
<h3><code class="language-plaintext highlighter-rouge">ext/readline</code> is retired</h3>
|
1683
|
+
|
1684
|
+
<ul>
|
1685
|
+
<li>We have <code class="language-plaintext highlighter-rouge">reline</code> that is pure Ruby implementation compatible with <code class="language-plaintext highlighter-rouge">ext/readline</code> API. We rely on <code class="language-plaintext highlighter-rouge">reline</code> in the future. If you need to use <code class="language-plaintext highlighter-rouge">ext/readline</code>, you can install <code class="language-plaintext highlighter-rouge">ext/readline</code> via rubygems.org with <code class="language-plaintext highlighter-rouge">gem install readline-ext</code>.</li>
|
1686
|
+
<li>We no longer need to install libraries like <code class="language-plaintext highlighter-rouge">libreadline</code> or <code class="language-plaintext highlighter-rouge">libedit</code>.</li>
|
1687
|
+
</ul>
|
1688
|
+
|
1689
|
+
<h2>C API updates</h2>
|
1690
|
+
|
1691
|
+
<h3>Updated C APIs</h3>
|
1692
|
+
|
1693
|
+
<p>The following APIs are updated.</p>
|
1694
|
+
|
1695
|
+
<h3>Removed C APIs</h3>
|
1696
|
+
|
1697
|
+
<p>The following deprecated APIs are removed.</p>
|
1698
|
+
|
1699
|
+
<h2>Standard library updates</h2>
|
1700
|
+
|
1701
|
+
<p>The following default gems are updated.</p>
|
1702
|
+
|
1703
|
+
<ul>
|
1704
|
+
<li>RubyGems 3.5.0.dev</li>
|
1705
|
+
<li>bigdecimal 3.1.4</li>
|
1706
|
+
<li>bundler 2.5.0.dev</li>
|
1707
|
+
<li>csv 3.2.7</li>
|
1708
|
+
<li>fiddle 1.1.2</li>
|
1709
|
+
<li>fileutils 1.7.1</li>
|
1710
|
+
<li>irb 1.6.4</li>
|
1711
|
+
<li>optparse 0.4.0.pre.1</li>
|
1712
|
+
<li>psych 5.1.0</li>
|
1713
|
+
<li>reline 0.3.3</li>
|
1714
|
+
<li>stringio 3.0.7</li>
|
1715
|
+
<li>strscan 3.0.7</li>
|
1716
|
+
<li>syntax_suggest 1.0.4</li>
|
1717
|
+
<li>time 0.2.2</li>
|
1718
|
+
<li>timeout 0.3.2</li>
|
1719
|
+
<li>uri 0.12.1</li>
|
1720
|
+
</ul>
|
1721
|
+
|
1722
|
+
<p>The following bundled gems are updated.</p>
|
1723
|
+
|
1724
|
+
<ul>
|
1725
|
+
<li>minitest 5.18.0</li>
|
1726
|
+
<li>rbs 3.1.0</li>
|
1727
|
+
<li>typeprof 0.21.7</li>
|
1728
|
+
<li>debug 1.8.0</li>
|
1729
|
+
</ul>
|
1730
|
+
|
1731
|
+
<p>See GitHub releases like <a href="https://github.com/ruby/logger/releases">Logger</a> or
|
1732
|
+
changelog for details of the default gems or bundled gems.</p>
|
1733
|
+
|
1734
|
+
<p>See <a href="https://github.com/ruby/ruby/blob/v3_3_0_preview1/NEWS.md">NEWS</a>
|
1735
|
+
or <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview1">commit logs</a>
|
1736
|
+
for more details.</p>
|
1737
|
+
|
1738
|
+
<p>With those changes, <a href="https://github.com/ruby/ruby/compare/v3_2_0...v3_3_0_preview1#file_bucket">1922 files changed, 75283 insertions(+), 44896 deletions(-)</a>
|
1739
|
+
since Ruby 3.2.0!</p>
|
1740
|
+
|
1741
|
+
<h2>Download</h2>
|
1742
|
+
|
1743
|
+
<ul>
|
1744
|
+
<li>
|
1745
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.tar.gz</a></p>
|
1746
|
+
|
1747
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 20428213
|
1748
|
+
SHA1: 5445eec1cd9ddb44e03e74568cac94209c91b42d
|
1749
|
+
SHA256: c3454a911779b8d747ab0ea87041030d002d533edacb2485fe558b7084da25ed
|
1750
|
+
SHA512: 0f891f140ddc6372aa7c4459f8784126e0c341db7b80e72c51e441c5153c43c2d7b965f7807c076862ac84b9b8b0c6a66bbf66fc341746016151397bb21c782a
|
1751
|
+
</code></pre></div> </div>
|
1752
|
+
</li>
|
1753
|
+
<li>
|
1754
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.tar.xz</a></p>
|
1755
|
+
|
1756
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 15074600
|
1757
|
+
SHA1: 4c22ebca287c87811e1050bf4d59b7d32255b212
|
1758
|
+
SHA256: ae300b49e06c13087dd163b97eddd38db895dc8e0c9904284119795d75303fbb
|
1759
|
+
SHA512: 46c1134dba5810847f7f6b4298900a91f5225679d7873548b271f4ef2ad1dc168722562a2e468a2ccf136314176ee613d8c7792fd4411a3f7a44c80b93b417ee
|
1760
|
+
</code></pre></div> </div>
|
1761
|
+
</li>
|
1762
|
+
<li>
|
1763
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.zip">https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.0-preview1.zip</a></p>
|
1764
|
+
|
1765
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 24846962
|
1766
|
+
SHA1: 31774fa653c54107b6afc30adda3a0350d8f41d2
|
1767
|
+
SHA256: 6ecafecf83f2cacf446b2326012f2b6ee1a0614d8dd29bb1fb3f105c27e2c553
|
1768
|
+
SHA512: 794bef847fefbbdbbdced85975a00c9289ef6464810408af3f0f2055052d6b5ef5576dbd41e0d87bb73f1ad276d8e27c36018610f8e2b9936828c0e692f611f0
|
1769
|
+
</code></pre></div> </div>
|
1770
|
+
</li>
|
1771
|
+
</ul>
|
1772
|
+
|
1773
|
+
<h2>What is Ruby</h2>
|
1774
|
+
|
1775
|
+
<p>Ruby was first developed by Matz (Yukihiro Matsumoto) in 1993,
|
1776
|
+
and is now developed as Open Source. It runs on multiple platforms
|
1777
|
+
and is used all over the world especially for web development.</p>
|
1778
|
+
|
1779
|
+
<p>Posted by naruse on 12 May 2023</p></description>
|
1780
|
+
<pubDate>Fri, 12 May 2023 00:00:00 +0000</pubDate>
|
1781
|
+
<guid>https://www.ruby-lang.org/en/news/2023/05/12/ruby-3-3-0-preview1-released/</guid>
|
1782
|
+
<link>https://www.ruby-lang.org/en/news/2023/05/12/ruby-3-3-0-preview1-released/</link>
|
1783
|
+
</item>
|
1784
|
+
|
1785
|
+
<item>
|
1786
|
+
<title>Ruby 3.2.2 Released</title>
|
1787
|
+
<description><p>Ruby 3.2.2 has been released.</p>
|
1788
|
+
|
1789
|
+
<p>This release includes security fixes.
|
1790
|
+
Please check the topics below for details.</p>
|
1791
|
+
|
1792
|
+
<ul>
|
1793
|
+
<li><a href="/en/news/2023/03/28/redos-in-uri-cve-2023-28755/">CVE-2023-28755: ReDoS vulnerability in URI</a></li>
|
1794
|
+
<li><a href="/en/news/2023/03/30/redos-in-time-cve-2023-28756/">CVE-2023-28756: ReDoS vulnerability in Time</a></li>
|
1795
|
+
</ul>
|
1796
|
+
|
1797
|
+
<p>See the <a href="https://github.com/ruby/ruby/releases/tag/v3_2_2">GitHub releases</a> for further details.</p>
|
1798
|
+
|
1799
|
+
<h2>Download</h2>
|
1800
|
+
|
1801
|
+
<ul>
|
1802
|
+
<li>
|
1803
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.tar.gz">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.tar.gz</a></p>
|
1804
|
+
|
1805
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 20467023
|
1806
|
+
SHA1: 670fce00d83771a1349b116e56a8a3b0ad323769
|
1807
|
+
SHA256: 96c57558871a6748de5bc9f274e93f4b5aad06cd8f37befa0e8d94e7b8a423bc
|
1808
|
+
SHA512: bcc68f3f24c1c8987d9c80b57332e5791f25b935ba38daf5addf60dbfe3a05f9dcaf21909681b88e862c67c6ed103150f73259c6e35c564f13a00f432e3c1e46
|
1809
|
+
</code></pre></div> </div>
|
1810
|
+
</li>
|
1811
|
+
<li>
|
1812
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.tar.xz">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.tar.xz</a></p>
|
1813
|
+
|
1814
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 15118856
|
1815
|
+
SHA1: 087af286b70b0e17f88c9c4469b471eca2010161
|
1816
|
+
SHA256: 4b352d0f7ec384e332e3e44cdbfdcd5ff2d594af3c8296b5636c710975149e23
|
1817
|
+
SHA512: a29f24cd80f563f6368952d06d6273f7241a409fa9ab2f60e03dde2ac58ca06bee1750715b6134caebf4c061d3503446dc37a6059e19860bb0010eef34951935
|
1818
|
+
</code></pre></div> </div>
|
1819
|
+
</li>
|
1820
|
+
<li>
|
1821
|
+
<p><a href="https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.zip">https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.2.zip</a></p>
|
1822
|
+
|
1823
|
+
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>SIZE: 24615317
|
1824
|
+
SHA1: a1b6d57019d41dca269b4b16a80784755d34b81d
|
1825
|
+
SHA256: cc216ecb4f49064d8f44e10ecf9218cfd7b28cf4168bb79ecdf171e321db4af1
|
1826
|
+
SHA512: 569a68d89cc9a646cd0319d7cb8d57df3a55c0ac2c64f1f61607cc9c06b3aa8415eb8d38f7893ab3dbf072da9e919fbc454a9338e924c20a6a5110a1fa301d52
|
1827
|
+
</code></pre></div> </div>
|
1828
|
+
</li>
|
1829
|
+
</ul>
|
1830
|
+
|
1831
|
+
<h2>Release Comment</h2>
|
1832
|
+
|
1833
|
+
<p>Many committers, developers, and users who provided bug reports helped us make this release.
|
1834
|
+
Thanks for their contributions.</p>
|
1835
|
+
|
1836
|
+
<p>Posted by naruse on 30 Mar 2023</p></description>
|
1837
|
+
<pubDate>Thu, 30 Mar 2023 12:00:00 +0000</pubDate>
|
1838
|
+
<guid>https://www.ruby-lang.org/en/news/2023/03/30/ruby-3-2-2-released/</guid>
|
1839
|
+
<link>https://www.ruby-lang.org/en/news/2023/03/30/ruby-3-2-2-released/</link>
|
1840
|
+
</item>
|
1841
|
+
|
1842
|
+
</channel>
|
1843
|
+
</rss>
|