From 5de9d27458cd8ff7e326532e8923c933e141ea7f Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Mon, 9 Nov 2026 03:31:33 -0300 Subject: idioms: swallows a caller can decide on, decided: a key a macro or a repeat cannot keep is said (Macro.append returns error{OutOfMemory}), a kind's found rows and list pane say their copy's failure as their fill's, a kind word's value past its pane's 256-byte record is said instead of dropped, and the REPL ask record's two prints, which fit, are unreachable with the reason Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- src/Kind.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Kind.zig') diff --git a/src/Kind.zig b/src/Kind.zig index 806e9558..0a8fc7ae 100644 --- a/src/Kind.zig +++ b/src/Kind.zig @@ -971,7 +971,7 @@ fn moreFound(p: *Pardes, id: usize, rows: []const u8) void { const rp = p.panes[pane.search_pane orelse return] orelse return; const rf = if (rp.file) |*f| f else return; const o = if (rf.output) |*x| x else return; - const content = std.mem.concat(p.gpa, u8, &.{ rf.content, rows }) catch return; + const content = std.mem.concat(p.gpa, u8, &.{ rf.content, rows }) catch |err| return p.reportError(id, "found", err); pardes.panes.Output.fillResults(p, id, std.fs.path.dirname(rf.path) orelse p.sessionDir(), .search, o.arg(), content, null) catch |err| p.reportError(id, "found", err); } @@ -1137,7 +1137,7 @@ pub var seed_base: u64 = 0; /// kind's pane, a Look of one going to its kind (look.zig lookKind). fn textPane(p: *Pardes, id: usize, slot: *const Slot, name: []const u8, text: []const u8) void { const dir = std.fs.path.dirname(slot.path) orelse p.sessionDir(); - const content = p.gpa.dupe(u8, text) catch return; + const content = p.gpa.dupe(u8, text) catch |err| return p.reportError(id, name, err); pardes.panes.Output.fillResults(p, id, dir, .kind, name, content, null) catch |err| p.reportError(id, name, err); } -- cgit v1.3