We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7e2a488 commit 8769049Copy full SHA for 8769049
py/objstr.c
@@ -663,9 +663,7 @@ STATIC mp_obj_t str_rsplit(size_t n_args, const mp_obj_t *args) {
663
}
664
res->items[idx--] = mp_obj_new_str_of_type(self_type, s + sep_len, last - s - sep_len);
665
last = s;
666
- if (splits > 0) {
667
- splits--;
668
- }
+ splits--;
669
670
if (idx != 0) {
671
// We split less parts than split limit, now go cleanup surplus
0 commit comments