diff options
author | Benjamin Peterson <benjamin@python.org> | 2009-02-16 16:15:34 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2009-02-16 16:15:34 (GMT) |
commit | b7851694e0bcfad81844021da0dead4d0948c651 (patch) | |
tree | 574ba878138481b15049e34c0f89b6509eb0ea20 /Doc | |
parent | 6ab247942c794d17b087b195a0d42305d64b1718 (diff) | |
download | cpython-b7851694e0bcfad81844021da0dead4d0948c651.zip cpython-b7851694e0bcfad81844021da0dead4d0948c651.tar.gz cpython-b7851694e0bcfad81844021da0dead4d0948c651.tar.bz2 |
raise more generic Exception() instead of RuntimeError() #5281
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/reference/simple_stmts.rst | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Doc/reference/simple_stmts.rst b/Doc/reference/simple_stmts.rst index 8797ece..1e3cb85 100644 --- a/Doc/reference/simple_stmts.rst +++ b/Doc/reference/simple_stmts.rst @@ -503,7 +503,7 @@ You can create an exception and set your own traceback in one step using the :meth:`with_traceback` exception method (which returns the same exception instance, with its traceback set to its argument), like so:: - raise RuntimeError("foo occurred").with_traceback(tracebackobj) + raise Exception("foo occurred").with_traceback(tracebackobj) .. index:: pair: exception; chaining __cause__ (exception attribute) |