Commit c42ad917 authored by Stefan Behnel's avatar Stefan Behnel

Merge branch '0.29.x'

parents 0b4207a2 343262ae
......@@ -456,6 +456,16 @@ Other changes
* Support for Python 2.6 was removed.
0.29.22 (2020-??-??)
====================
Bugs fixed
----------
* ``repr()`` was assumed to return ``str`` instead of ``unicode`` with ``language_level=3``.
(Github issue #3736)
0.29.21 (2020-07-09)
====================
......
......@@ -205,7 +205,7 @@ builtin_function_table = [
#('raw_input', "", "", ""),
#('reduce', "", "", ""),
BuiltinFunction('reload', "O", "O", "PyImport_ReloadModule"),
BuiltinFunction('repr', "O", "O", "PyObject_Repr", builtin_return_type='str'),
BuiltinFunction('repr', "O", "O", "PyObject_Repr"), # , builtin_return_type='str'), # add in Cython 3.1
#('round', "", "", ""),
BuiltinFunction('setattr', "OOO", "r", "PyObject_SetAttr"),
#('sum', "", "", ""),
......
......@@ -654,3 +654,11 @@ async def async_def_annotations(x: 'int') -> 'float':
u'int'
"""
return float(x)
def repr_returns_str(x) -> str:
"""
>>> repr_returns_str(123)
'123'
"""
return repr(x)
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