Created
April 25, 2024 14:23
-
-
Save mypy-play/3ad17a83f39c3a2c110abc28451d232b to your computer and use it in GitHub Desktop.
Shared via mypy Playground
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from typing import Final | |
# Sentinel to denote unset values | |
UNSET: Final[object] = object() | |
def foo(timezone: str | object | None = UNSET) -> None: | |
pass | |
if __name__ == "__main__": | |
foo() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment