diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2021-07-01 10:15:52 -0700 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2021-07-07 11:21:03 -0700 |
commit | 09d7da19c18d788e48cb46dbf10d791dabdf7eb9 (patch) | |
tree | f7b3aea958fda6b6376d1c246ee99ef4eeef3606 /mesonbuild/interpreter/interpreter.py | |
parent | 3135b130b83c9f4058ae45ff0f6e368e22958c99 (diff) | |
download | meson-09d7da19c18d788e48cb46dbf10d791dabdf7eb9.zip meson-09d7da19c18d788e48cb46dbf10d791dabdf7eb9.tar.gz meson-09d7da19c18d788e48cb46dbf10d791dabdf7eb9.tar.bz2 |
interpreter: use typed_kwargs for include_directories
Diffstat (limited to 'mesonbuild/interpreter/interpreter.py')
-rw-r--r-- | mesonbuild/interpreter/interpreter.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/mesonbuild/interpreter/interpreter.py b/mesonbuild/interpreter/interpreter.py index 66f2dd2..baf2e9d 100644 --- a/mesonbuild/interpreter/interpreter.py +++ b/mesonbuild/interpreter/interpreter.py @@ -2268,11 +2268,11 @@ This will become a hard error in the future.''' % kwargs['input'], location=self raise InterpreterException('Include directory objects can only be created from strings or include directories.') return result - @permittedKwargs({'is_system'}) @typed_pos_args('include_directories', varargs=str) + @typed_kwargs('include_directories', KwargInfo('is_system', bool, default=False)) def func_include_directories(self, node: mparser.BaseNode, args: T.Tuple[T.List[str]], - kwargs: 'TYPE_kwargs') -> build.IncludeDirs: - return self.build_incdir_object(args[0], kwargs.get('is_system', False)) + kwargs: 'kwargs.FuncIncludeDirectories') -> build.IncludeDirs: + return self.build_incdir_object(args[0], kwargs['is_system']) def build_incdir_object(self, incdir_strings: T.List[str], is_system: bool = False) -> build.IncludeDirs: if not isinstance(is_system, bool): |