bpo-35133: Fix mistakes when concatenate string literals on different lines. (GH-10284)
Two kind of mistakes:
1. Missed space. After concatenating there is no space between words.
2. Missed comma. Causes unintentional concatenating in a list of strings.
(cherry picked from commit 34fd4c20198dea6ab2fe8dc6d32d744d9bde868d)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
diff --git a/Modules/_datetimemodule.c b/Modules/_datetimemodule.c
index f538808..1f15367 100644
--- a/Modules/_datetimemodule.c
+++ b/Modules/_datetimemodule.c
@@ -3443,7 +3443,7 @@
return result;
Inconsistent:
- PyErr_SetString(PyExc_ValueError, "fromutc: tz.dst() gave"
+ PyErr_SetString(PyExc_ValueError, "fromutc: tz.dst() gave "
"inconsistent results; cannot convert");
/* fall through to failure */
diff --git a/Modules/_io/textio.c b/Modules/_io/textio.c
index 73d1b2e..9d0d9ca 100644
--- a/Modules/_io/textio.c
+++ b/Modules/_io/textio.c
@@ -1313,7 +1313,7 @@
/* Check if something is in the read buffer */
if (self->decoded_chars != NULL) {
if (encoding != Py_None || errors != Py_None || newline_obj != NULL) {
- _unsupported("It is not possible to set the encoding or newline"
+ _unsupported("It is not possible to set the encoding or newline "
"of stream after the first read");
return NULL;
}
diff --git a/Modules/_pickle.c b/Modules/_pickle.c
index ba8962d..03f575e 100644
--- a/Modules/_pickle.c
+++ b/Modules/_pickle.c
@@ -4614,7 +4614,7 @@
}
else {
PyErr_Format(PyExc_TypeError,
- "'memo' attribute must be a PicklerMemoProxy object"
+ "'memo' attribute must be a PicklerMemoProxy object "
"or dict, not %.200s", Py_TYPE(obj)->tp_name);
return -1;
}
@@ -7060,7 +7060,7 @@
}
else {
PyErr_Format(PyExc_TypeError,
- "'memo' attribute must be an UnpicklerMemoProxy object"
+ "'memo' attribute must be an UnpicklerMemoProxy object "
"or dict, not %.200s", Py_TYPE(obj)->tp_name);
return -1;
}