[pypy-commit] pypy hpy: fix translation, and make it possible to show pdb+ even when the test passes
antocuni
pypy.commits at gmail.com
Mon Dec 2 10:10:21 EST 2019
Author: Antonio Cuni <anto.cuni at gmail.com>
Branch: hpy
Changeset: r98218:9227c0af2212
Date: 2019-12-02 15:07 +0100
http://bitbucket.org/pypy/pypy/changeset/9227c0af2212/
Log: fix translation, and make it possible to show pdb+ even when the
test passes
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
@@ -35,6 +35,8 @@
@API.func("HPy HPyUnicode_FromWideChar(HPyContext ctx, const wchar_t *w, HPy_ssize_t size)")
def HPyUnicode_FromWideChar(space, ctx, wchar_p, size):
+ # remove the "const", else we can't call wcharpsize2utf8 later
+ wchar_p = rffi.cast(rffi.CWCHARP, wchar_p)
if wchar_p:
if size == -1:
size = wcharplen(wchar_p)
diff --git a/pypy/objspace/fake/checkmodule.py b/pypy/objspace/fake/checkmodule.py
--- a/pypy/objspace/fake/checkmodule.py
+++ b/pypy/objspace/fake/checkmodule.py
@@ -72,5 +72,9 @@
print
exc, val, tb = sys.exc_info()
traceback.print_exc()
- sys.p = p = PdbPlusShow(space.t)
+ sys.pdbplus = p = PdbPlusShow(space.t)
p.start(tb)
+ else:
+ if show_pdbplus:
+ sys.pdbplus = p = PdbPlusShow(space.t)
+ p.start(None)
More information about the pypy-commit
mailing list