Commit 7d1dc885 authored by da-woods's avatar da-woods Committed by GitHub

Make annotation tests work with non-evaluated annotations (GH-4050)

Backported from 3dc2b9df
Partial fix for https://github.com/cython/cython/issues/3919
parent bb49a03a
......@@ -30,10 +30,10 @@ def anno_gen(x: 'int') -> 'float':
>>> next(gen)
2.0
>>> ret, arg = sorted(anno_gen.__annotations__.items())
>>> print(ret[0]); print(ret[1])
>>> print(ret[0]); print(str(ret[1]).strip("'")) # strip makes it pass with/without PEP563
return
float
>>> print(arg[0]); print(arg[1])
>>> print(arg[0]); print(str(arg[1]).strip("'"))
x
int
"""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment