]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
put returns on their own lines
authorBenjamin Peterson <benjamin@python.org>
Sat, 4 Feb 2012 00:22:31 +0000 (19:22 -0500)
committerBenjamin Peterson <benjamin@python.org>
Sat, 4 Feb 2012 00:22:31 +0000 (19:22 -0500)
Objects/exceptions.c

index 711c87dea9ad4597f223894950431e040a34de40..26571856492856d36452f522d84aa36071a74dc3 100644 (file)
@@ -306,7 +306,8 @@ BaseException_set_args(PyBaseExceptionObject *self, PyObject *val)
         return -1;
     }
     seq = PySequence_Tuple(val);
-    if (!seq) return -1;
+    if (!seq)
+        return -1;
     Py_CLEAR(self->args);
     self->args = seq;
     return 0;
@@ -773,7 +774,8 @@ EnvironmentError_reduce(PyEnvironmentErrorObject *self)
      * file name given to EnvironmentError. */
     if (PyTuple_GET_SIZE(args) == 2 && self->filename) {
         args = PyTuple_New(3);
-        if (!args) return NULL;
+        if (!args)
+            return NULL;
 
         tmp = PyTuple_GET_ITEM(self->args, 0);
         Py_INCREF(tmp);
@@ -1071,7 +1073,8 @@ SyntaxError_init(PySyntaxErrorObject *self, PyObject *args, PyObject *kwds)
     if (lenargs == 2) {
         info = PyTuple_GET_ITEM(args, 1);
         info = PySequence_Tuple(info);
-        if (!info) return -1;
+        if (!info)
+            return -1;
 
         if (PyTuple_GET_SIZE(info) != 4) {
             /* not a very good error message, but it's what Python 2.4 gives */
@@ -1167,9 +1170,11 @@ SyntaxError_str(PySyntaxErrorObject *self)
         str = PyObject_Str(self->msg);
     else
         str = PyObject_Str(Py_None);
-    if (!str) return NULL;
+    if (!str)
+        return NULL;
     /* Don't fiddle with non-string return (shouldn't happen anyway) */
-    if (!PyString_Check(str)) return str;
+    if (!PyString_Check(str))
+        return str;
 
     /* XXX -- do all the additional formatting with filename and
        lineno here */
@@ -2111,7 +2116,8 @@ _PyExc_Init(void)
 
     m = Py_InitModule4("exceptions", functions, exceptions_doc,
         (PyObject *)NULL, PYTHON_API_VERSION);
-    if (m == NULL) return;
+    if (m == NULL)
+        return;
 
     bltinmod = PyImport_ImportModule("__builtin__");
     if (bltinmod == NULL)