diff options
| author | Christoph Behle <behlec@gmail.com> | 2017-11-18 17:38:05 +0100 |
|---|---|---|
| committer | Jussi Pakkanen <jpakkane@gmail.com> | 2017-11-19 18:27:27 +0200 |
| commit | 05ee756ba045e6b298951bd00a0e4b0c5ec46150 (patch) | |
| tree | b24fce320ab99cb893f4702fd4f646cabcd57679 | |
| parent | fadce7f9b4e272c5aa92c0782bbabebdbb363f48 (diff) | |
| download | meson-05ee756ba045e6b298951bd00a0e4b0c5ec46150.tar.gz | |
Check keyword arguments for dependency
Check if the keyword arguments given to dependency are permitted, as is
done with other functions already.
The list of permitted keyword arguments is taken from the documentation.
| -rw-r--r-- | mesonbuild/interpreter.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py index 6300f7f1b..fbf9a21de 100644 --- a/mesonbuild/interpreter.py +++ b/mesonbuild/interpreter.py @@ -1358,6 +1358,7 @@ permitted_kwargs = {'add_global_arguments': {'language'}, 'build_target': build_target_kwargs, 'configure_file': {'input', 'output', 'configuration', 'command', 'install_dir', 'capture', 'install'}, 'custom_target': {'input', 'output', 'command', 'install', 'install_dir', 'build_always', 'capture', 'depends', 'depend_files', 'depfile', 'build_by_default'}, + 'dependency': {'default_options', 'fallback', 'language', 'method', 'modules', 'native', 'required', 'static', 'version'}, 'declare_dependency': {'include_directories', 'link_with', 'sources', 'dependencies', 'compile_args', 'link_args', 'version'}, 'executable': exe_kwargs, 'find_program': {'required', 'native'}, @@ -2130,6 +2131,7 @@ to directly access options of other subprojects.''') break return identifier, cached_dep + @permittedKwargs(permitted_kwargs['dependency']) def func_dependency(self, node, args, kwargs): self.validate_arguments(args, 1, [str]) name = args[0] |
