Added edge case test to mem.count

Some implementations break on this edge case. Thought relevant to add it.
This commit is contained in:
Cléo Rebert
2020-08-27 01:29:16 +02:00
committed by Andrew Kelley
parent 5fed721290
commit fc001110b4

View File

@@ -920,6 +920,7 @@ test "mem.count" {
testing.expect(count(u8, "foo bar", "o bar") == 1);
testing.expect(count(u8, "foofoofoo", "foo") == 3);
testing.expect(count(u8, "fffffff", "ff") == 3);
testing.expect(count(u8, "owowowu", "owowu") == 1);
}
/// Reads an integer from memory with size equal to bytes.len.