diff options
Diffstat (limited to 'crates')
-rw-r--r-- | crates/ra_parser/src/grammar/expressions/atom.rs | 2 | ||||
-rw-r--r-- | crates/ra_parser/src/grammar/patterns.rs | 5 | ||||
-rw-r--r-- | crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rs | 6 |
3 files changed, 6 insertions, 7 deletions
diff --git a/crates/ra_parser/src/grammar/expressions/atom.rs b/crates/ra_parser/src/grammar/expressions/atom.rs index ab8fb9f6e..bc942ae01 100644 --- a/crates/ra_parser/src/grammar/expressions/atom.rs +++ b/crates/ra_parser/src/grammar/expressions/atom.rs | |||
@@ -414,8 +414,6 @@ pub(crate) fn match_arm_list(p: &mut Parser) { | |||
414 | // X | Y if Z => (), | 414 | // X | Y if Z => (), |
415 | // | X | Y if Z => (), | 415 | // | X | Y if Z => (), |
416 | // | X => (), | 416 | // | X => (), |
417 | // box X => (), | ||
418 | // Some(box X) => (), | ||
419 | // }; | 417 | // }; |
420 | // } | 418 | // } |
421 | fn match_arm(p: &mut Parser) -> BlockLike { | 419 | fn match_arm(p: &mut Parser) -> BlockLike { |
diff --git a/crates/ra_parser/src/grammar/patterns.rs b/crates/ra_parser/src/grammar/patterns.rs index 67f1548a7..f9e6de13c 100644 --- a/crates/ra_parser/src/grammar/patterns.rs +++ b/crates/ra_parser/src/grammar/patterns.rs | |||
@@ -269,11 +269,6 @@ fn bind_pat(p: &mut Parser, with_at: bool) -> CompletedMarker { | |||
269 | m.complete(p, BIND_PAT) | 269 | m.complete(p, BIND_PAT) |
270 | } | 270 | } |
271 | 271 | ||
272 | // test_err ref_box_pat | ||
273 | // fn main() { | ||
274 | // let ref box i = (); | ||
275 | // } | ||
276 | |||
277 | // test box_pat | 272 | // test box_pat |
278 | // fn main() { | 273 | // fn main() { |
279 | // let box i = (); | 274 | // let box i = (); |
diff --git a/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rs b/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rs new file mode 100644 index 000000000..d3fa2e468 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rs | |||
@@ -0,0 +1,6 @@ | |||
1 | fn main() { | ||
2 | let ref box i = (); | ||
3 | let mut box i = (); | ||
4 | let ref mut box i = (); | ||
5 | } | ||
6 | |||