Author: Antonio Cuni <[email protected]>
Branch: hpy
Changeset: r98213:4063b6b8b3f3
Date: 2019-12-02 12:17 +0100
http://bitbucket.org/pypy/pypy/changeset/4063b6b8b3f3/
Log: fix the last bit of translation
diff --git a/pypy/module/hpy_universal/interp_hpy.py
b/pypy/module/hpy_universal/interp_hpy.py
--- a/pypy/module/hpy_universal/interp_hpy.py
+++ b/pypy/module/hpy_universal/interp_hpy.py
@@ -12,8 +12,15 @@
# these imports have side effects, as they call @API.func()
from pypy.module.hpy_universal import (
- interp_err, interp_long, interp_module, interp_number, interp_unicode,
interp_float,
- interp_bytes, interp_dict, interp_list,
+ interp_err,
+ interp_long,
+ interp_module,
+ interp_number,
+ interp_unicode,
+ interp_float,
+ interp_bytes,
+ interp_dict,
+ interp_list,
)
diff --git a/pypy/module/hpy_universal/interp_unicode.py
b/pypy/module/hpy_universal/interp_unicode.py
--- a/pypy/module/hpy_universal/interp_unicode.py
+++ b/pypy/module/hpy_universal/interp_unicode.py
@@ -29,6 +29,8 @@
@API.func("HPy HPyUnicode_AsUTF8String(HPyContext ctx, HPy h)")
def HPyUnicode_AsUTF8String(space, ctx, h):
+ from rpython.rlib.nonconst import NonConstant
+ if NonConstant(False): return 0 # needed for the annotator
raise NotImplementedError
@API.func("HPy HPyUnicode_FromWideChar(HPyContext ctx, const wchar_t *w,
HPy_ssize_t size)")
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit