News

Ruby 3.0.0 update released, brings performance, static analysis, transition issues, and more

The second is to enable thread operations based on Fibers over Threads because doing so can reduce context switching overhead. Then there is Ruby Actor/Ractor: It is similar to the network operation running in the background in JavaScript, but the Ractor also supports parallel execution. Because methods share common objects, Ractor has better thread parallel security and supports communication schemes based on message passing.

In terms of memory performance, by using a garbage compressor (GP), most objects will be transferred to the heap and compressed automatically.

Thanks to RBS, Ruby 3.0 also supports type checking. As a type of sign language, RBS can be used to describe class types and definitions, methods, entity variables, inheritance/mixing relationships, and Ruby modules.

It aims to view common patterns in Ruby programs, and allows advanced classes such as union, method overloading, and generics, making it possible for processes to process signature files written in .rbs format.

In addition, there are improvements in just-in-time compilers, because the compilation speed of JIT is increased by 50~500% (depending on the specific workload), support for encoding block parameters, right assignment (Right Assignment), and RubyGems 3.2.0.RC .1, Bundler 2.2.0.rc.1, IRB 1.2.6, Reline 0.1.5, and some standard library updates.

Finally, backward compatibility. Ruby 3.0 makes switching between different versions no longer a problem, and the warning messages in the log help to quickly fix bugs.

(via)

Click to comment

Leave a Reply

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

The Latest

To Top