summaryrefslogtreecommitdiff
path: root/lib/std/strjoin.myr
diff options
context:
space:
mode:
Diffstat (limited to 'lib/std/strjoin.myr')
-rw-r--r--lib/std/strjoin.myr5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/std/strjoin.myr b/lib/std/strjoin.myr
index 518a4dc..b8dc813 100644
--- a/lib/std/strjoin.myr
+++ b/lib/std/strjoin.myr
@@ -13,11 +13,10 @@ const strcat = {a, b
const strjoin = {strings, delim
var len, off
- var i
var s
len = 0
- for i = 0; i < strings.len; i++
+ for var i = 0; i < strings.len; i++
len += strings[i].len
;;
if strings.len > 0
@@ -26,7 +25,7 @@ const strjoin = {strings, delim
s = slalloc(len)
off = 0
- for i = 0; i < strings.len; i++
+ for var i = 0; i < strings.len; i++
slcp(s[off:off + strings[i].len], strings[i])
off += strings[i].len
/* we don't want to terminate the last string with delim */