Author: Armin Rigo <[email protected]>
Branch: reverse-debugger
Changeset: r85486:0f2ae8aeae0c
Date: 2016-07-01 12:57 +0200
http://bitbucket.org/pypy/pypy/changeset/0f2ae8aeae0c/
Log: Use marshal version 0 to avoid new_interned_str().
diff --git a/pypy/interpreter/reverse_debugging.py
b/pypy/interpreter/reverse_debugging.py
--- a/pypy/interpreter/reverse_debugging.py
+++ b/pypy/interpreter/reverse_debugging.py
@@ -499,9 +499,11 @@
space = dbstate.space
try:
code = compile(expression, 'eval')
+ # Note: using version 0 to marshal watchpoints, in order to
+ # avoid space.new_interned_str() on unmarshal. This is
+ # forbidden because it comes with lasting side-effects.
marshalled_code = space.str_w(interp_marshal.dumps(
- space, space.wrap(code),
- space.wrap(interp_marshal.Py_MARSHAL_VERSION)))
+ space, space.wrap(code), space.wrap(0)))
except OperationError as e:
revdb.send_watch(e.errorstr(space), ok_flag=0)
else:
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit