From e0719babdc8744144449c81fac14ba7bbf21446f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 27 Feb 2023 11:40:00 +0100 Subject: Merging upstream version 3.0.23. Signed-off-by: Daniel Baumann --- ptpython/validator.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ptpython/validator.py') diff --git a/ptpython/validator.py b/ptpython/validator.py index ffac583..3b36d27 100644 --- a/ptpython/validator.py +++ b/ptpython/validator.py @@ -1,3 +1,5 @@ +from __future__ import annotations + from typing import Callable, Optional from prompt_toolkit.document import Document @@ -16,7 +18,7 @@ class PythonValidator(Validator): active compiler flags. """ - def __init__(self, get_compiler_flags: Optional[Callable[[], int]] = None) -> None: + def __init__(self, get_compiler_flags: Callable[[], int] | None = None) -> None: self.get_compiler_flags = get_compiler_flags def validate(self, document: Document) -> None: -- cgit v1.2.3