rust-analyzer/crates/ra_parser/src
bors[bot] 2d79a1ad83
Merge #1848
1848: Parse `..` as a full pattern r=matklad a=ecstatic-morse

Resolves #1479.

This PR implements [RFC 2707](https://github.com/rust-lang/rfcs/pull/2707) in the parser. It introduces a new `DotDotPat` AST node modeled on `PlaceholderPat` and changes the parsing of tuple and slice patterns to conform to the RFC.

Notably, this PR does *not* change the resulting AST when `..` appears in a struct pattern (e.g. `Struct { a, b: c, .. }`). I *think* this is the behavior mandated by RFC 2707, but someone should confirm this.

Co-authored-by: Dylan MacKenzie <ecstaticmorse@gmail.com>
2019-09-15 07:10:16 +00:00
..
grammar Merge #1848 2019-09-15 07:10:16 +00:00
syntax_kind Add DotDotPat to AST 2019-09-14 17:08:22 -07:00
event.rs allow rustfmt to reorder imports 2019-07-04 23:09:09 +03:00
grammar.rs WIP: switch to fully decomposed tokens internally 2019-09-10 15:46:39 +03:00
lib.rs simplify 2019-09-02 18:58:21 +03:00
parser.rs don't break parser error recovery in presence of macros 2019-09-12 12:38:07 +03:00
syntax_kind.rs use derive(Debug) for SyntaxKind 2019-08-19 13:11:51 +03:00
token_set.rs docs 2019-02-21 15:24:42 +03:00