summaryrefslogtreecommitdiff
path: root/test/macos_e2e.swift
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-16 22:43:18 -0300
committerGabriel Schneider <[email protected]>2026-11-17 12:15:01 -0300
commit383b60b79146937e12c82abaaca2ce213d210b7f (patch)
tree82fe9805ab85ef72fbc38fa56569632081a8964e /test/macos_e2e.swift
parentf2b02c455f2bcdfb905a015eefbb630a28b4b12e (diff)
downloadpardes-383b60b79146937e12c82abaaca2ce213d210b7f.tar.gz
pardes-383b60b79146937e12c82abaaca2ce213d210b7f.zip
syntax: the highlight queries are filtered by the build, not in every compile: colorQuery kept each grammar's patterns whose captures pardes colours by scanning the 29 highlights.scm byte by byte at comptime, a quarter of a full recompile of the core (and again in each of the ~15 artifacts that import it); build.zig's treeSitter now runs the same filter once over the query it reads (grammar_manifest.colorQuery, a plain function, with Syn and synFor's capture-to-class table beside it, the one copy both the build and syntax.zig read), so ts_queries' <name>_highlights is the filtered query and Spec.query_src a field read; typst's supplement is the manifest's highlights_extra, appended before the filter as before; <name>_highlights_unfiltered is the whole query, for the test that the filter keeps every colour; a package that depends on pardes gets the same through library's treeSitter, for its own grammar set; proven byte-identical before the comptime path went (29 grammars, 28,398 filtered bytes of 79,678); core-test's forced full recompile 12.7-12.9 s wall / 17.5 s CPU to 9.7-10.1 s / 14.6 s; syntax snapshots unchanged; the changelog says so
Diffstat (limited to 'test/macos_e2e.swift')
0 files changed, 0 insertions, 0 deletions