summaryrefslogtreecommitdiff
path: root/core/builtins.zig
diff options
context:
space:
mode:
Diffstat (limited to 'core/builtins.zig')
-rw-r--r--core/builtins.zig6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/builtins.zig b/core/builtins.zig
index a236b0d6..0c643a18 100644
--- a/core/builtins.zig
+++ b/core/builtins.zig
@@ -1248,7 +1248,7 @@ pub const Del = struct {
var rec: [32]u8 = undefined;
pardes.ctlfs.events.notePath(c.p, "ask", std.fmt.bufPrint(&rec, "{d} del k j", .{c.pane.serial}) catch unreachable); // a u32 fits 32
// The question says Del already.
- if (c.pane.msg_announcement) c.pane.msg_len = 0;
+ _ = c.p.messages.retire(&.{.echo});
return;
}
c.p.removePane(c.id, to) catch |err| return c.p.reportError(.at(c.id), "close", err);
@@ -2363,7 +2363,7 @@ test "Exit over a ctl write or a click names every pane it asks about, a second
try std.testing.expect(std.mem.endsWith(u8, unsavedList(p), "\nExit again to discard\n"));
var noticed = false;
for (p.panes) |slot| if (slot) |pane| {
- noticed = noticed or std.mem.eql(u8, pane.msg[0..pane.msg_len], "2 unsaved panes \u{2014} Exit again to discard");
+ noticed = noticed or std.mem.eql(u8, p.messages.saidBy(pane), "2 unsaved panes \u{2014} Exit again to discard");
};
try std.testing.expect(noticed);
// Edited since: only that one is named again (acme's rule).
@@ -2463,7 +2463,7 @@ test "Kill stops the commands pardes typed, bare all and by name those that matc
p.host = .{ .vtable = &killed.vtable };
// Nothing running: nothing to stop, and never the shell; said.
try std.testing.expectEqual(@as(usize, 0), killed.count(p, "Kill"));
- try std.testing.expectEqualStrings("Kill: nothing running", p.panes[term].?.msg[0..p.panes[term].?.msg_len]);
+ try std.testing.expectEqualStrings("Kill: nothing running", p.messages.saidBy(p.panes[term].?));
_ = exec.execute(p, term, "make -j8");
while (p.nextEffect()) |_| {}
// Typed but not started yet (no C mark): not running.