mirror of https://github.com/python/cpython.git
Of course, when the type of the argument to dis() is unsupported, it
should raise TypeError, not ValueError...
This commit is contained in:
parent
bd30795192
commit
00f86e6086
|
@ -14,7 +14,7 @@ def dis(x=None):
|
|||
if hasattr(x, 'co_code'):
|
||||
disassemble(x)
|
||||
else:
|
||||
raise ValueError, \
|
||||
raise TypeError, \
|
||||
"don't know how to disassemble %s objects" % \
|
||||
type(x).__name__
|
||||
|
||||
|
|
Loading…
Reference in New Issue