NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Go modules · #2396 by repository stars
Last release 2 days ago
21 Sep 2026
Ships on a steady schedule
a new release about every 8 days
Nearly every release is documented
notes for 59 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
7 months old
849 releases · first in 2026
One column per month.
Nothing published for this version
Cobol frontier and perf-ratchet release. This release completes the focused Wave 4 Cobol frontier work and adds the first checked-in Wave 3 perf budge
Cobol frontier and perf-ratchet release. This release completes the focused Wave 4 Cobol frontier work and adds the first checked-in Wave 3 perf budget ratchet. It does not claim universal near-C performance; the ratchet and CI validator make future claims auditable.
cgo_harness/cmd/perf_scan_budget and the initial 20-language perf-ratio
budget seed, with a fast CI validation job wired into the aggregate build.ERROR regions so
recovered trees keep the C-oracle error carriers instead of timing out or
dropping them.Nothing published for this version
C++ recovery parity fold. This release fixes the focused C++ malformed-class recovery gap without enabling cpp C-recovery globally.
C++ recovery parity fold. This release fixes the focused C++ malformed-class recovery gap without enabling cpp C-recovery globally.
REPRO_GO_BACKEND=registry mode for C tree-dump
diagnostics.class bodies followed by void A::b() {} now normalize to the
C-oracle recovered function_definition shape.class_specifier, retagged namespace_identifier, and nested extra
ERROR(identifier) shapes.Cobol oracle cleanup and CI/dead-code maintenance release.
Cobol oracle cleanup and CI/dead-code maintenance release.
Nothing published for this version
Nothing published for this version
Roadmap checkpoint release after the v0.21 engine cut. This release lands the first four campaign buckets after v0.21.0: the runtime/recovery foundati
Roadmap checkpoint release after the v0.21 engine cut. This release lands the first four campaign buckets after v0.21.0: the runtime/recovery foundation, the external lex-state election ledger, broad precise ExternalLexStates coverage, and the Cobol large-table/recovery cleanup. It does not claim that all grammar tiers are parity-clean yet; the remaining tier-IV rows stay visible and classified for the next campaign waves. It also does not claim universal near-C parser performance across the registry yet; v0.22.0 publishes the perf-scan scaffold and targeted wins while the broader wave-3 ratchet remains tracked for the next release line.
cgo_harness/perf_scan: a nightly Go-vs-C scoring harness and CI proposal
for tracking full-parse and incremental parser performance without mixing
correctness and performance gates.cgo_harness/tier_scan/external_lex_elections.{md,json}), including the
default-elected, staged, missing-ELS, and no-scanner categories used by the
C-recovery rollout.uint16. The runtime now supports large state targets, and the
generator reports actionable boundary errors for unsupported table shapes.HasError state, so a clean recovered header no longer masks a separate
retained error in the same procedure_division subtree.Nothing published for this version
The engine release. The generalized GLR parser core — a C-faithful error recovery engine plus a GSS-forest fast path — replaces the v0.20.x per-langua
The engine release. The generalized GLR parser core — a C-faithful error recovery engine plus a GSS-forest fast path — replaces the v0.20.x per-language recovery approximations as the default runtime. Error recovery for 123 elected grammars now reproduces C tree-sitter's decisions (strategy-1 election order, per-stack-version error-mode lexing identity, error-cost model, and condense scheduling were each verified decision-for-decision against an instrumented tree-sitter v0.25.0 oracle). The campaign branch's full correctness backlog — 42 known failing tests at its peak — is zero in this release, and the root test suite dropped from ~340s to ~62s along the way.
_automatic_semicolon), replacing the grammar-level approximation. Fixes
the byte-strict ASI parity gap; spurious-HasError files on a large real
repo walk dropped 436 → 17.LexModes[0] at ERROR_STATE),
including an engine-side error-mode relex for custom token sources, with
the capability forwarded through included-range wrappers.module_repeat1 worklist blowup); the
EOF-recovery competition probe no longer declines ordinary clean input;
and Parser.SetTimeoutMicros is now enforced inside the forest path
(previously unenforceable for forest-dispatched languages)._whitespace extra tokens like C's
generated lexer instead of silently skipping horizontal whitespace, fixing
a 1-byte recovery-anchor divergence.f(a,b) = c[d] tuple assignments) no longer
corrupts the enclosing production or kills the stack; C's nested shape is
restored.-race suite now actually runs for non-draft PRs without
panicking Go's default per-package timeout (-timeout 35m -p 1, 60m job
budget); wall-clock boundedness contracts skip under -race
(instrumentation-slowdown measurement, not parser boundedness);
./grammargen runs as a non-blocking visibility step until its
enumerated pre-existing backlog (stale markdown blob, two Dart parity
gaps) is burned down.docs/authoring-languages.md — adding a language without forking:
grammar.json → grammargen → blob → Register/RegisterExtension/taproot,
the wantsForest opt-in, generator budgets, and blob provenance
discipline.docs/external-scanners.md — when a grammar needs an external scanner and
the Go porting contract (emit extras, C-EOF behavior, error-mode lexing,
token-source responsibilities), with Pawn's five externals as the worked
case study.grammars/clean_regression_pins_test.go).Patch release recovering C# large-namespace method/type declarations and the Swift ternary/conditional operator, both via post-parse source recovery p
Patch release recovering C# large-namespace method/type declarations and the
Swift ternary/conditional operator, both via post-parse source recovery
passes, plus a CI stability fix for the new C# recovery test under -race.
JsonTextReader.cs / JsonReader.cs) now recover their
method_declaration nodes instead of yielding only a comment-filled namespace
shell. Follow-up to #115/#116: the source-based type/method reconstruction was
gated off above 4096 bytes, so nothing rebuilt the members of a large collapsed
class. Namespace recovery now falls back, when the child-based pass surfaces no
method, to a per-member bounded source reconstruction — the type shell's
header is reparsed for its modifiers/name/base list, and each member is
recovered on its own (a method via signature-shell + lenient block, other
members by a single small wrapped reparse), skipping any that still won't parse.
Each reparse is a single small snippet capped by size and count and honors the
parser timeout, so the anti-OOM guarantees from #64/#98/#106 are preserved and
the whole-file 4096-byte gate is unchanged. JsonTextReader.cs now recovers 68
methods (was 0) and JsonReader.cs 41 (was 0). Thanks @richardwooding (#136, #138).cond ? a : b) now recovers instead of
dropping ? a : b into an ERROR node in every position. The runtime Swift
blob never fired the ternary_expression reduction, so any function containing
a ternary lost its whole parse (collapsing to
_modifierless_function_declaration_no_body). A post-parse recovery pass
reconstructs the ternary_expression — reparsing the source with each
? if_true : if_false tail blanked so the condition parses in place, then
splicing a synthesised node with the upstream condition/if_true/if_false
layout. The rewrite is accepted only when the result is error-free and
byte-faithful, so non-ternary code is never affected. Thanks @richardwooding
(#135, #137).TestCSharpLargeShreddedNamespaceRecoversMethods now skips under go test -race: the per-member bounded recovery reparses each class member as its
own small GLR parse, which normally finishes well inside the parser's
timeout budget, but race-detector instrumentation slows the same work enough
to trip the parser's internal wall-clock timeout. Non-race coverage keeps
the full recovery assertions; mirrors the existing Scala realworld-recovery
-race skip.Nothing published for this version
Adds consumer-controllable forest parsing.
Adds consumer-controllable forest parsing.
Language.WantsForest field (gob-serialized into blobs), the
grammargen.Grammar.WantsForest flag, and a declarative
"gotreesitter": { "wantsForest": true } object in grammar.json (read by
ImportGrammarJSON, mirrored back by ExportGrammarJSON only when set, so
standard grammars' output is unchanged). Built-in languages keep their curated,
byte-range parity-certified forest defaults; consumer opt-in is at the
consumer's responsibility, with the forest's decline→production fallback still
preventing hard failures on declined inputs. ExtendGrammar inherits the flag
from its base grammar (#134).Patch release for parser timeout propagation and targeted language recovery scanner fixes merged after v0.20.6.
Patch release for parser timeout propagation and targeted language recovery scanner fixes merged after v0.20.6.
then, and, with, else, elif, and end, preventing
scanner panics on malformed or edge-case indentation (#129, #130).if … else if … chains no longer collapse the enclosing function to
_modifierless_function_declaration_no_body (#131). The trailing-closure
ambiguity recovery now follows the whole if/else-if chain — the chained if
keyword is swallowed into an ERROR node, so it is discovered by scanning from
the body's matching close brace — and requires a byte-faithful reparse so a
partially-bracketed chain (which silently truncates without an ERROR node) is
rejected rather than accepted (#132).Patch release for parser recovery correctness, grammargen parity, and the forest/performance workstream merged after v0.20.5.
Patch release for parser recovery correctness, grammargen parity, and the forest/performance workstream merged after v0.20.5.
ErrParseStoppedEarly for timeout,
cancellation, token-source EOF, and parser safety-limit partial trees while
preserving the returned tree for diagnostics.NodeAtByte and NamedNodeAtByte helpers on Tree and Node for editor
offset lookup without hand-written tree walks.grammars.LoadLanguage(name, blob) attaches registered external scanners and
external lex-state tables when loading raw grammar blobs.Language.Size() reports approximate decoded table and lookup-cache bytes for
diagnostics and cache policy decisions.{a}b=c,
matching the C parser on minified bundle shapes (#111).ParserPool.Parse crash reported against command_test.go and
completions_test.go (#110).children, fieldIDs, and
fieldSources aligned when a cyclic edge is removed (#121).source_file root when
child nodes contain parse errors, matching the root-shape behavior already
used for SQL and Swift (#112).grammargen now treats explicit precedence wrappers around finite string
choices, such as prec.right(choice("=", "+=", "-=")), as reducible
nonterminals instead of overlapping named lexer tokens. This restores wrapper
nodes and lets LR precedence resolve the intended conflict (#122).for…in loop over a range (0..<n, 0...n)
or a call expression (stride(from:to:by:)) no longer silently collapse to
_modifierless_function_declaration_no_body with the loop body spilled out as
file-level siblings. As with the if/while case, the loop body brace was
being consumed as a trailing closure of the iterable; recovery now re-parses
the affected for…in headers with synthetic parentheses around the iterable
and maps the result back to byte-faithful original coordinates. Because this
misparse produced no ERROR node, the recovery pass now runs whenever the
detection walk finds a collapsed header rather than only on errored trees
(#123).TestGoCobraLargeFileParseRegression, gated by
GTS_COBRA_REGRESSION_ROOT, for exact large-file release validation without
making normal test runs network- or corpus-dependent.grammargen no longer imports the grammars registry. The grammar.js importer (ImportGrammarJS) previously pulled in grammars for the embedded JavaScrip
grammargen no longer imports the grammars registry. The grammar.js
importer (ImportGrammarJS) previously pulled in grammars for the embedded
JavaScript language, which transitively bundled all ~200 grammar blobs
(~22MB) into every consumer that merely defined a grammar via the DSL —
including taproot and all downstream DSLs. The JS language is now injected
via SetJSGrammarProvider; blank-import grammargen/grammarjs (or cmds
that need -js) to register it. Net effect: grammargen, taproot, and
anything that only defines/loads a grammar are now grammar-registry-free.taproot/walk: a grammar-free core of the taproot harness. It loads a tree-sitter Language from a pre-generated blob (LanguageFromBlob) and navigates t
taproot/walk: a grammar-free core of the taproot harness. It loads a
tree-sitter Language from a pre-generated blob (LanguageFromBlob) and
navigates the CST (Walker, ParseFromBlob, ParseWithLanguage) depending
only on the gotreesitter runtime — not grammargen or the grammars
registry. DSLs that embed a generated grammar blob can now parse/highlight
without linking the ~200-grammar registry (~22 MB). The grammargen-backed
build-from-DSL fallbacks remain in taproot, which re-exports walk.Walker
so existing taproot.Walker/Parse callers are unaffected.C# files whose namespace body does not parse cleanly no longer collapse into a single top-level ERROR node with zero recoverable declarations. Namespa
ERROR node with zero recoverable declarations. Namespace
recovery now falls back to a best-effort namespace_declaration built from
the existing sub-parse, surfacing the type declarations (and the members that
parsed) instead of discarding the whole file. C# brace matching used during
recovery is now trivia-aware, so braces inside char literals, strings and
comments no longer truncate a recovered declaration's span (#115).if/while condition contains a comparison operator
(< / > / ==, etc.) no longer collapse into an ERROR tree with no
recoverable function_declaration. The body brace was being consumed as a
trailing closure of the condition's last operand; recovery now re-parses the
affected conditions with synthetic parentheses to remove the ambiguity and
maps the result back to byte-faithful original coordinates (#118).normalizeGoDotLeafChildren now walks dotted-selector chains with an
iterative DFS instead of recursion, removing a stack-depth risk on very long
selector chains.TestJavaScriptBlockThenAssignmentParsesClean, for the JavaScript
block-then-simple-assignment GLR collapse ({a}b=c, #111). The root cause is
the JSX-attribute-continuation ASI heuristic in the JS scanner; the fix is
still pending (targeted for the C-oracle-verified parity line). Remove the
t.Skip to validate once fixed.Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Patch release for the post-0.20 parser reliability and code-understanding surface fixes. This tagged release references the issue fixes merged after v
Patch release for the post-0.20 parser reliability and code-understanding surface fixes. This tagged release references the issue fixes merged after v0.20.1.
import Foundation followed by declarations, covering the real-world Swift
misparse report while avoiding recursive recovery (#99, #107).int or
error as definition.function tags (#100, #109).case _:/block-start normalization now match the C tree-sitter shapes used
by the parity harness (#101, #102, #103, #108).Taproot blob-loading helpers and stable parser harness coverage for the extracted Taproot DSL surface.
Taproot stable release.
GLR parser-core release after the 0.20 release-candidate line.
GLR parser-core release after the 0.20 release-candidate line.
markdown_inline.Extracted Taproot as a reusable DSL parsing harness with diagnostics.
Fourth 0.20 release candidate.
Third release candidate on the 0.20 line. Parser-core GLR performance wins — C now parses at/below parity with tree-sitter C on real corpus — plus par
Third release candidate on the 0.20 line. Parser-core GLR performance wins — C now parses at/below parity with tree-sitter C on real corpus — plus parser correctness fixes and markdown grammargen advances. CI green (build, parity-cgo, perf-regression).
RepetitionShiftConflictChoice resolver to collapse spurious reduce/shift
forks at boundaries where tree-sitter C resolves deterministically (verified
per state against C's parser.c; the reduce is a zero-progress dead-end with
no conflicts: entanglement). Every change is byte-for-byte C-parity-verified
against libtree-sitter.
translation_unit_repeat1 (top-level item list) + preproc_if_repeat1
(preprocessor body) collapse — large__cluster.c drops from 20,866 to
1,099 GLR forks (−95%) and ~−30% parse wall, bringing C to/below parity.delim_token_tree_repeat1) continuation-token
fork reduction.external_lex_state indexing (single active state references the
precomputed row instead of rebuilding it per token).html_block type 6/7 at a blank line.link_reference_definition soft-break terminator.Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Kotlin source-file query compatibility patch.
Kotlin source-file query compatibility patch.
source_file roots instead of ERROR roots, while
preserving child error state for diagnostics.fun declarations recovered under an error root
now expose function_declaration shape with the fun keyword, name, and
parameter list, while retaining error state. This preserves downstream
Aspect/Gazelle Orion queries without AXL rewrites on files with recoverable
syntax errors.GLR materialization, query parity, and parser hot-path release.
GLR materialization, query parity, and parser hot-path release.
source_file -> import_list -> import_header patterns
without requiring query rewrites.#lua-match? predicate parity and query predicate stack storage now match
expected tree-sitter semantics more closely.legacy_generated_register_stubs build tag; the generated registry
is now the single checked-in grammar registration surface.cmd/grammargen via
-lr-split, reducing the public command set while keeping the regeneration
path available.grammarlsp side package and its LSP/SegmentIO
dependencies from the root module.~1.54 ms, incremental single-byte edit ~649 ns, no-edit
incremental reparse ~2.43 ns. Full parse now reports 728 B/op and
7 allocs/op on this workload.GOMAXPROCS=1 go test . -run '^$' -bench 'BenchmarkGoParseFullDFA|BenchmarkGoParseIncrementalSingleByteEditDFA|BenchmarkGoParseIncrementalNoEditDFA' -benchmem -count=10 -benchtime=750ms.Nothing published for this version
Cold dependency extraction and parser materialization diagnostics release.
Cold dependency extraction and parser materialization diagnostics release.
ExtractImports, ExtractImportsFromSource, and
ExtractImportsFromSourceWithReport. The source extractor reports status,
reason, and fallback recommendation so callers can use a fast source scan and
fall back to a full tree parse only when needed.cgo_harness/cmd/import_replay, a Bazel/Gazelle-shaped replay command that
scans repositories and compares cgo tree extraction, Go tree extraction, and
hybrid source extraction with normalized dependency-output diffs and timing
JSON.__future__ imports,
multiline imports, relative imports, and triple-quoted strings consistently
across source and tree extractors..canopy/ is ignored and stale tracked scratch programs were removed.**
instead of letting shared shorter literals split them during generated-parser
lexing.rules_python replay with 564 Python files and 949 imports, hybrid
source extraction matched cgo tree extraction and Go tree extraction exactly:
cgo parse+extract was about 158 ms, Go tree extraction about 1.17 s, and
source extraction about 3.9 ms.rules_jvm replay with 231 Java files and 1028 imports, hybrid source
extraction matched cgo and Go tree extraction exactly: cgo parse+extract was
about 70 ms, Go tree extraction about 276 ms, and source extraction about
1 ms.aspect-gazelle Go replay with 148 files and 916 refs, hybrid source
extraction matched cgo tree extraction exactly in about 0.7 ms; Go full-tree
extraction missed 8 refs because three full-tree parses were incomplete.4 GB memory and 1 CPU with
oom_killed=false.Python parser compatibility patch for downstream Gazelle consumers.
Python parser compatibility patch for downstream Gazelle consumers.
_ identifiers no longer get retokenized as EOF during contextual
literal repair. This prevents clean prefix parses from silently truncating
modules before later assignments or nested imports.Module compatibility patch for downstream Gazelle consumers.
Module compatibility patch for downstream Gazelle consumers.
go directive from 1.25.0 to 1.22.0 and pin
golang.org/x/sync to v0.11.0, avoiding accidental Go 1.25 upgrades for
downstream consumers that import gotreesitter only as a parser runtime.Query predicate compatibility patch for downstream Gazelle consumers.
Query predicate compatibility patch for downstream Gazelle consumers.
#has-parent? with immediate
parent semantics, matching the existing #not-has-parent? support.Kotlin parser compatibility patch for downstream Gazelle consumers.
Kotlin parser compatibility patch for downstream Gazelle consumers.
fun interface declarations..
or import.Nothing published for this version
Java corpus parity and parser-performance release.
Java corpus parity and parser-performance release.
Parser.ParseNoTreeBenchmarkOnly for diagnostic parser-loop benchmarks that
suppress full public tree materialization while keeping lexing and parse
actions active.grammargen parity coverage checks and focused fixtures for Java,
Bash, Python, Swift, comment, CPON, git config, gomod, ini, and related
imported-grammar edge cases.grammargen normalization and conflict-resolution gaps for lexical choices,
aliased inline precedence, long Unicode escapes, augmented start symbols,
terminal collisions, Python/Swift parity regressions, Julia assignment
conflicts, D binary repeat, PowerShell binary repeat, and gomod grouped
retract intervals.~1.98 ms, incremental single-byte edit ~666 ns, no-edit
incremental reparse ~2.84 ns, with full parse at 5 allocs/op.~537 ms, Go
no-tree diagnostic ~402 ms, cgo full ~394 ms; full/cgo is about 1.36x.~306 ms, Go no-tree
diagnostic ~235 ms, cgo full ~213 ms; full/cgo is about 1.44x.Nothing published for this version
Nothing published for this version
Grammar extensibility, UTF-16 input, and parser-resilience release.
Grammar extensibility, UTF-16 input, and parser-resilience release.
grammargen DSL sources and extension smoke coverage for Kotlin and Swift.grammargen constructors for JavaScript, TypeScript, TSX, and Fortran, plus
imported grammar coverage and TypeScript inline-rule filtering documentation.DEDENT behavior for
issue #53. Includes Fraser Isbester's fork commit and a follow-up regression
hardening pass.grammargen parity gaps were closed.ExtendGrammar smoke tests.grammargen constructors.Nothing published for this version
Nothing published for this version
Parser stability and harness release.
Parser stability and harness release.
#embed directive lines and
__has_embed(...) conditional feature-test forms (including parameter
variants) without parse errors.cgo_harness/docker/. The wrapper mounts
the host Canopy binary into the Docker harness, applies memory/CPU/PID caps,
uses a host-side timeout watchdog, and scopes analysis to one package with
generated blobs/worktrees excluded by default.ts2go batch execution is parallelized, reducing generated-grammar
conversion wall time on multi-core machines.AdaptExternalScannerByExternalOrder can match shared symbols by
name, leave unpaired target symbols disabled, and size the source-valid bitmap
to the source scanner rather than assuming equal external lists.testdata directories and
updated the harness docs and scripts to use the new paths.parser_result_test, and larger parser-result Python source
fixtures now live under testdata/parser_result.Nothing published for this version
Nothing published for this version
Nothing published for this version
Reconciliation release. The release/v0.15.x line and main had drifted apart; v0.15.2 unifies them so subsequent work has a single forward branch to bu
Reconciliation release. The release/v0.15.x line and main had drifted apart; v0.15.2 unifies them so subsequent work has a single forward branch to build on.
grammargen/swift_abi_grammar.go, SwiftABIManglingGrammar()). Parses the $s / $S / $e / _T0 Swift symbol-mangling prefixes. Intended for tooling that needs to walk demangled Swift symbols without invoking the Swift toolchain.cmd/grammar_updater -verify-pins flag. Validates that every locked commit in grammars/languages.manifest is still fetchable from its declared remote before any sync runs. verifyRemotePins / verifyRemoteCommit deduplicate by repo+commit to keep the check cheap on large manifests.cmd/grammar_updater -sync-manifest-only flag. Limits a sync pass to manifest entries that are new since the last run. syncMissingEntriesFromManifest now returns a map so callers can apply an allow-list filter..claude/, docs/blog-outlines/, docs/plans/, docs/superpowers/) along with the benchgate binary. Plan docs are working references and should not ship with the repo.docs/plans/ and docs/superpowers/ prior to the gitignore update.Nothing published for this version
Nothing published for this version
Query matching now backtracks when structurally valid child candidates fail predicates, fixing Starlark nested-dictionary predicate cases.
ParsePolicy.ShouldSkipDir lets gateway consumers prune a directory before descending into it. This is intended for large generated/vendor trees where
ParsePolicy.ShouldSkipDir lets gateway consumers prune a directory before descending into it. This is intended for large generated/vendor trees where even file discovery and language detection can create avoidable memory pressure.parser_result_*.go files instead of centralizing every per-language call chain in parser_result.go.ImportGrammarJSON now drops reserved-word sets when the imported grammar does not expose a RESERVED wrapper, avoiding stale reserved metadata on grammars that should not carry it.string_close external-token handling for the refreshed lock pin.Tree.Edit stops scanning already-sorted right-side siblings when an edit has no tail shift to apply.Nothing published for this version
Nothing published for this version
Go grammar now ships as a grammargen-compiled blob (PR #35). Our pure-Go LALR(1) + LR(1) state-splitting compiler produces a different state layout th
} had no action after certain nested switch/case/if patterns. gotreesitter's own parser_reduce.go, parser.go, and parser_test.go now parse cleanly (HasError=false); the old blob wrapped them in ERROR. Adds cmd/emit_grammargen_go_blob for one-shot regeneration as grammargen evolves.GoTokenSource no longer registered by default (PR #35). The grammargen blob ships DFA tables that parse Go on their own; GoTokenSource remains available via the public API for callers carrying their own ts2go Go blob.maxxnino/tree-sitter-zig (inactive since 2024-10) to tree-sitter-grammars/tree-sitter-zig (active upstream, PR #32, addresses #31). Wholesale PascalCase → snake_case node-name rename; 28 % smaller blob (62 948 → 45 316 bytes). Three upstream #lua-match? highlight predicates rewritten as #match? for portability. Review-follow-up commit addresses four gemini-flagged issues: anchored type regex, ... moved to @operator, broken . anchors on field_expression patterns removed, duplicated &/-% operators deduped.sourceLen × 4 → sourceLen / 4 (PR #33). The old formula over-allocated 10-16× for Go (~1 node per 5-10 input bytes); the adaptive hint handles subsequent parses.dfaTokenSource while the outer parse still held one, causing a use-after-return when the outer parse finished first. Adds newDFATokenSourceDirect with noPool: true so recovery nests safely inside an active parse, and extracts an initDFATokenSource helper.DrainArenaPools() + releaseNodeRefs on reuseCursor/reuseScratch (PR #25 by @vdergachev). Arenas held in the pool are strong Go references and are not collected by the GC until explicitly drained; call after a large batch scan to allow reclamation.BenchmarkSelfParse and BenchmarkSelfParseWarmReuse — regression-guard benchmarks that parse gotreesitter's own pathological root files. Intended to catch memory-footprint regressions on dense real-world Go source.recomputeByteOffset, stackEntriesEqual*, gssStackEntriesEqual*, stackEntryNodesEquivalent*Frontier.Stacked effect across PR #25 + #33 + #34 + #35 + #36 on BenchmarkSelfParseWarmReuse (six gotreesitter root files, 5-iter warm bench, Docker 4 g / 4 cpus):
| mode | pre-0.14.0 | 0.14.0 | delta |
|---|---|---|---|
| cold (fresh Parser per iter) | 574 MB/op | 225 MB/op | -60.8 % |
| warm (one Parser reused) | 498 MB/op | 229 MB/op | -54.0 % |
| warm + GC drain between rounds | 522 MB/op | 252 MB/op | -51.7 % |
Warm-reuse throughput ~10 % higher. 206-grammar parity green under GTS_PARITY_MODE=exhaustive.
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →