From 92f7cd309b44efa9bc5d944df9a993357a4975d6 Mon Sep 17 00:00:00 2001 From: by Date: Wed, 15 Jul 2026 07:25:02 +0800 Subject: [PATCH] fix(utilities): fix CircularBuffer read/write using u8 instead of generic T --- core/src/utilities.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/utilities.zig b/core/src/utilities.zig index 9083fa18c..17d6323b7 100644 --- a/core/src/utilities.zig +++ b/core/src/utilities.zig @@ -576,7 +576,7 @@ pub fn CircularBuffer(comptime T: type, comptime len: usize) type { buffer.full = true; } - pub fn read(buffer: *Self, out: []u8) usize { + pub fn read(buffer: *Self, out: []T) usize { buffer.assert_valid(); defer buffer.assert_valid(); @@ -589,7 +589,7 @@ pub fn CircularBuffer(comptime T: type, comptime len: usize) type { return count; } - pub fn write(buffer: *Self, data: []const u8) error{Full}!void { + pub fn write(buffer: *Self, data: []const T) error{Full}!void { buffer.assert_valid(); defer buffer.assert_valid(); for (data) |d| {