| ... | @@ -77,7 +77,7 @@ pub fn Decompress(comptime ReaderType: type) type { | ... | @@ -77,7 +77,7 @@ pub fn Decompress(comptime ReaderType: type) type { |
| 77 | const input = self.to_read.items; | 77 | const input = self.to_read.items; |
| 78 | const n = @min(input.len, output.len); | 78 | const n = @min(input.len, output.len); |
| 79 | @memcpy(output[0..n], input[0..n]); | 79 | @memcpy(output[0..n], input[0..n]); |
| 80 | @memcpy(input[0 .. input.len - n], input[n..]); | 80 | std.mem.copyForwards(u8, input[0 .. input.len - n], input[n..]); |
| 81 | self.to_read.shrinkRetainingCapacity(input.len - n); | 81 | self.to_read.shrinkRetainingCapacity(input.len - n); |
| 82 | return n; | 82 | return n; |
| 83 | } | 83 | } |