From 00f86e6086444b94653d0fb01f2fa18e9a24f59a Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Fri, 17 Jan 1997 20:08:18 +0000 Subject: Of course, when the type of the argument to dis() is unsupported, it should raise TypeError, not ValueError... --- Lib/dis.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/dis.py b/Lib/dis.py index 50e6c1d..3957f9c 100644 --- a/Lib/dis.py +++ b/Lib/dis.py @@ -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__ -- cgit v0.12