Commit graph

2854 commits

Author SHA1 Message Date
Patrick Thomson
39bfcdf595 Fix build with MinGW tooling. (#514)
Courtesy of @Eli-Zaretskii, these fixes should unblock people from
building tree-sitter with MinGW.

I don't think this is an unreasonable maintenance burden, especially
given the Emacs project's interest in using tree-sitter, but
@maxbrunsfeld gets the final call.
2020-01-06 09:21:40 -08:00
Max Brunsfeld
9a73277389 web-ui: Load static files from disk if TREE_SITTER_BASE_DIR var is set 2019-12-19 11:23:14 -08:00
Max Brunsfeld
f53e7377dc Allow highlight to command to take glob patterns 2019-12-17 15:49:05 -08:00
Max Brunsfeld
6c5adb7072 0.16.2 2019-12-17 15:06:21 -08:00
Max Brunsfeld
f0e4d630d5 Reliably avoid duplicate subtypes in node-types.json 2019-12-17 14:55:51 -08:00
Max Brunsfeld
3ac047679c Fix children.required when multiple nodes are aliased as the same 2019-12-16 12:39:57 -08:00
Max Brunsfeld
7c711c5537 Move the private functions in node_types.rs to the end of the file 2019-12-16 12:38:40 -08:00
Max Brunsfeld
5edf97bca9 Remove accidentally-commited garbage line in arg parsing config 2019-12-16 11:59:26 -08:00
Maxim Sukharev
edb5693100 include language.h in query.c (#507)
Building `query.c` requires `TREE_SITTER_LANGUAGE_VERSION_WITH_SYMBOL_DEDUPING` which is defined in `language.h`.

It produces an error:
```
query.c:744:40: error: use of undeclared identifier 'TREE_SITTER_LANGUAGE_VERSION_WITH_SYMBOL_DEDUPING'
```

when building with cgo.
2019-12-16 09:38:18 -08:00
Max Brunsfeld
9a0cfa2376 Fix 'required' field when rules with diff fields are aliased to look the same 2019-12-12 11:26:58 -08:00
Max Brunsfeld
fc19312913 Fix node-types bugs involving aliases and external tokens 2019-12-12 10:06:18 -08:00
Max Brunsfeld
1b5ae380ce
Don't attempt to extract keywords that don't entirely match word token (#505) 2019-12-11 17:18:15 -08:00
Max Brunsfeld
e313f981a2 wasm: 0.16.0 2019-12-10 16:26:20 -08:00
Max Brunsfeld
80a4304956 lib: 0.6.0 2019-12-10 16:24:39 -08:00
Max Brunsfeld
d25b71182e Update bash unit test to reflect field additions 2019-12-10 14:12:45 -08:00
Max Brunsfeld
c2e253a4c8 Update unit test to reflect javascript query change 2019-12-10 13:24:36 -08:00
Max Brunsfeld
9f77afcd1f 0.16.1 2019-12-09 13:26:26 -08:00
Max Brunsfeld
a5a9000e29 generate: Ensure that field_map_slices array is long enough 2019-12-09 11:46:32 -08:00
Steven Kalt
09fb24c03d add encoding to web_ui.html (#504)
addressing #503 .
2019-12-06 19:28:08 -08:00
Max Brunsfeld
0cb2ef1082 Fix code paths that still conflated null characters with EOF 2019-12-06 15:29:03 -08:00
Han BAO
47a926067d Update README.md (#502)
configure the recognized names for highlighting
2019-12-06 14:00:27 -08:00
Han BAO
acc5f092c8 FIxing the README in highlight (#501)
* Correct README.md in /highlight

correct the lifetime in highlighter.highlight and correct the cases in match so that the demo in README could work.

* Update README.md

another small fix

* Update highlight/README.md

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@github.com>
2019-12-06 13:05:28 -08:00
Max Brunsfeld
2758103646 0.16.0 2019-12-06 12:48:11 -08:00
Max Brunsfeld
d426f46087 Add unit test for symbols respecting simple aliases 2019-12-06 12:47:27 -08:00
Max Brunsfeld
6d1d8cc217 query: Skip workaround code path when using new symbol map field 2019-12-06 12:11:45 -08:00
Max Brunsfeld
7032dae4f6 Include alias symbols in unique symbol map 2019-12-06 12:11:09 -08:00
Max Brunsfeld
bea6e0e28b cli: Generate parseres with the new ABI by default 2019-12-06 11:51:55 -08:00
Max Brunsfeld
bd49fbab12 cli: Allow globs and exclusions (via '!' prefix) as args to parse 2019-12-06 11:41:21 -08:00
Max Brunsfeld
1c8aed790d
Merge pull request #500 from tree-sitter/dedup-symbols
Store a mapping to ensure no two symbols map to the same metadata
2019-12-06 09:51:28 -08:00
Max Brunsfeld
56c620c005 Store a mapping to ensure no two symbols map to the same metadata 2019-12-05 17:21:46 -08:00
Max Brunsfeld
d6c7b243a7
Merge pull request #499 from tree-sitter/highlight-test
Add a system for testing syntax highlighting queries
2019-12-05 15:55:24 -08:00
Max Brunsfeld
4b9feccd13 Run syntax highlighting tests as part of the main test command
Also, allow `corpus` to be in the `test/corpus` directory, and expect 
highlighting tests to be in the `test/highlight` directory.
2019-12-05 15:28:16 -08:00
Max Brunsfeld
6dbfbaed07 Start work on a system for testing syntax highlighting 2019-12-05 09:45:54 -08:00
Max Brunsfeld
82a8b15714 docs: Add C# parser to the playground 2019-12-02 14:00:26 -08:00
Max Brunsfeld
7ee65222d3 docs: Consider C# to be fairly complete 2019-12-02 13:54:24 -08:00
Max Brunsfeld
388511dbc9
Merge pull request #496 from kramred/patch-1
Fix small typo in docs
2019-12-02 09:06:45 -08:00
Mark Schmitz
3fbe0be6e2
Fix small typo in docs 2019-12-02 13:05:41 +00:00
Max Brunsfeld
f2118ac7f0
Merge pull request #494 from smacker/patch-1
add missing unicode include to query.c
2019-12-01 13:21:50 -08:00
Max Brunsfeld
4ef8e54d96
Merge pull request #495 from akiyosi/master
Fix link to contributing docs
2019-12-01 13:21:15 -08:00
akiyosi
1742f32fcc Fix link to contributing docs 2019-11-28 22:07:32 +09:00
Maxim Sukharev
a647de1ef5
add missing unicode include to query.c
it causes problems with building tree-sitter with cgo
2019-11-28 01:32:41 +01:00
Max Brunsfeld
284489a83b Fix home directory name in travis config file 2019-11-22 13:05:46 -08:00
Max Brunsfeld
a23e8b3dcb
Merge pull request #492 from tree-sitter/query-fixes
Fix handling of tricky patterns in tree queries
2019-11-22 13:05:20 -08:00
Max Brunsfeld
c957a5b8e7 Add test for handling of too many states in query captures 2019-11-22 11:54:32 -08:00
Max Brunsfeld
e3f6b1a1af Query - If too many states, kill the one w/ the earliest capture 2019-11-22 11:54:12 -08:00
Max Brunsfeld
71998ef3c1 web: 0.15.11 2019-11-20 11:12:50 -08:00
Max Brunsfeld
9ea3668f75 wasm: Fix logic for finding language functions 2019-11-20 11:10:49 -08:00
Max Brunsfeld
70309ad846 0.15.14 2019-11-20 10:56:25 -08:00
Max Brunsfeld
87c2021e6e
Merge pull request #490 from tree-sitter/fix-compiler-warnings
Fix a few compiler warnings
2019-11-20 10:48:32 -08:00
Damien Guard
599e4f0ec4
Fix a few compiler warnings 2019-11-20 10:21:10 -08:00