テクノロジー

Ruby 3.3.0 nears release with new parser

[ad_1]

Ruby 3.3.0, a planned update to the popular dynamic language that features a new parser, has reached the release candidate stage.

RC1 of Ruby 3.3.0 was announced December 11. It can be accessed from ruby-lang.org.

Featured is the Prism parser as a default gem. Prism is billed as a portable, error-tolerant, maintainable, recursive-descent parser for the Ruby language. A C library, Prism can be used in place of Ripper.

Also featured in Ruby 3.3.0 is the Lrama LALR parser generator, which is intended to provide an error-tolerant parser for CRuby with minimal changes to the CRuby parse.y file. Other highlights of Ruby 3.3.0 include:

  • The pure-Ruby RJIT Ruby JIT compiler replaces MJIT. RJIT is currently experimental; YJIT should be used in production.
  • YJIT receives major performance improvements over Ruby 3.2. Memory usage also has been improved in YJIT.
  • The M:N thread scheduler is introduced.
  • For performance, defined?(@ivar) is optimized with Object Shapes.
  • Garbage collector performance has been improved.
  • Most core classes now use Variable Width Allocation, notably Hash, Time, Thread::Backtrace, Thread::Backtrace::Location, File::Stat, and Method. This makes these classes faster to allocate and to free, and reduces memory use and heap fragmentation.

After the release of RC1, Ruby’s builders will avoid introducing ABI (application binary interface) incompatibilities wherever possible. Predecessor Ruby 3.2.2, featuring security fixes, was released March 30.

Copyright © 2023 IDG Communications, Inc.

[ad_2]
Source link

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button