Bump Tree-sitter for bug fixes affecting YAML parser loaded via WASM (#25054)

Closes https://github.com/zed-industries/zed/issues/24742
Closes #24632

This PR bumps Tree-sitter to bring in bug fixes:
* https://github.com/tree-sitter/tree-sitter/pull/4218
* https://github.com/tree-sitter/tree-sitter/pull/4213
* https://github.com/tree-sitter/tree-sitter/pull/4210

I've also bumped Wasmtime and wit-bindgen, since the new Tree-sitter
uses a newer wasmtime.

Release Notes:

- Fixed a parsing bug that caused memory leaks and crashes when using
the Ansible extension

---------

Co-authored-by: Anthony <anthony@zed.dev>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
This commit is contained in:
Max Brunsfeld 2025-02-17 21:29:27 -08:00 committed by GitHub
parent 8942e657aa
commit 813d870a03
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 225 additions and 211 deletions

View file

@ -1238,12 +1238,13 @@ fn parse_text(
parser.set_included_ranges(&ranges)?;
parser.set_language(&grammar.ts_language)?;
parser
.parse_with(
.parse_with_options(
&mut move |offset, _| {
chunks.seek(start_byte + offset);
chunks.next().unwrap_or("").as_bytes()
},
old_tree.as_ref(),
None,
)
.ok_or_else(|| anyhow::anyhow!("failed to parse"))
})