interpreter: don't use `in dict.keys()` use `in dict`

The former performs a linear search, which is slower than the set based
search.
pull/13908/head
Dylan Baker 10 months ago
parent f1a09aabf1
commit cad608108b
  1. 2
      mesonbuild/interpreter/interpreter.py

@ -1127,7 +1127,7 @@ class Interpreter(InterpreterBase, HoldableObject):
return
from ..backend import backends
if OptionKey('genvslite') in self.user_defined_options.cmd_line_options.keys():
if OptionKey('genvslite') in self.user_defined_options.cmd_line_options:
# Use of the '--genvslite vsxxxx' option ultimately overrides any '--backend xxx'
# option the user may specify.
backend_name = self.coredata.get_option(OptionKey('genvslite'))

Loading…
Cancel
Save