mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
[inspections] PY-85120 Do not consider expressions like a: list[int] | None = None a type alias
Target expression should have either explicit `TypeAlias` annotation or valid type expression in assignment without type annotation (to be considered implicit type alias) (cherry picked from commit 1059a8df2d221bd068eee706139be20c256df549) GitOrigin-RevId: 8c952138fbc4124f02f717ce8a1784c1f0dc86b2
This commit is contained in:
committed by
intellij-monorepo-bot
parent
1b197eb884
commit
489b9b90aa
@@ -22,6 +22,9 @@ bin3_ok = Union[str, bool] | None
|
||||
bin4_notOk = str & int
|
||||
list_notOk = [int, str]
|
||||
|
||||
bin5_notOk: int | str = "foo"
|
||||
list_none_notOk: list[int] | None = None
|
||||
|
||||
callable_ok = Callable[[int, str], bool]
|
||||
|
||||
explicit_alias1_ok: TypeAlias = 'Foo is bar.'
|
||||
|
||||
Reference in New Issue
Block a user