File tree Expand file tree Collapse file tree 2 files changed +27
-11
lines changed
Expand file tree Collapse file tree 2 files changed +27
-11
lines changed Original file line number Diff line number Diff line change 33 - push
44 - pull_request
55jobs :
6- ruby-versions-inplace :
6+ ruby-versions :
77 uses : ruby/actions/.github/workflows/ruby_versions.yml@master
88 with :
99 engine : cruby-jruby
1010 min_version : 2.5
1111
1212 inplace :
13- needs : ruby-versions-inplace
13+ needs : ruby-versions
1414 name : " Inplace: ${{ matrix.ruby-version }} on ${{ matrix.runs-on }}"
1515 runs-on : ${{ matrix.runs-on }}
1616 strategy :
2020 - ubuntu-latest
2121 - macos-latest
2222 - windows-latest
23- ruby-version : ${{ fromJson(needs.ruby-versions-inplace .outputs.versions) }}
23+ ruby-version : ${{ fromJson(needs.ruby-versions.outputs.versions) }}
2424 exclude :
2525 - {runs-on: macos-latest, ruby-version: 2.5}
2626 # include:
4747 - name : Test
4848 run : bundle exec rake test RUBYOPT="--enable-frozen-string-literal"
4949
50- ruby-versions-gem :
51- uses : ruby/actions/.github/workflows/ruby_versions.yml@master
52- with :
53- engine : cruby-jruby
54- min_version : 3.0
55-
5650 gem :
57- needs : ruby-versions-gem
51+ needs : ruby-versions
5852 name : " Gem: ${{ matrix.ruby-version }} on ${{ matrix.runs-on }}"
5953 runs-on : ${{ matrix.runs-on }}
6054 strategy :
6458 - ubuntu-latest
6559 - macos-latest
6660 - windows-latest
67- ruby-version : ${{ fromJson(needs.ruby-versions-gem.outputs.versions) }}
61+ exclude :
62+ - {runs-on: macos-latest, ruby-version: 2.5}
63+ ruby-version : ${{ fromJson(needs.ruby-versions.outputs.versions) }}
6864 steps :
6965 - uses : actions/checkout@v4
7066 - uses : ruby/setup-ruby@v1
Original file line number Diff line number Diff line change 11# coding: US-ASCII
22# frozen_string_literal: false
3+
4+ require "strscan"
5+
36require_relative 'encoding'
47
58module REXML
9+ if StringScanner ::Version < "1.0.0"
10+ module StringScannerCheckScanString
11+ refine StringScanner do
12+ def check ( pattern )
13+ pattern = /#{ Regexp . escape ( pattern ) } / if pattern . is_a? ( String )
14+ super ( pattern )
15+ end
16+
17+ def scan ( pattern )
18+ pattern = /#{ Regexp . escape ( pattern ) } / if pattern . is_a? ( String )
19+ super ( pattern )
20+ end
21+ end
22+ end
23+ using StringScannerCheckScanString
24+ end
25+
626 # Generates Source-s. USE THIS CLASS.
727 class SourceFactory
828 # Generates a Source object
You can’t perform that action at this time.
0 commit comments