File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -127,16 +127,24 @@ class Inextensible(NamedTuple):
127127 x: int
128128
129129[file driver.py]
130- from typing import ForwardRef, Optional
130+ import sys
131+ from typing import Optional
131132from native import ClassIR, FuncIR, Record
132133
134+ if sys.version_info >= (3, 14):
135+ from test.support import EqualToForwardRef
136+ type_forward_ref = EqualToForwardRef
137+ else:
138+ from typing import ForwardRef
139+ type_forward_ref = ForwardRef
140+
133141assert Record.__annotations__ == {
134142 'st_mtime': float,
135143 'st_size': int,
136144 'is_borrowed': bool,
137145 'hash': str,
138146 'python_path': tuple,
139- 'type': ForwardRef ('ClassIR'),
147+ 'type': type_forward_ref ('ClassIR'),
140148 'method': FuncIR,
141149 'shadow_method': type,
142150 'classes': dict,
You can’t perform that action at this time.
0 commit comments