Use a case statement
This commit is contained in:
parent
dfea2b6045
commit
9e8d419070
@ -92,7 +92,9 @@ module SharedEnvExtension
|
|||||||
def compiler
|
def compiler
|
||||||
@compiler ||= if (cc = ARGV.cc)
|
@compiler ||= if (cc = ARGV.cc)
|
||||||
COMPILER_SYMBOL_MAP.fetch(cc) do |other|
|
COMPILER_SYMBOL_MAP.fetch(cc) do |other|
|
||||||
if other =~ GNU_GCC_REGEXP then other
|
case other
|
||||||
|
when GNU_GCC_REGEXP
|
||||||
|
other
|
||||||
else
|
else
|
||||||
raise "Invalid value for --cc: #{other}"
|
raise "Invalid value for --cc: #{other}"
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user