diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-01-31 05:44:41 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-01-31 05:44:41 +0000 |
commit | 376de8b6892deca7dc5d83035c047f1e13eb67ea (patch) | |
tree | 334a1753cd914294aa99128fac3fb59bf14dc10f /sqlglot/_typing.py | |
parent | Releasing debian version 20.9.0-1. (diff) | |
download | sqlglot-376de8b6892deca7dc5d83035c047f1e13eb67ea.tar.xz sqlglot-376de8b6892deca7dc5d83035c047f1e13eb67ea.zip |
Merging upstream version 20.11.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'sqlglot/_typing.py')
-rw-r--r-- | sqlglot/_typing.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sqlglot/_typing.py b/sqlglot/_typing.py index 86d965a..65f307e 100644 --- a/sqlglot/_typing.py +++ b/sqlglot/_typing.py @@ -4,10 +4,13 @@ import typing as t import sqlglot +if t.TYPE_CHECKING: + from typing_extensions import Literal as Lit # noqa + # A little hack for backwards compatibility with Python 3.7. # For example, we might want a TypeVar for objects that support comparison e.g. SupportsRichComparisonT from typeshed. # But Python 3.7 doesn't support Protocols, so we'd also need typing_extensions, which we don't want as a dependency. A = t.TypeVar("A", bound=t.Any) - +B = t.TypeVar("B", bound="sqlglot.exp.Binary") E = t.TypeVar("E", bound="sqlglot.exp.Expression") T = t.TypeVar("T") |