strings: preserve UTF-8 and boundary invariants
This commit is contained in:
@@ -19,5 +19,5 @@ import encoding.utf8;
|
||||
let r: str = strings.frombytes(b);
|
||||
assert(!(!streq(r, "hello")));
|
||||
assert(!(r.ptr != s.ptr)); // borrowed, not copied
|
||||
assert(!(r.cap != r.len));
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user