fn testUtf8IteratorOnAscii() !void 612
613
614
615
616
617
618
619
620
621
622
623
624
625
626fn testUtf8IteratorOnAscii() !void {
const s = Utf8View.initComptime("abc");
var it1 = s.iterator();
try testing.expect(mem.eql(u8, "a", it1.nextCodepointSlice().?));
try testing.expect(mem.eql(u8, "b", it1.nextCodepointSlice().?));
try testing.expect(mem.eql(u8, "c", it1.nextCodepointSlice().?));
try testing.expect(it1.nextCodepointSlice() == null);
var it2 = s.iterator();
try testing.expect(it2.nextCodepoint().? == 'a');
try testing.expect(it2.nextCodepoint().? == 'b');
try testing.expect(it2.nextCodepoint().? == 'c');
try testing.expect(it2.nextCodepoint() == null);
}