mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-30 05:45:24 +00:00
[red-knot] Make Symbol::or_fall_back_to()
lazy (#15943)
This commit is contained in:
parent
c69b19fe1d
commit
2ebb5e8d4b
4 changed files with 99 additions and 100 deletions
|
@ -13,7 +13,7 @@ if returns_bool():
|
|||
chr: int = 1
|
||||
|
||||
def f():
|
||||
reveal_type(chr) # revealed: Literal[chr] | int
|
||||
reveal_type(chr) # revealed: int | Literal[chr]
|
||||
```
|
||||
|
||||
## Conditionally global or builtin, with annotation
|
||||
|
@ -28,5 +28,5 @@ if returns_bool():
|
|||
chr: int = 1
|
||||
|
||||
def f():
|
||||
reveal_type(chr) # revealed: Literal[chr] | int
|
||||
reveal_type(chr) # revealed: int | Literal[chr]
|
||||
```
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue