ref: d359a98ab9cfc42de66ad35333bd6d6c0571b7ca
dir: /lib/std/test/striter.myr/
use std const main = { var chars = ['a', 'b', 'c'] var splits = ["foo", "+bar"] var i i = 0 for c : std.bychar("abc") std.assert(chars[i++] == c, "wrong char") ;; std.assert(i == chars.len, "wrong split count") i = 0 for sp : std.bysplit("foo+++bar", "++") std.assert(std.streq(splits[i++], sp), "wrong split {}", sp) ;; std.assert(i == splits.len, "wrong split count") }