aboutsummaryrefslogtreecommitdiff
path: root/core/strings
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2020-03-05 21:12:16 +0000
committergingerBill <bill@gingerbill.org>2020-03-05 21:12:16 +0000
commitdb7a3ffd2a66d976c985ebfc2c5a96b21c9684e3 (patch)
treef5fd15ae28e664dd37f69018e5a6ce1f35e0beab /core/strings
parent7d93dd60240a58834c950f341ec9761050784b3b (diff)
parentc213d72ec6a64e973017bf326e0f241a3eef8adb (diff)
Merge branch 'master' into llvm-integration
Diffstat (limited to 'core/strings')
-rw-r--r--core/strings/strings.odin2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/strings/strings.odin b/core/strings/strings.odin
index a477b9e13..fd3808684 100644
--- a/core/strings/strings.odin
+++ b/core/strings/strings.odin
@@ -325,7 +325,7 @@ last_index :: proc(s, substr: string) -> int {
case n == 1:
return last_index_byte(s, substr[0]);
case n == len(s):
- return substr == s ? 0 : -1;
+ return 0 if substr == s else -1;
case n > len(s):
return -1;
}