Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.11/site-packages/pathspec/_typing.py: 100%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

9 statements  

1""" 

2This module provides stubs for type hints not supported by all relevant Python 

3versions. 

4 

5NOTICE: This project should have zero required dependencies which means it 

6cannot simply require :module:`typing_extensions`, and I do not want to maintain 

7vendored copy of :module:`typing_extensions`. 

8""" 

9 

10from collections.abc import ( 

11 Callable) 

12from typing import ( 

13 Any, 

14 TypeVar) 

15 

16F = TypeVar('F', bound=Callable[..., Any]) 

17 

18try: 

19 from typing import override 

20except ImportError: 

21 def override(f: F) -> F: 

22 return f