1. Pypy
  2. Untitled project
  3. pypy


Amaury Forgeot d'Arc  committed 16b015b

cpyext: add PyUnicode_GetMax()

  • Participants
  • Parent commits 7bf5725
  • Branches default

Comments (0)

Files changed (1)

File pypy/module/cpyext/unicodeobject.py

View file
     except KeyError:
         return -1.0
+@cpython_api([], Py_UNICODE, error=CANNOT_FAIL)
+def PyUnicode_GetMax(space):
+    """Get the maximum ordinal for a Unicode character."""
+    return unichr(runicode.MAXUNICODE)
 @cpython_api([PyObject], rffi.CCHARP, error=CANNOT_FAIL)
 def PyUnicode_AS_DATA(space, ref):
     """Return a pointer to the internal buffer of the object. o has to be a