aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/compilers
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2020-08-23 21:06:05 -0700
committerDylan Baker <dylan@pnwbakers.com>2020-09-24 12:14:13 -0700
commitc93395bfc7c3ff734573c599f7dbcc8fe12681e9 (patch)
treecb76427a579a75d4556c9f3eb8c232f95640b33c /mesonbuild/compilers
parentb7db3660a0709f1f47bbad0e8af85da1360a6f19 (diff)
downloadmeson-c93395bfc7c3ff734573c599f7dbcc8fe12681e9.zip
meson-c93395bfc7c3ff734573c599f7dbcc8fe12681e9.tar.gz
meson-c93395bfc7c3ff734573c599f7dbcc8fe12681e9.tar.bz2
compilers/mixins/c2000: Make mypy safe
Diffstat (limited to 'mesonbuild/compilers')
-rw-r--r--mesonbuild/compilers/mixins/c2000.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/mesonbuild/compilers/mixins/c2000.py b/mesonbuild/compilers/mixins/c2000.py
index 65a2cea..eb66003 100644
--- a/mesonbuild/compilers/mixins/c2000.py
+++ b/mesonbuild/compilers/mixins/c2000.py
@@ -47,7 +47,12 @@ c2000_debug_args = {
class C2000Compiler:
- def __init__(self):
+
+ if T.TYPE_CHECKING:
+ is_cross = True
+ can_compile_suffixes = set() # type: T.Set[str]
+
+ def __init__(self) -> None:
if not self.is_cross:
raise EnvironmentException('c2000 supports only cross-compilation.')
self.id = 'c2000'