diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-20 04:36:44 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-20 04:36:47 -0300 |
| commit | fc9e2eaf5ad86719a3bc57d18ce4ad302461dfbd (patch) | |
| tree | 301495bfaf9e814b79bb620f101e3c52e3f53601 /abi/wire.zig | |
| parent | 852299dd8d056b90446508757d8c6dacf8975abe (diff) | |
| download | pardes-fc9e2eaf5ad86719a3bc57d18ce4ad302461dfbd.tar.gz pardes-fc9e2eaf5ad86719a3bc57d18ce4ad302461dfbd.zip | |
build: the grammar set is one option, `grammars`, with `none | minimal | full` (pardes-build-2 item 3; the start design's step 3, P31's lean): for a package that depends on pardes `.grammars = .minimal` where it wrote `.@"tree-sitter" = .minimal`, and for pardes's own products `-Dgrammars=minimal` where `-Dtree-sitter=minimal` was (one option, not two spellings of one: no live gate script passes -Dtree-sitter, only two configure-matrix scripts of an earlier agent's and the first build pass's shapes script, which also name test/lib and the deleted `disabled` and change anyway; the three consumers' lines change for `.grammars` anyway); `none` is tree-sitter's runtime with no grammar, for a program that hands in its own at run time (sketchbook's examples/live, which set `zig` only because it was the smallest set that kept syntax on: `zig`, its one setter, goes, and the Zig grammar is a minimal one: grammar_manifest's tiers are minimal and full); syntax.zig's sets read `none` (`minimal_grammars` is `!= .none`, four tests' doubled condition one), the Build pane prints the set's own name (`none` was what it printed for the zig set), and abi/wire.zig hashes the set as the four words it was hashed as, so a minimal or a full set's semantics did not move (8b6382fddba7b382 full, 0520895ac88d25ad minimal, as at items 1 and 2) and `none` hashes as highlighting with no grammar (794d23e0255281f8; the old zig set's hash is gone with it); test/lib asks with `.grammars`; the manual's table, its library section's two lines and the changelog say it; build.zig and build/ 2,974 -> 2,971 lines; -Dgrammars=full, minimal and none each install and pass lib-test, and the old spelling is refused (`invalid option: "tree-sitter"`); the suites run on the stack's top (item 5)
Co-Authored-By: Claude Opus <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'abi/wire.zig')
| -rw-r--r-- | abi/wire.zig | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/abi/wire.zig b/abi/wire.zig index 4f6e199b..a36e746b 100644 --- a/abi/wire.zig +++ b/abi/wire.zig @@ -63,19 +63,19 @@ const family = switch (config.platform) { pub const semantics: u64 = blk: { @setEvalBranchQuota(1_000_000); // The grammar set as the four words it was hashed as when it was four - // options (highlighting, zig, minimal, full), so the hash stays: - // highlighting and the Zig grammar are in every set. + // options (highlighting, zig, minimal, full), so the hash of a minimal + // or a full set stays: every set has highlighting, `none` no grammar. const g = config.grammars; // The two long ones (the dependencies, 2.5 KB, and the tape's shape, // 11 KB) joined on, not formatted: formatting them at comptime was 5 % // of a compile of the core. break :blk std.hash.Wyhash.hash(0, std.fmt.comptimePrint( - "wire {d}\npardes {s} {s}\n{s} grammars true true {} {} workspace_tag {} sources {}\nusize {d} {t}\n", + "wire {d}\npardes {s} {s}\n{s} grammars true {} {} {} workspace_tag {} sources {}\nusize {d} {t}\n", .{ - version, build_info.version, build_info.commit orelse "unstamped", - family, g != .zig, g == .full, - config.workspace_tag, config.embed_sources, @sizeOf(usize), - builtin.cpu.arch.endian(), + version, build_info.version, build_info.commit orelse "unstamped", + family, g != .none, g != .none, + g == .full, config.workspace_tag, config.embed_sources, + @sizeOf(usize), builtin.cpu.arch.endian(), }, ) ++ build_info.deps ++ "\n" ++ pardes.tape.shape); }; |
