Skip to content

Commit f1a6ec9

Browse files
committed
Fix runtime bound typevars
1 parent 21c981c commit f1a6ec9

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

distutils/_modified.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
"""Timestamp comparison of files and groups of files."""
22

3+
from __future__ import annotations
4+
35
import functools
46
import os.path
57
from collections.abc import Callable, Iterable
@@ -11,10 +13,10 @@
1113
from .errors import DistutilsFileError
1214

1315
_SourcesT = TypeVar(
14-
"_SourcesT", bound=str | bytes | os.PathLike[str] | os.PathLike[bytes]
16+
"_SourcesT", bound="str | bytes | os.PathLike[str] | os.PathLike[bytes]"
1517
)
1618
_TargetsT = TypeVar(
17-
"_TargetsT", bound=str | bytes | os.PathLike[str] | os.PathLike[bytes]
19+
"_TargetsT", bound="str | bytes | os.PathLike[str] | os.PathLike[bytes]"
1820
)
1921

2022

distutils/compilers/C/base.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@
4646
_Ts = TypeVarTuple("_Ts")
4747

4848
_Macro: TypeAlias = Union[Tuple[str], Tuple[str, str | None]]
49-
_StrPathT = TypeVar("_StrPathT", bound=str | os.PathLike[str])
50-
_BytesPathT = TypeVar("_BytesPathT", bound=bytes | os.PathLike[bytes])
49+
_StrPathT = TypeVar("_StrPathT", bound="str | os.PathLike[str]")
50+
_BytesPathT = TypeVar("_BytesPathT", bound="bytes | os.PathLike[bytes]")
5151

5252

5353
class Compiler:

0 commit comments

Comments
 (0)