Project

General

Profile

Actions

Bug #20246

closed

Unexpected behavior for Regexp in Subexpression Calls on Ruby 3.3.0

Added by bestwebua (Vladislav Trotsenko) 11 months ago. Updated 9 months ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin22]
[ruby-core:116627]

Description

Hello! A few days ago, after migration on 3.3.0 I have faced with issue inside subexpression calls.

An expected result on Ruby up to 3.3.0:

'1.2.3'[/(\d+)(\.\g<1>){2}/] # => "1.2.3"

An actual result on Ruby 3.3.0:

'1.2.3'[/(\d+)(\.\g<1>){2}/] # => nil

Related issues 1 (0 open1 closed)

Has duplicate Ruby master - Bug #20285: Stale inline method caches when refinement modules are reopenedClosedjhawthorn (John Hawthorn)Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0