summaryrefslogtreecommitdiff
path: root/core/Stream.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-20 03:23:49 -0300
committerGabriel Schneider <[email protected]>2026-11-20 03:57:11 -0300
commit1e127c3968205f0e42faa4eb5b894cea296346d0 (patch)
tree314eac62c4e47f8b20c844dacc957b706a87dc62 /core/Stream.zig
parent11f55f018a5eb0699d58627a4f2ea39c2b7f5e89 (diff)
downloadpardes-1e127c3968205f0e42faa4eb5b894cea296346d0.tar.gz
pardes-1e127c3968205f0e42faa4eb5b894cea296346d0.zip
build: pardes-isolate and `zig build run-isolated` are deleted (pardes-build-2 item 1; P31's Q3, decided on the evidence 2026-11-20): the terminal's pardes compiled with `isolated = true`, a build whose host supplied only the terminal (no file, pty, clipboard, LSP or watch calls: tui.zig's second Host table) and whose filesystem was absent (`fs.platform_has_fs` false: every libc path compiled away, the virtual tree and the embedded sources alone), arriving on `src/pardes.zig` read out of the binary when no file was named; it did not compile on the base (`zig build run-isolated -Dplatform=tui -- version`: core/builtins.zig:510 `error.FileNotFound` not in `fs.readFile`'s set, core/ninep/ctl.zig:1298 `error.OutOfMemory` not in `Dir.refresh`'s set) and no test, gate or document ran it; out with it: its module set and step in build.zig, `Core.isolated` and the `isolated` option in build/core.zig, `pardes.isolated` (core/root.zig), `fs.platform_has_fs` and the 60 guards on the two (whole lines in core/Stream.zig, Dir.zig, Plumb.zig, fs.zig, look.zig, Query.zig, edit_cmd.zig, dump.zig, test/fs_namespace.zig, test/terminal.zig; a term of a condition in dev/file_watch.zig's six tests, fs.zig's readFileLimit, whose virtual branch now takes `/virtual/` alone, and one Stream.zig test), Stream.zig's search failing at once without a filesystem, tui.zig's `isolated_vtable`, runtime/main.zig's `src/pardes.zig` default (a file that does not exist), and the mention in docs/next-terminal.md; the changelog says it is gone; build.zig and build/ 2,996 -> 2,981 lines; `pardes version`'s semantics line did not move (`isolated` was never in its text): 8b6382fddba7b382 on tui, gui, the bare build's two, both statics and FreeBSD (gpu/tree2's base binary says the same), 0520895ac88d25ad with -Dtree-sitter=minimal; every shape configures (12) and builds (tui, gui, bare, static musl and gui, FreeBSD, -Dtree-sitter=minimal, the macOS library for Linux and aarch64-macos), -Dtree-sitter=disabled failing as on the base (core/indent.zig:48); tui core-test 856/1006 (150 skipped), shell-test 1046/1049, pane-test 183/184, behaviour-test 275/275 and -- --replay 275/275, term-test 17/17, kitty-test 45/45, addon-test 5/5, lib-test, hxlib 538 cases 0 mismatches, process-test 1 of 144 failed (pagercolor, on the flaky list: passes alone, 931 ms), gui unit-test 1643/1647 (the perf check's BaselineHarnessMismatch, the base's); load 6-17 on 16 cores
Co-Authored-By: Claude Opus <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'core/Stream.zig')
-rw-r--r--core/Stream.zig13
1 files changed, 1 insertions, 12 deletions
diff --git a/core/Stream.zig b/core/Stream.zig
index 5960d249..e5825e9d 100644
--- a/core/Stream.zig
+++ b/core/Stream.zig
@@ -478,7 +478,6 @@ fn parseWork(io: std.Io, job: *TextJob, ctx: ?*anyopaque, sink: Sink) void {
}
fn now() u64 {
- if (comptime !filesystem.platform_has_fs) return 0;
const t = std.Io.Clock.awake.now(std.Io.Threaded.global_single_threaded.io());
return @intCast(@max(0, t.nanoseconds));
}
@@ -635,10 +634,6 @@ pub fn runHere(p: *Pardes, gen: u32, comptime in_call: bool) void {
};
return;
}
- if (comptime !filesystem.platform_has_fs) {
- p.stream.state = .failed;
- return;
- }
const s = &p.stream;
if (gen != s.gen or s.state != .searching) return;
const job = makeJob(p.gpa, s) catch |err| {
@@ -1163,7 +1158,6 @@ const Rogue = struct {
};
test "Stream: a stale generation's rows never land in the query pane, however two generations race (walk and rg)" {
- if (comptime !filesystem.platform_has_fs) return;
var tmp = testing.tmpDir(.{});
defer tmp.cleanup();
var root_buf: [4096]u8 = undefined;
@@ -1243,7 +1237,6 @@ test "Stream: a stale generation's rows never land in the query pane, however tw
}
test "Stream: the listing of files for Find on a worker, a cap of hits stops the walk on the loop" {
- if (comptime !filesystem.platform_has_fs) return;
var tmp = testing.tmpDir(.{});
defer tmp.cleanup();
var root_buf: [4096]u8 = undefined;
@@ -1273,7 +1266,6 @@ test "Stream: the listing of files for Find on a worker, a cap of hits stops the
}
test "Stream: a big text's declarations are parsed on a worker, never the loop, and the rows of its / regroup under them" {
- if (comptime !filesystem.platform_has_fs) return;
const p = try Pardes.init(testing.allocator, .{ .tty_only = true, .cols = 120, .rows = 40 });
defer p.deinit();
var text: std.ArrayList(u8) = .empty;
@@ -1312,7 +1304,7 @@ test "Stream: a big text's declarations are parsed on a worker, never the loop,
}
test "Stream: a scroll's colours are painted ahead on a worker, so PageDown after PageDown parses nothing on the frame" {
- if (comptime !filesystem.platform_has_fs or !syntax.enabled) return;
+ if (comptime !syntax.enabled) return;
const p = try Pardes.init(testing.allocator, .{ .tty_only = true, .cols = 120, .rows = 40 });
defer p.deinit();
var text: std.ArrayList(u8) = .empty;
@@ -1355,7 +1347,6 @@ test "Stream: a scroll's colours are painted ahead on a worker, so PageDown afte
}
test "Stream: a Grep stops at its 2000 lines and waits; More in the query pane's tag goes on" {
- if (comptime !filesystem.platform_has_fs) return;
var tmp = testing.tmpDir(.{});
defer tmp.cleanup();
var root_buf: [4096]u8 = undefined;
@@ -1404,7 +1395,6 @@ test "Stream: a Grep stops at its 2000 lines and waits; More in the query pane's
}
test "Stream: a Grep's rows recoloured are made again, never written, and a dump of them dropped by an edit loads to its digest" {
- if (comptime !filesystem.platform_has_fs) return;
if (!syntax.enabled or !syntax.readyApart("c.zig")) return;
var tmp = testing.tmpDir(.{});
defer tmp.cleanup();
@@ -1476,7 +1466,6 @@ test "Stream: a Grep's rows recoloured are made again, never written, and a dump
}
test "Stream: a Grep's rows are coloured as their file's language colours them, the file painted on a worker, the match tint on top" {
- if (comptime !filesystem.platform_has_fs) return;
if (!syntax.enabled or !syntax.readyApart("c.zig")) return;
var tmp = testing.tmpDir(.{});
defer tmp.cleanup();