1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

ext/ripper/tools/dsl.rb: Use String#sub instead of delete_suffix

It fails when baseruby is old.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61994 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
mame 2018-01-20 17:52:51 +00:00
parent f69bf70881
commit 8a489a7d6f

View file

@ -55,7 +55,7 @@ class DSL
end
def add_event(event, args, qundef_check = false)
event = event.to_s.delete_suffix("!")
event = event.to_s.sub(/!\z/, "")
@events[event] = args.size
vars = []
args.each do |arg|