| ... | ... | @@ -28,7 +28,6 @@ pub const Buffer = struct { |
| 28 | 28 | /// Must deinitialize with deinit. |
| 29 | 29 | /// None of the other operations are valid until you do one of these: |
| 30 | 30 | /// * ::replaceContents |
| 31 | | /// * ::replaceContentsBuffer |
| 32 | 31 | /// * ::resize |
| 33 | 32 | pub fn initNull(allocator: *Allocator) Buffer { |
| 34 | 33 | return Buffer{ .list = ArrayList(u8).init(allocator) }; |
| ... | ... | @@ -116,7 +115,7 @@ pub const Buffer = struct { |
| 116 | 115 | return mem.eql(u8, self.list.items[start..l], m); |
| 117 | 116 | } |
| 118 | 117 | |
| 119 | | pub fn replaceContents(self: *const Buffer, m: []const u8) !void { |
| 118 | pub fn replaceContents(self: *Buffer, m: []const u8) !void { |
| 120 | 119 | try self.resize(m.len); |
| 121 | 120 | mem.copy(u8, self.list.toSlice(), m); |
| 122 | 121 | } |