mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
[ruby/optparse] JRuby does not have EXECUTABLE_EXTS in RbConfg::CONFIG
15b2f00b6b
This commit is contained in:
parent
259b0233d8
commit
9598ed9d1c
2 changed files with 2 additions and 2 deletions
|
@ -1300,7 +1300,7 @@ XXX
|
|||
private def strip_ext(name) # :nodoc:
|
||||
exts = /#{
|
||||
require "rbconfig"
|
||||
Regexp.union(RbConfig::CONFIG["EXECUTABLE_EXTS"])
|
||||
Regexp.union(*RbConfig::CONFIG["EXECUTABLE_EXTS"]&.split(" "))
|
||||
}\z/o
|
||||
name.sub(exts, "")
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue