-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed as not planned
Description
Could be nice to support composition of literals, so that something like this type checks correctly:
from typing import Literal
def page(page: Literal["p1", "p2"]): ...
def foo(num: Literal["1", "2"]):
page(f"p{num}")
page("p" + num)
page("p" + "1")
noneofyourbusiness1415252 and majdsalloum-agsterliakov