[ruby/strscan] Support Ractor#value

(https://github.com/ruby/strscan/pull/157)

This is same as https://github.com/ruby/stringio/pull/134

---------

https://github.com/ruby/strscan/commit/141f9cf9b6

Co-authored-by: Koichi Sasada <ko1@atdot.net>
This commit is contained in:
Hiroshi SHIBATA 2025-06-03 16:44:03 +09:00
parent 8ab4935ddf
commit 267d8a04b3
No known key found for this signature in database
GPG Key ID: F9CF13417264FAC2

View File

@ -8,6 +8,10 @@ class TestStringScannerRactor < Test::Unit::TestCase
def test_ractor
assert_in_out_err([], <<-"end;", ["stra", " ", "strb", " ", "strc"], [])
class Ractor
alias value take unless method_defined? :value # compat with Ruby 3.4 and olders
end
require "strscan"
$VERBOSE = nil
r = Ractor.new do