aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/interpreter/kwargs.py
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2021-06-01 16:05:09 -0700
committerDylan Baker <dylan@pnwbakers.com>2021-06-15 12:36:05 -0700
commit2bc7a1b3dad998b12d80a52f83bab9a5981b2ec8 (patch)
tree2bec1ef09673257f4fa772e699f20a28457dd961 /mesonbuild/interpreter/kwargs.py
parent61ddceb3b99928de78a97e406c990377cd3085b4 (diff)
downloadmeson-2bc7a1b3dad998b12d80a52f83bab9a5981b2ec8.zip
meson-2bc7a1b3dad998b12d80a52f83bab9a5981b2ec8.tar.gz
meson-2bc7a1b3dad998b12d80a52f83bab9a5981b2ec8.tar.bz2
modules/qt: fully annotate and check qt.has_tools
Diffstat (limited to 'mesonbuild/interpreter/kwargs.py')
-rw-r--r--mesonbuild/interpreter/kwargs.py16
1 files changed, 15 insertions, 1 deletions
diff --git a/mesonbuild/interpreter/kwargs.py b/mesonbuild/interpreter/kwargs.py
index db6b02b..feba62e 100644
--- a/mesonbuild/interpreter/kwargs.py
+++ b/mesonbuild/interpreter/kwargs.py
@@ -9,7 +9,10 @@ import typing as T
from typing_extensions import TypedDict, Literal
from ..mesonlib import MachineChoice, File
-from .interpreterobjects import BuildTargetHolder, CustomTargetHolder, EnvironmentVariablesHolder, TargetHolder
+from .interpreterobjects import (
+ BuildTargetHolder, CustomTargetHolder, EnvironmentVariablesHolder,
+ FeatureOptionHolder, TargetHolder
+)
class FuncAddProjectArgs(TypedDict):
@@ -57,3 +60,14 @@ class FuncTest(FuncBenchmark):
"""
is_parallel: bool
+
+
+class ExtractRequired(TypedDict):
+
+ """Keyword Arguments consumed by the `extract_required_kwargs` function.
+
+ Any function that uses the `required` keyword argument which accepts either
+ a boolean or a feature option should inherit it's arguments from this class.
+ """
+
+ required: T.Union[bool, 'FeatureOptionHolder']