changeset 51793:0f62ea8a9be8 stable

typing: fix type annotation
author Manuel Jacob <me@manueljacob.de>
date Tue, 06 Aug 2024 18:23:59 +0200
parents 472699b5ddb3
children bd490cdf764a
files mercurial/posix.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/posix.py	Tue Aug 06 17:53:59 2024 +0200
+++ b/mercurial/posix.py	Tue Aug 06 18:23:59 2024 +0200
@@ -23,6 +23,7 @@
 from typing import (
     Any,
     AnyStr,
+    Callable,
     Iterable,
     Iterator,
     List,
@@ -552,7 +553,7 @@
         return False
 
 
-_needsshellquote: Optional[Match[bytes]] = None
+_needsshellquote: Optional[Callable[[bytes], Optional[Match[bytes]]]] = None
 
 
 def shellquote(s: bytes) -> bytes: