diff options
author | Eli Schwartz <eschwartz@archlinux.org> | 2022-06-14 00:42:26 -0400 |
---|---|---|
committer | Eli Schwartz <eschwartz@archlinux.org> | 2022-07-03 14:11:31 -0400 |
commit | 0703ee0aef68e235c1e22d6448b79dfbbb5c8039 (patch) | |
tree | 0f7ba031362d926b726852d2070ecc8377bdb5bd /mesonbuild/ast/interpreter.py | |
parent | 46148f923b196e1b1d004e68d43edc2daca4dd25 (diff) | |
download | meson-0703ee0aef68e235c1e22d6448b79dfbbb5c8039.zip meson-0703ee0aef68e235c1e22d6448b79dfbbb5c8039.tar.gz meson-0703ee0aef68e235c1e22d6448b79dfbbb5c8039.tar.bz2 |
move various unused typing-only imports into type-checking blocks
Diffstat (limited to 'mesonbuild/ast/interpreter.py')
-rw-r--r-- | mesonbuild/ast/interpreter.py | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/mesonbuild/ast/interpreter.py b/mesonbuild/ast/interpreter.py index 63eb3e2..c510eee 100644 --- a/mesonbuild/ast/interpreter.py +++ b/mesonbuild/ast/interpreter.py @@ -14,12 +14,12 @@ # This class contains the basic functionality needed to run any interpreter # or an interpreter-based tool. +from __future__ import annotations import os import sys import typing as T -from .visitor import AstVisitor from .. import mparser, mesonlib from .. import environment @@ -30,8 +30,6 @@ from ..interpreterbase import ( BreakRequest, ContinueRequest, default_resolve_key, - TYPE_nvar, - TYPE_nkwargs, ) from ..interpreter import ( @@ -43,29 +41,33 @@ from ..interpreter import ( ) from ..mparser import ( - AndNode, ArgumentNode, ArithmeticNode, ArrayNode, AssignmentNode, BaseNode, - ComparisonNode, ElementaryNode, EmptyNode, - ForeachClauseNode, IdNode, - IfClauseNode, - IndexNode, MethodNode, NotNode, - OrNode, PlusAssignmentNode, TernaryNode, - UMinusNode, ) if T.TYPE_CHECKING: + from .visitor import AstVisitor from ..interpreter import Interpreter + from ..interpreterbase import TYPE_nkwargs, TYPE_nvar + from ..mparser import ( + AndNode, + ComparisonNode, + ForeachClauseNode, + IfClauseNode, + IndexNode, + OrNode, + UMinusNode, + ) class DontCareObject(MesonInterpreterObject): pass |