Core library clean up: Make range expressions more consistent and replace uses of .. with ..=

This commit is contained in:
gingerBill
2021-06-14 11:15:25 +01:00
parent 3ca887a60a
commit 86649e6b44
23 changed files with 80 additions and 84 deletions
+2 -2
View File
@@ -39,7 +39,7 @@ encode :: proc(d: []u16, s: []rune) -> int {
d[n] = u16(r);
n += 1;
case _surr_self .. MAX_RUNE:
case _surr_self ..= MAX_RUNE:
if m+2 < n { break loop; }
r1, r2 := encode_surrogate_pair(r);
d[n] = u16(r1);
@@ -65,7 +65,7 @@ encode_string :: proc(d: []u16, s: string) -> int {
d[n] = u16(r);
n += 1;
case _surr_self .. MAX_RUNE:
case _surr_self ..= MAX_RUNE:
if m+2 < n { break loop; }
r1, r2 := encode_surrogate_pair(r);
d[n] = u16(r1);