1
1
mirror of https://github.com/github/semantic.git synced 2024-12-23 06:41:45 +03:00
Commit Graph

202 Commits

Author SHA1 Message Date
Rob Rix
974020891a Assign Switch terms language-agnostically. 2017-01-23 15:04:05 -05:00
Rob Rix
a7cbea7051 Handle break/continue statements language-agnostically. 2017-01-23 14:09:07 -05:00
Rob Rix
a0bdcb9f60 Handle pairs in the default term assignment. 2017-01-23 14:07:47 -05:00
Rob Rix
3809b07723 Group language-agnostic patterns. 2017-01-20 16:49:45 -05:00
Rob Rix
ed217d9d10 Add language-agnostic handling of while statements. 2017-01-20 16:40:34 -05:00
Rob Rix
a49ca3cbe6 Add language-agnostic handling of return statements. 2017-01-20 16:39:27 -05:00
Rob Rix
24753de48d Add a default handler for if statements. 2017-01-20 15:20:36 -05:00
Rob Rix
c9af7b1196 Per-language term assignment is pure. 2017-01-20 15:03:40 -05:00
Rob Rix
6abb7d812a Handle operators in the default term assignment. 2017-01-20 14:59:49 -05:00
Rob Rix
a16f3b4e99 defaultTermAssignment receives the list of all children. 2017-01-20 14:55:43 -05:00
Rob Rix
3ed32e9225 defaultTermAssignment returns in IO. 2017-01-20 14:54:03 -05:00
Rob Rix
427afdf61c Ruby term assignment returns Syntax. 2017-01-20 14:15:09 -05:00
Rob Rix
600b861135 C term assignment returns Syntax. 2017-01-20 14:12:56 -05:00
Rob Rix
17ce8d6988 JavaScript term assignment returns Syntax. 2017-01-20 14:09:44 -05:00
Rob Rix
a538d39b31 Per-language term assignment returns Syntax, not Term. 2017-01-20 14:09:29 -05:00
Rob Rix
af8b3bf268 Go term assignment is (notionally) partial. 2017-01-20 13:51:52 -05:00
Rob Rix
27a01e8ddc Fall back to default term assignment if we don’t have a language. 2017-01-20 13:48:52 -05:00
Rob Rix
45621eedd8 JavaScript term assignment is (notionally) partial. 2017-01-20 13:47:06 -05:00
Rob Rix
2e7c4c2ac4 C term assignment is (notionally) partial. 2017-01-20 13:45:05 -05:00
Rob Rix
5432eaab34 Ruby term assignment is (notionally) partial. 2017-01-20 13:37:20 -05:00
Rob Rix
740f1ee174 Write a fallback path for partial term assignment. 2017-01-20 13:35:38 -05:00
Rob Rix
f84c578371 Construct parse error terms for all languages. 2017-01-20 13:11:04 -05:00
Rob Rix
44ecf732fa Curry defaultTermAssignment. 2017-01-20 13:07:19 -05:00
Rob Rix
a6c897163c Rename termConstructor to termAssignment. 2017-01-20 13:05:55 -05:00
Rob Rix
8dbf54bcca Export the default term assignment. 2017-01-20 13:04:36 -05:00
Rob Rix
c1e82f9b37 Define a default term assignment. 2017-01-20 13:03:52 -05:00
Rob Rix
1c0c7e4bdf Factor slicing the source out of term assignment. 2017-01-20 12:59:56 -05:00
Rob Rix
c93d9abe0b Pass the annotations in whole. 2017-01-19 16:36:49 -05:00
Rob Rix
b8901998ff Rename termConstructor to assignTerm. 2017-01-19 15:22:04 -05:00
Rob Rix
5ef2464550 Extract the overall term constructor to the top level. 2017-01-19 15:18:02 -05:00
Rob Rix
4d1d84ef9f Map parse error categories in one place. 2017-01-19 15:09:22 -05:00
Rob Rix
33040ea22e Assign terms based on the Category. 2017-01-19 12:26:45 -05:00
Rob Rix
83acde8ad4 Add a function computing the Category for a given language & production name. 2017-01-19 12:26:20 -05:00
Rob Rix
dbcfb85c1c This comment now applies to sourceSpan as well. 2017-01-18 13:40:55 -05:00
Rob Rix
0854ba66e2 Evaluate the SourceSpan strictly. 2017-01-18 13:39:58 -05:00
Rob Rix
60a8f588e4 Term assignment takes a pure SourceSpan.
We always access this now, so we don’t need to guard it in IO.
2017-01-18 13:39:40 -05:00
Timothy Clem
5c0ee56565 Bring in new tree-sitter API to query all child nodes 2016-12-06 11:21:31 -08:00
joshvera
30a3961409 Add go, defer, and subscript access statements 2016-11-14 19:05:02 -05:00
joshvera
0d58e97070 Merge remote-tracking branch 'origin/master' into go-parser 2016-11-02 15:25:50 -04:00
Timothy Clem
4b42939bf3 Basics of Ruby termConstructor 2016-10-19 08:30:46 -07:00
joshvera
9d81396317 construct Go terms with its termConstructor 2016-10-17 15:51:53 -04:00
joshvera
098655b1d9 Remove filepath from SourceSpan 2016-10-11 15:09:24 -04:00
joshvera
c0a8483263 Merge remote-tracking branch 'origin/master' into add-source-spans 2016-10-07 11:28:57 -04:00
joshvera
4c219279b2 SourceSpans are one-indexed 2016-10-06 18:31:06 -04:00
Timothy Clem
fa2f13ab74 Update to latest tree-sitter and parsers 2016-10-06 11:07:40 -07:00
joshvera
7ba5607cc8 Add source spans to terms 2016-10-05 17:27:45 -04:00
Rob Rix
fc43dd54a0 🔥 a redundant import. 2016-09-14 19:23:40 -04:00
Rick Winfrey
67d5bec5ff Format comment 2016-09-09 16:23:19 -05:00
Rob Rix
29e5b5d1da Filter empty nodes out at the assignment of children. 2016-09-08 09:42:16 -04:00
Rob Rix
eccaab1fbd Use record wildcards to destructure the source blob. 2016-09-08 09:40:00 -04:00