From: "nobu (Nobuyoshi Nakada) via ruby-core" Date: 2023-12-25T13:21:41+00:00 Subject: [ruby-core:115891] [Ruby master Bug#20084] Breaking change with Regexp.new on 3.3.0 Issue #20084 has been updated by nobu (Nobuyoshi Nakada). I think we needed to add it to Compatibility issues in NEWS.md. ---------------------------------------- Bug #20084: Breaking change with Regexp.new on 3.3.0 https://bugs.ruby-lang.org/issues/20084#change-105848 * Author: paddor (Patrik Wenger) * Status: Closed * Priority: Normal * ruby -v: ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [x86_64-linux] * Backport: 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN ---------------------------------------- Regexp.new used to take up to 3 arguments, but now only 1..2 are allowed: ``` [1] pry(main)> Regexp.new 'abc', 'i', 'n' ArgumentError: wrong number of arguments (given 3, expected 1..2) from (pry):1:in `initialize' ``` On 3.2.2: ``` [1] pry(main)> Regexp.new 'abc', 'i', 'n' => /abc/in ``` -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/