terminal: rename ReadonlyStream to TerminalStream

Rename stream_readonly.zig to stream_terminal.zig and its exported
types from ReadonlyStream/ReadonlyHandler to TerminalStream. The
"readonly" name is now wrong since the handler now supports
settable effects callbacks. The new name better reflects that this
is a stream handler for updating terminal state.
This commit is contained in:
Mitchell Hashimoto
2026-03-22 20:12:09 -07:00
parent 07272ae88f
commit 67d8d86efd
6 changed files with 35 additions and 31 deletions

View File

@@ -419,11 +419,12 @@ pub const Action = union(Key) {
/// e.g. you don't need to pay a conditional branching cost on every single
/// action because the Zig compiler codegens separate code paths for every
/// single action at comptime.
pub fn Stream(comptime Handler: type) type {
pub fn Stream(comptime H: type) type {
return struct {
const Self = @This();
pub const Action = streampkg.Action;
pub const Handler = H;
const T = switch (@typeInfo(Handler)) {
.pointer => |p| p.child,