[Python-3000-checkins] r62741 - python/branches/py3k/Objects/exceptions.c

georg.brandl python-3000-checkins at python.org
Mon May 5 23:38:47 CEST 2008


Author: georg.brandl
Date: Mon May  5 23:38:47 2008
New Revision: 62741

Log:
Give with_traceback a docstring.


Modified:
   python/branches/py3k/Objects/exceptions.c

Modified: python/branches/py3k/Objects/exceptions.c
==============================================================================
--- python/branches/py3k/Objects/exceptions.c	(original)
+++ python/branches/py3k/Objects/exceptions.c	Mon May  5 23:38:47 2008
@@ -151,11 +151,16 @@
     return self;
 }
 
+PyDoc_STRVAR(with_traceback_doc,
+"Exception.with_traceback(tb) --\n\
+    set self.__traceback__ to tb and return self.");
+
 
 static PyMethodDef BaseException_methods[] = {
    {"__reduce__", (PyCFunction)BaseException_reduce, METH_NOARGS },
    {"__setstate__", (PyCFunction)BaseException_setstate, METH_O },
-   {"with_traceback", (PyCFunction)BaseException_with_traceback, METH_O },
+   {"with_traceback", (PyCFunction)BaseException_with_traceback, METH_O,
+    with_traceback_doc},
    {NULL, NULL, 0, NULL},
 };
 


More information about the Python-3000-checkins mailing list