fix an error of [][:-1]

This commit is contained in:
BLUELOVETH 2023-02-14 16:17:54 +00:00
parent 0e4052744b
commit af9f2ba6c4

View File

@ -56,6 +56,7 @@ struct Slice {
if(stop < 0) stop += len; if(stop < 0) stop += len;
if(start < 0) start = 0; if(start < 0) start = 0;
if(stop > len) stop = len; if(stop > len) stop = len;
if(stop < start) stop = start;
} }
}; };