diff options
author | Eli Schwartz <eschwartz@archlinux.org> | 2021-11-21 13:37:25 -0500 |
---|---|---|
committer | Eli Schwartz <eschwartz@archlinux.org> | 2021-11-22 16:28:13 -0500 |
commit | 1c2461f5c7687f63bb02dd306889480d36e97b3c (patch) | |
tree | 379c68f89971b04343961d4833c91cc1bd479a13 /mesonbuild/interpreter/interpreter.py | |
parent | 1b1ecec920c5ce480ea109557b978155f63a3178 (diff) | |
download | meson-1c2461f5c7687f63bb02dd306889480d36e97b3c.zip meson-1c2461f5c7687f63bb02dd306889480d36e97b3c.tar.gz meson-1c2461f5c7687f63bb02dd306889480d36e97b3c.tar.bz2 |
simplify passing some nodes around
Every function has a copy of the node as a kwarg, and doesn't need to go
through the class's self.current_node.
Diffstat (limited to 'mesonbuild/interpreter/interpreter.py')
-rw-r--r-- | mesonbuild/interpreter/interpreter.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/interpreter/interpreter.py b/mesonbuild/interpreter/interpreter.py index d946678..5b108c7 100644 --- a/mesonbuild/interpreter/interpreter.py +++ b/mesonbuild/interpreter/interpreter.py @@ -1159,7 +1159,7 @@ external dependencies (including libraries) must go to "dependencies".''') tv = FeatureNew.get_target_version(self.subproject) if FeatureNew.check_version(tv, '0.54.0'): mlog.warning('add_languages is missing native:, assuming languages are wanted for both host and build.', - location=self.current_node) + location=node) success = self.add_languages(langs, False, MachineChoice.BUILD) success &= self.add_languages(langs, required, MachineChoice.HOST) @@ -1731,7 +1731,7 @@ external dependencies (including libraries) must go to "dependencies".''') kwargs['input'] = self.source_strings_to_files(extract_as_list(kwargs, 'input')) except mesonlib.MesonException: mlog.warning(f'''Custom target input '{kwargs['input']}' can't be converted to File object(s). -This will become a hard error in the future.''', location=self.current_node) +This will become a hard error in the future.''', location=node) kwargs['env'] = self.unpack_env_kwarg(kwargs) if 'command' in kwargs and isinstance(kwargs['command'], list) and kwargs['command']: if isinstance(kwargs['command'][0], str): |