Commits

Armin Rigo committed 8613b72

Attempt to dump a bit more information when hitting this error.

Comments (0)

Files changed (1)

pypy/interpreter/gateway.py

         for name, defaultval in self._staticdefs:
             if name.startswith('w_'):
                 assert defaultval is None, (
-                    "%s: default value for '%s' can only be None; "
+                    "%s: default value for '%s' can only be None, got %r; "
                     "use unwrap_spec(...=WrappedDefault(default))" % (
-                    self._code.identifier, name))
+                    self._code.identifier, name, defaultval))
                 defs_w.append(None)
             else:
                 defs_w.append(space.wrap(defaultval))