Ruby latest versions changelog
Ruby 3.3.6
- Internals Introduced Prism parser as a default gem
- Internals Lrama replaces Bison as parser generator
- Internals Major YJIT performance improvements, introduction of RJIT
- Internals Introduction of M:N thread scheduler
- Internals Several performance improvements in the Garbage Collector
- Internals Enhancements in IRB: advanced irb:rdbg integration; pager support
Ruby 3.2.6
- Internals
WASI based WebAssembly support
- Internals Production-ready YJIT
- Internals Regexp improvements against ReDoS
- Internals IRB improvements (SyntaxSuggest, ErrorHighlight)
- Internals Bundler 2.4 now uses PubGrub resolver instead of Molinillo
Ruby 3.1.6
- Added debug gem: A new debugger
- Added error_highlight: Fine-grained error location in backtrace
- Added IRB Autocomplete and Documentation Display
-
Updated Values in Hash literals and keyword arguments can be omitted.
{x:, y:} is syntax sugar for {x: x, y: y} foo(x:, y:) is syntax sugar for foo(x: x, y: y). -
Updated Updates in RBS / TypeProf
- Internals
YJIT: New experimental in-process JIT compiler (experimental)
--yjit # CLI option
Ruby 3.0.7
- Added Ractor - Actor-model like concurrent abstraction (experimental)
- Added Fiber Scheduler for light-weight concurrency (experimental)
-
Added RBS - a language to describe the structure of Ruby classes
class User attr_reader login: String attr_reader email: String def initialize: (login: String, email: String) -> void end -
Added TypeProf - type analysis tool, generates RBS type signatures (experimental)
- Added
Hash#except -
Updated Keyword arguments are separated from other arguments
def foo(key: 42); end; foo({key: 42}) # won't work! def foo(key: 42); end; foo(**{key: 42}) # OK -
Updated Rightward assignment statement
fib(10) => a a #=> 55 -
Updated Reversed (again) order of backtrace (experimental)
Error message first, caller later. This reverts change from Ruby 2.5.0. -
Updated Endless method definition
def square(x) = x * x - Internals MJIT improvements
Ruby 2.7.8
-
Added Pattern Matching (experimental)
case [0, [1, 2, 3]] in [a, [b, *c]] a # => 0 b # => 1 c # => [2, 3] -
Updated REPL improvements
-
Updated Separation of positional and keyword arguments
// To treat last hash argument as keywords, add a double splat operator // (to avoid the warning and ensure correct behavior in Ruby 3) def foo(key: 42); end; foo({key: 42}) # warned def foo(key: 42); end; foo(**{key: 42}) # OK -
// parentheses are mandatory def foo(...) bar(...) end -
Internals Compaction GC
Ruby 2.6.10
- Added
endless ranges
(1..) - Added
Enumerable#chain - Added
function composition operators
<<, >>toProc - Updated
#thenalias for#yield_self - Internals
JIT compiler
--jit - Internals Bundler is installed as a default gem
Ruby 2.5.9
-
// Unlike #tap, it returns the result of the block. // yield_self is like #map for single object. 'Hello'.yield_self { |word| word.upcase } => 'HELLO' ['Hello'].map { |word| word.upcase }.first => 'HELLO' -
Added
rescuein blocks - Added
Hash#sliceandHash#transform_keys - Added
ERB#result_with_hash - Updated
New
Arrayaliases -#prepend (#unshift)and#append (#push) - Updated
Pattern argument on
Enumerablemethods - Updated
Keyword arguments on
Struct.new - Updated Removed Top-level constant lookup
- Updated
Reverse order of backtrace (oldest call first) (experimental)
Only when printed to terminal directly. This will be reversed again in Ruby 3.0.0
Ruby 2.4.10
- Added
Enumerable#sum - Added
Integer#digits - Added
Regexp#match?,Regexp#named_captures - Updated
New constructor
Logger.new(STDOUT, level:, progname:) - Updated
Float:
#round,#ceil,#floor, and#truncatenow accept a precision - Removed
Removed
FixnumandBignumclasses (unified toInteger)
Ruby 2.3.8
- Added
Safe navigation operator
&. - Added Frozen string literals
- Added
Array#dig - Added
Hash#fetch_values,Hash#to_proc,Hash#dig - Added 'Did you mean?'
Ruby 2.2
- Removed
callccis obsolete - use Fiber instead - Removed
DLhas been removed from stdlib - use Fiddle instead - Internals Incremental GC - fixes performance for 'old' objects
- Internals The introduction of GC for symbols (mortal/immortal)
Ruby 2.1
- Added Refinements
- Added
Exception#cause- for libraries exceptions - Added
RationalandComplexliterals - Added Generational GC - young / old objects
Ruby 2.0
- Added Keyword arguments
- Added
Module#prepend - Added
Enumerator#lazy - Added
%ia literal for symbol array
(Last updated on 2025-05-27 22:26:47 +0200)