Max Brunsfeld
83514293b5
Allow external tokens to be either visible or hidden
2016-12-05 17:26:11 -08:00
Max Brunsfeld
6073d9c0e8
Restore all languages in corpus specs
2016-12-05 16:36:50 -08:00
Max Brunsfeld
49d25bd0f8
Remove EXTERNAL_TOKEN grammar rule type
2016-12-04 15:02:32 -08:00
Max Brunsfeld
d72b49316b
Handle external tokens in apply_transitive_closure
2016-12-04 10:40:32 -08:00
Max Brunsfeld
0f8e130687
Call external scanner functions when lexing
2016-12-02 22:03:48 -08:00
Max Brunsfeld
c966af0412
Start work on external tokens
2016-12-02 16:24:19 -08:00
Max Brunsfeld
be9e79db1b
Avoid incorrect application of precedence
2016-12-01 10:24:06 -08:00
Max Brunsfeld
996ca91e70
Disallow syntax rules that match the empty string (for now)
2016-11-30 23:19:54 -08:00
Max Brunsfeld
cab1bd3ac5
Make conflict messages explicit about precedence combinations
2016-11-18 17:05:16 -08:00
Max Brunsfeld
42ba70a5a0
🎨
2016-11-18 16:16:51 -08:00
Max Brunsfeld
60593d13f4
Use a newer gcc on travis
2016-11-18 14:41:02 -08:00
Max Brunsfeld
32387400c6
Rework LR conflict resolution
...
* Unify precedence/associativity-based resolution with the
search for a whitelisted conflict
* Improve conflict error messages
2016-11-18 13:50:55 -08:00
Max Brunsfeld
535879a2bd
Represent byte, char and tree counts as 32 bit numbers
...
The parser spends the majority of its time allocating and freeing trees and stack nodes.
Also, the memory footprint of the AST is a significant concern when using tree-sitter
with large files. This library is already unlikely to work very well with source files
larger than 4GB, so representing rows, columns, byte lengths and child indices as
unsigned 32 bit integers seems like the right choice.
2016-11-14 12:19:13 -08:00
Max Brunsfeld
1412419434
Verify changed ranges for random deletions as well as random insertions
2016-10-16 14:55:51 -07:00
Max Brunsfeld
b3140b2689
Implement ts_document_parse_and_get_changed_ranges
2016-10-15 22:31:21 -07:00
Max Brunsfeld
3014101104
Fix inconsistencies in nodes sizes after edits
2016-09-19 13:35:08 -07:00
Max Brunsfeld
744eb7b356
Assert consistency of trees' sizes in bytes
2016-09-19 12:40:45 -07:00
Max Brunsfeld
591fcc980c
Update trees' offsets when editing them
2016-09-08 17:54:51 -07:00
Max Brunsfeld
70756034f1
Allow descendant queries by both 1D and 2D coordinates
2016-09-06 21:17:26 -07:00
Max Brunsfeld
096ac2d4b6
Rename ts_document_set_debugger -> ts_document_set_logger
2016-09-06 17:40:26 -07:00
Max Brunsfeld
64a6c9db0e
Rename ts_document_make -> ts_document_new
2016-09-06 17:26:18 -07:00
Max Brunsfeld
b6e2bed761
Fix specs after js grammar change
2016-09-01 17:45:35 -07:00
Max Brunsfeld
e947d7e2ad
Adjust test assertions for subtly different recoveries
2016-08-29 11:23:52 -07:00
Max Brunsfeld
285f2272fd
Move random string helpers into a separate file
2016-07-17 06:22:05 -07:00
Max Brunsfeld
6fd3edceae
Fix logic for inserting leading & trailing extras into root node on acceptance
2016-06-26 11:57:42 -07:00
Max Brunsfeld
f425fbad18
Break down reused node on stack whenever lookahead can't be reused
2016-06-22 22:03:27 -07:00
Max Brunsfeld
00a0939504
Abort erroneous parse versions more eagerly
2016-06-02 14:04:48 -07:00
Max Brunsfeld
ea47fdc0fe
Rework logic for when to abandon parses with errors
2016-05-29 22:36:47 -07:00
Max Brunsfeld
e1a3a1daeb
Import error corpus entries from grammar repos
...
Now that error recovery requires no input for the grammar author, it shouldn't
be tested in the individual grammar repos.
2016-05-28 20:12:02 -07:00
Max Brunsfeld
bc8df9f5c5
Avoid recompiling test languages when possible
2016-03-03 12:05:04 -08:00
Max Brunsfeld
da2ef7ad35
Store trees in the links between stack nodes, not in the nodes themselves
2016-02-23 17:35:50 -08:00
Max Brunsfeld
b80a330a74
Fix assorted memory leaks in test code
2016-02-05 12:23:54 -08:00
Max Brunsfeld
b1c8b74e9c
Avoid leak caused by earlier corpus spec failures
2016-02-05 11:35:40 -08:00
Max Brunsfeld
2f2ca401be
Fix last few leaks, add leak checking to all randomized specs
2016-02-05 11:18:22 -08:00
Max Brunsfeld
0f7dbea9a3
Unify test targets, use externally defined languages as fixtures
2016-01-15 11:19:24 -08:00
Max Brunsfeld
569b9d4099
Allow comments within grammar JSON
2016-01-14 11:28:13 -08:00
Max Brunsfeld
ad4089a4bf
Move anonymous tokens grammar into integration spec
2016-01-14 10:35:03 -08:00
Max Brunsfeld
4a5deda071
Add tests that compile a grammar and use its parser
2016-01-14 10:11:30 -08:00