Commit graph

6118 commits

Author SHA1 Message Date
Boris Verkhovskiy
c070c92722 refactor(wasm)!: make current*, is*, and has* methods properties 2024-03-08 00:27:06 -05:00
Amaan Qureshi
4b578a3649 fix(generate): camel case name in Cargo.toml description 2024-03-06 19:53:51 -05:00
ObserverOfTime
2d652c90a7 fix(cli): only output the sources with --no-bindings 2024-03-06 13:56:40 -05:00
dependabot[bot]
7171ecd4ad build(deps): bump the cargo group with 4 updates
Bumps the cargo group with 4 updates: [cc](https://github.com/rust-lang/cc-rs), [indexmap](https://github.com/indexmap-rs/indexmap), [libloading](https://github.com/nagisa/rust_libloading) and [walkdir](https://github.com/BurntSushi/walkdir).


Updates `cc` from 1.0.88 to 1.0.89
- [Release notes](https://github.com/rust-lang/cc-rs/releases)
- [Commits](https://github.com/rust-lang/cc-rs/compare/1.0.88...1.0.89)

Updates `indexmap` from 2.2.4 to 2.2.5
- [Changelog](https://github.com/indexmap-rs/indexmap/blob/master/RELEASES.md)
- [Commits](https://github.com/indexmap-rs/indexmap/compare/2.2.4...2.2.5)

Updates `libloading` from 0.8.1 to 0.8.2
- [Commits](https://github.com/nagisa/rust_libloading/compare/0.8.1...0.8.2)

Updates `walkdir` from 2.4.0 to 2.5.0
- [Commits](https://github.com/BurntSushi/walkdir/compare/2.4.0...2.5.0)

---
updated-dependencies:
- dependency-name: cc
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo
- dependency-name: indexmap
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo
- dependency-name: libloading
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo
- dependency-name: walkdir
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: cargo
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-06 01:27:41 -05:00
Amaan Qureshi
92675117a6 fix(generate): extern allocator functions for the template don't need to be "exported" 2024-03-05 11:19:06 -05:00
Amaan Qureshi
54a31069af fix: parsers should export the language function on windows 2024-03-05 11:19:06 -05:00
Amaan Qureshi
304f8b7c04 fix: don't use __declspec(dllexport) on windows 2024-03-04 13:23:06 -05:00
Amaan Qureshi
f8c41f74f8 fix(bindings): insert types after main if it exists 2024-03-03 11:17:30 -05:00
Amaan Qureshi
57d01335c0 chore: delete binding_files.rs 2024-03-03 10:46:37 -05:00
Amaan Qureshi
27f52266ac feat: replace nan with node-addon-api and conditionally print logs 2024-03-03 10:46:37 -05:00
Segev Finer
30bb44f48a feat: add typings for the node bindings
Fixes #3072
2024-03-03 10:46:37 -05:00
geekvest
b43e8ce902
docs: remove duplicate the's
Signed-off-by: geekvest <cuimoman@sohu.com>
2024-03-03 10:30:21 -05:00
Segev Finer
1dd35fe0e0
feat(node): type tag the language
Co-authored-by: ObserverOfTime <chronobserver@disroot.org>
2024-03-02 20:59:20 -05:00
ObserverOfTime
924c2b4425 chore(bindings): ignore more artifacts 2024-03-02 20:13:39 -05:00
ObserverOfTime
f7c6dcadaa feat(bindings): add more make targets 2024-03-02 20:13:39 -05:00
Max Brunsfeld
6756eb5c48
Merge pull request #3114 from novusnota-forks/ohm-language
docs: Add `Ohm` language parser
2024-03-01 08:16:44 -08:00
Amaan Qureshi
c66ed6a141
fix: and binding.gyp... 2024-03-01 11:02:33 -05:00
Amaan Qureshi
274d0cda0a fix: binding.cc overwrite should replace PARSER_NAME 2024-03-01 10:59:25 -05:00
Novus Nota
43358f0c59
docs: Add Ohm language parser 2024-02-29 19:13:53 +01:00
Max Brunsfeld
36397810e6
Merge pull request #3111 from daumantas-kavolis-sensmetry/patch-1
Fix regression in `subtree_compare`
2024-02-29 07:51:34 -08:00
dundargoc
6ef5236ea6 ci(dependabot): update weekly instead of daily
Daily updates turned out to be too frequent.
2024-02-29 14:27:08 +01:00
Daumantas Kavolis
ce5afeb4b3
Fix regression in subtree_compare 2024-02-29 10:15:58 +02:00
Amaan Qureshi
6b2879144f build(deps): bump deps & lockfile 2024-02-29 02:17:30 -05:00
Amaan Qureshi
5a4765ca01 style: clippy lints 2024-02-29 02:17:30 -05:00
Amaan Qureshi
3eb7366500 docs: document test attributes 2024-02-29 02:17:30 -05:00
Amaan Qureshi
60a935139b refactor!: remove top-level corpus dir for tests
It's confusing to have tests in two different top-level directories when working between different grammars, and most of them use `test/corpus` which is more fitting, so time to go.
2024-02-29 02:17:30 -05:00
Amaan Qureshi
4ff33e81bb fix(assertions): case shouldn't matter for comment node detection 2024-02-29 02:17:30 -05:00
Amaan Qureshi
8c4861c186 feat(test): add attributes for corpus tests 2024-02-29 02:17:30 -05:00
ObserverOfTime
b3c14c9295 build(bindings): make everything c11 2024-02-29 01:50:04 -05:00
ObserverOfTime
22c85c6139 refactor(array): use pragma GCC in clang too 2024-02-29 01:50:04 -05:00
ObserverOfTime
b4b2d9cecc refactor: remove extern/const where possible 2024-02-29 01:50:04 -05:00
Christian Clason
59838de33a ci: don't skip tests on failing lint
Problem: A failing lint will block running actual tests, adding friction to contributors who will have to golf the linter before getting to see actually useful test results.

Solution: Don't gate `sanitize` and `build` behind successful `checks` so you can see whether your code works at all _before_ worrying about its quality. (In general, the more feedback you get at the same time, the fewer edit->push->test cycles you need, _saving_ CI time in the long run. Only skip tests you are sure to be useless given previous failures.)
2024-02-28 16:31:21 +01:00
Amaan Qureshi
d92a7a9690 test: add test case for parse stack merging with incorrect error cost bug 2024-02-28 08:51:28 -05:00
JmPotato
aeefb99871
build(swift): move 'cLanguageStandard' behind 'targets'
Signed-off-by: JmPotato <ghzpotato@gmail.com>
2024-02-28 05:49:12 -05:00
Segev Finer
e87cf7ef15
refactor(bindings)!: convert node bindings to NAPI
Co-authored-by: Boris Verkhovskiy <boris.verk@gmail.com>
Co-authored-by: Amaan Qureshi <amaanq12@gmail.com>
Co-authored-by: ObserverOfTime <chronobserver@disroot.org>
2024-02-27 17:06:25 -05:00
dependabot[bot]
3d65ffa5af build(deps): bump the cargo group with 1 update
Bumps the cargo group with 1 update: [tempfile](https://github.com/Stebalien/tempfile).


Updates `tempfile` from 3.10.0 to 3.10.1
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Stebalien/tempfile/compare/v3.10.0...v3.10.1)

---
updated-dependencies:
- dependency-name: tempfile
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-27 16:50:58 -05:00
Amaan Qureshi
eb332ffa4d style(bindings): consistent wording 2024-02-27 16:07:38 -05:00
ObserverOfTime
502dacf220 refactor: rename TS_REUSE_ALLOCATOR flag
TREE_SITTER_REUSE_ALLOCATOR is more consistent
2024-02-27 15:54:38 -05:00
ObserverOfTime
46520eda58 build(bindings): metadata improvements 2024-02-27 15:54:38 -05:00
Amaan Qureshi
f7c13406c9 build: add uninstall command 2024-02-27 15:54:38 -05:00
ObserverOfTime
799833f9cf build: use c11 everywhere
And improve the makefiles
2024-02-27 15:54:38 -05:00
Amaan Qureshi
e75a36232b fix(lib): include api.h so ts_set_allocator is visible 2024-02-27 09:21:17 -05:00
ObserverOfTime
412a6a774e refactor(bindings): remove npmignore
Replace with package.json files
2024-02-27 06:22:00 -05:00
Max Brunsfeld
c03c773a24
Merge pull request #3086 from tree-sitter/randomized-test-crash-stack-merge
Fix invalid parse stack recursive merging with mismatched error cost
2024-02-26 17:38:02 -08:00
Max Brunsfeld
9b485924d6 Fix invalid parse stack recursive merging with mismatched error cost
Allowing this invalid merge caused an invariant to be violated
later on during parsing, when handling a later error.

Co-authored-by: Amaan Qureshi <amaanq12@gmail.com>
Co-authored-by: Marshall <marshall@zed.dev>
2024-02-26 20:16:21 -05:00
Amaan Qureshi
eb35502f06 test: don't use TS_REUSE_ALLOCATOR on Darwin systems
For some reason, the linker seems to behave a bit differently with `-exported_symbols_list` on macOS vs other operating systems, so we'll disable this for now
2024-02-26 20:15:36 -05:00
Max Brunsfeld
527848d7c0
Merge pull request #3084 from tree-sitter/no-vendored-wasmtime-headers
Remove vendored wasmtime headers
2024-02-26 15:36:10 -08:00
Max Brunsfeld
dfc6d93bae Rename wasm C sources to avoid conflicts with standard wasm headers
Co-authored-by: Marshall <marshall@zed.dev>
2024-02-26 13:08:30 -08:00
Amaan Qureshi
8ae3870b51 fix(generate): add .npmignore, populate Swift's exclude list 2024-02-26 14:30:48 -05:00
Amaan Qureshi
a31f084b1b fix: ignore unused variables in the array macros 2024-02-26 14:05:16 -05:00