diff options
author | Daniel Mensinger <daniel@mensinger-ka.de> | 2020-09-01 14:28:08 +0200 |
---|---|---|
committer | Daniel Mensinger <daniel@mensinger-ka.de> | 2020-09-08 20:15:58 +0200 |
commit | 23818fc5a389c49e2673f79af2c90d9d56b1aaf0 (patch) | |
tree | 75d73e4d81c9b1ca3187668808a80a8673ead0e6 /mesonbuild/mcompile.py | |
parent | 1b19822a2df7ff969e3734973f131df9ed9d2ee3 (diff) | |
download | meson-23818fc5a389c49e2673f79af2c90d9d56b1aaf0.zip meson-23818fc5a389c49e2673f79af2c90d9d56b1aaf0.tar.gz meson-23818fc5a389c49e2673f79af2c90d9d56b1aaf0.tar.bz2 |
typing: more fixes
Diffstat (limited to 'mesonbuild/mcompile.py')
-rw-r--r-- | mesonbuild/mcompile.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/mesonbuild/mcompile.py b/mesonbuild/mcompile.py index 5466ad2..3267529 100644 --- a/mesonbuild/mcompile.py +++ b/mesonbuild/mcompile.py @@ -32,7 +32,7 @@ if T.TYPE_CHECKING: import argparse def array_arg(value: str) -> T.List[str]: - return T.cast(T.List[str], UserArrayOption(None, value, allow_dups=True, user_input=True).value) + return UserArrayOption(None, value, allow_dups=True, user_input=True).value def validate_builddir(builddir: Path) -> None: if not (builddir / 'meson-private' / 'coredata.dat' ).is_file(): @@ -45,7 +45,9 @@ def get_backend_from_coredata(builddir: Path) -> str: """ Gets `backend` option value from coredata """ - return T.cast(str, coredata.load(str(builddir)).get_builtin_option('backend')) + backend = coredata.load(str(builddir)).get_builtin_option('backend') + assert isinstance(backend, str) + return backend def parse_introspect_data(builddir: Path) -> T.Dict[str, T.List[dict]]: """ |