From 310184945155ae1c41031040d01cc2156274264c Mon Sep 17 00:00:00 2001 From: Nikita Sobolev Date: Tue, 11 Jan 2022 15:26:37 +0300 Subject: [PATCH] Use `Literal` type in `winsound` (#6891) --- stdlib/winsound.pyi | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/stdlib/winsound.pyi b/stdlib/winsound.pyi index 3d79f3b04..588bd5969 100644 --- a/stdlib/winsound.pyi +++ b/stdlib/winsound.pyi @@ -3,21 +3,21 @@ from typing import overload from typing_extensions import Literal if sys.platform == "win32": - SND_FILENAME: int - SND_ALIAS: int - SND_LOOP: int - SND_MEMORY: int - SND_PURGE: int - SND_ASYNC: int - SND_NODEFAULT: int - SND_NOSTOP: int - SND_NOWAIT: int + SND_FILENAME: Literal[131072] + SND_ALIAS: Literal[65536] + SND_LOOP: Literal[8] + SND_MEMORY: Literal[4] + SND_PURGE: Literal[64] + SND_ASYNC: Literal[1] + SND_NODEFAULT: Literal[2] + SND_NOSTOP: Literal[16] + SND_NOWAIT: Literal[8192] - MB_ICONASTERISK: int - MB_ICONEXCLAMATION: int - MB_ICONHAND: int - MB_ICONQUESTION: int - MB_OK: int + MB_ICONASTERISK: Literal[64] + MB_ICONEXCLAMATION: Literal[48] + MB_ICONHAND: Literal[16] + MB_ICONQUESTION: Literal[32] + MB_OK: Literal[0] def Beep(frequency: int, duration: int) -> None: ... # Can actually accept anything ORed with 4, and if not it's definitely str, but that's inexpressible @overload