Commit 714123e3 authored by Stefan Behnel's avatar Stefan Behnel

Improve error message if assertion fails.

parent 82c8d297
......@@ -13023,7 +13023,7 @@ class PyTypeTestNode(CoercionNode):
# The arg is known to be a Python object, and
# the dst_type is known to be an extension type.
assert dst_type.is_extension_type or dst_type.is_builtin_type, \
"PyTypeTest on non extension type %s" % dst_type
"PyTypeTest for %s against non extension type %s" % (arg.type, dst_type)
CoercionNode.__init__(self, arg)
self.type = dst_type
self.result_ctype = arg.ctype()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment