mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
transform_mjit_header.rb: apply Regexp.escape
to prevent future breakage Following up r62285 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62287 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
4d351c7b24
commit
13b376c561
1 changed files with 1 additions and 1 deletions
|
@ -135,7 +135,7 @@ module MJITHeader
|
|||
|
||||
# If code has macro which only supported compilers predefine, return true.
|
||||
def self.supported_header?(code)
|
||||
SUPPORTED_CC_MACROS.any? { |macro| code =~ /^#\s*define\s+#{macro}\b/ }
|
||||
SUPPORTED_CC_MACROS.any? { |macro| code =~ /^#\s*define\s+#{Regexp.escape(macro)}\b/ }
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue