about summary refs log tree commit diff
path: root/crates/parser/src
AgeCommit message (Collapse)AuthorLines
2022-01-01add expr testsAleksey Kladov-1/+10
2022-01-01tests for tyAleksey Kladov-0/+7
2022-01-01internal: add tests for patternsAleksey Kladov-0/+10
2021-12-29restore invariatnsAleksey Kladov-10/+25
2021-12-29parse empty statemet as statemetnAleksey Kladov-15/+6
2021-12-29renameAleksey Kladov-20/+19
2021-12-29compressAleksey Kladov-5/+6
2021-12-29internal: add tests for extra parser entry pointsAleksey Kladov-1/+46
2021-12-28dead codeAleksey Kladov-62/+2
2021-12-28remove Item::parseAleksey Kladov-2/+0
2021-12-28internal: start isolating ssr-related parsing APIs to SSRAleksey Kladov-2/+0
2021-12-28dead codeAleksey Kladov-2/+0
2021-12-28add TopEntryPointAleksey Kladov-35/+82
2021-12-28simplifyAleksey Kladov-11/+13
2021-12-28move pathAleksey Kladov-8/+7
2021-12-28move exprAleksey Kladov-0/+5
2021-12-28move tyAleksey Kladov-3/+7
2021-12-28move pat to prefix entry pointsAleksey Kladov-4/+9
2021-12-28move stmt to entry pointsAleksey Kladov-12/+6
2021-12-28internal: move block to prefix entry pointAleksey Kladov-0/+6
2021-12-28internal: move visibility to a prefix entry pointAleksey Kladov-7/+4
2021-12-28internal: add prefix entry pointsAleksey Kladov-0/+36
2021-12-26internal: move inline parser tests to parser crateAleksey Kladov-11/+147
2021-12-26internal: move outlined parser testsAleksey Kladov-2/+57
2021-12-26internal: move ws attachment logic to the parser crateAleksey Kladov-25/+222
This has to re-introduce the `sink` pattern, because doing this purely with iterators is awkward :( Maaaybe the event vector was a false start? But, anyway, I like the current factoring more -- it sort-of obvious that we do want to keep ws-attachment business in the parser, and that we also don't want that to depend on the particular tree structure. I think `shortcuts` module achieves that.
2021-12-25internal: renameAleksey Kladov-55/+72
2021-12-25internal: replace TreeSink with a data structureAleksey Kladov-35/+91
The general theme of this is to make parser a better independent library. The specific thing we do here is replacing callback based TreeSink with a data structure. That is, rather than calling user-provided tree construction methods, the parser now spits out a very bare-bones tree, effectively a log of a DFS traversal. This makes the parser usable without any *specifc* tree sink, and allows us to, eg, move tests into this crate. Now, it's also true that this is a distinction without a difference, as the old and the new interface are equivalent in expressiveness. Still, this new thing seems somewhat simpler. But yeah, I admit I don't have a suuper strong motivation here, just a hunch that this is better.
2021-12-18Update crates/parser/src/lexed_str.rsAleksey Kladov-1/+1
Co-authored-by: bjorn3 <bjorn3@users.noreply.github.com>
2021-12-18internal: move all the lexing to the parser crateAleksey Kladov-7/+33
2021-12-18converting lexed str to tokensAleksey Kladov-1/+28
2021-12-18soa all the thingsAleksey Kladov-34/+75
2021-12-18move lexing to the parser crateAleksey Kladov-1/+283
2021-12-12prettyfyAleksey Kladov-19/+20
2021-12-12consistencyAleksey Kladov-6/+6
2021-12-12simplifyAleksey Kladov-47/+23
2021-12-12tighten up invariantsAleksey Kladov-5/+2
2021-12-12add cross-crate inlinesAleksey Kladov-1/+5
2021-12-12port mbe to soa tokensAleksey Kladov-2/+26
2021-12-12more orthogonal interfaceAleksey Kladov-7/+10
2021-12-12parser tests workAleksey Kladov-37/+32
2021-12-12Switch parser to use tokensAleksey Kladov-53/+47
2021-12-12use eof token pattenrAleksey Kladov-4/+12
2021-12-12start SOA parser interfaceAleksey Kladov-0/+59
2021-12-06Bump parser step limit a littleLaurențiu Nicola-1/+4
2021-11-18fix: parse the range pat inside the tuple patzhoufan-1/+6
2021-11-10Handle pub tuple fields in tuple structsAdam Bratschi-Kaye-8/+16
The current implementation will throw a parser error for tuple structs that contain a pub tuple field. For example, ```rust struct Foo(pub (u32, u32)); ``` is valid Rust, but rust-analyzer will throw a parser error. This is because the parens after `pub` is treated as a visibility context. Allowing a tuple type to follow `pub` in the special case when we are defining fields in a tuple struct can fix the issue.
2021-10-23internal: remove unused dollarsAleksey Kladov-43/+4
2021-10-19internal: Parse const trait boundsLukas Wirth-6/+16
2021-10-07Support `let...else`Jonas Schievink-0/+11
2021-10-06parser: fix parsing of macro call inside generic argscynecx-1/+4