8000 Fix some trivial things in cPickle due to the renaming of the string … · python/cpython@32c38e7 · GitHub
[go: up one dir, main page]

Skip to content

Commit 32c38e7

Browse files
committed
Fix some trivial things in cPickle due to the renaming of the string types.
1 parent 6cb726a commit 32c38e7

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

Modules/cPickle.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2217,13 +2217,11 @@ save(Picklerobject *self, PyObject *args, int pers_save)
22172217
}
22182218
break;
22192219

2220-
case 's':
2220+
case 's': /* str8, str */
22212221
if ((type == &PyString_Type) && (PyString_GET_SIZE(args) < 2)) {
22222222
res = save_string(self, args, 0);
22232223
goto finally;
22242224
}
2225-
2226-
case 'u':
22272225
if ((type == &PyUnicode_Type) && (PyString_GET_SIZE(args) < 2)) {
22282226
res = save_unicode(self, args, 0);
22292227
goto finally;
@@ -2244,14 +2242,11 @@ save(Picklerobject *self, PyObject *args, int pers_save)
22442242
}
22452243

22462244
switch (type->tp_name[0]) {
2247-
case 's':
2245+
case 's': /* str8, str */
22482246
if (type == &PyString_Type) {
22492247
res = save_string(self, args, 1);
22502248
goto finally;
22512249
}
2252-
break;
2253-
2254-
case 'u':
22552250
if (type == &PyUnicode_Type) {
22562251
res = save_unicode(self, args, 1);
22572252
goto finally;

0 commit comments

Comments
 (0)
0