Revise comment about RocStr.init ownership

This commit is contained in:
Richard Feldman 2020-12-03 18:36:54 -05:00 committed by GitHub
parent e8b86ad887
commit 77d68491fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -10,7 +10,7 @@ const RocStr = extern struct {
str_bytes: ?[*]u8,
str_len: usize,
// This takes ownership of the pointed-to bytes if they won't fit in a
// This clones the pointed-to bytes if they won't fit in a
// small string, and returns a (pointer, len) tuple which points to them.
pub fn init(allocator: *Allocator, bytes_ptr: [*]const u8, length: usize) RocStr {
const rocStrSize = @sizeOf(RocStr);