Skip to content

Commit 5483722

Browse files
committed
Fix RuboCop: Use ENV.fetch instead of ENV[] for compiler flags
1 parent 62a1550 commit 5483722

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packaging/homebrew/mfc.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ def install
5858
system venv/"bin/python", "-m", "SCons", "build",
5959
"CC=#{ENV.cc}",
6060
"CXX=#{ENV.cxx}",
61-
"CXXFLAGS=#{ENV["CXXFLAGS"]}",
62-
"CCFLAGS=#{ENV["CFLAGS"]}",
63-
"CPPFLAGS=#{ENV["CPPFLAGS"]}",
61+
"CXXFLAGS=#{ENV.fetch("CXXFLAGS", nil)}",
62+
"CCFLAGS=#{ENV.fetch("CFLAGS", nil)}",
63+
"CPPFLAGS=#{ENV.fetch("CPPFLAGS", nil)}",
6464
"python_package=y",
6565
"f90_interface=n",
6666
"system_sundials=y",

0 commit comments

Comments
 (0)