aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_parser
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_parser')
-rw-r--r--crates/ra_parser/src/grammar/params.rs13
1 files changed, 12 insertions, 1 deletions
diff --git a/crates/ra_parser/src/grammar/params.rs b/crates/ra_parser/src/grammar/params.rs
index 723b56343..0b09f1874 100644
--- a/crates/ra_parser/src/grammar/params.rs
+++ b/crates/ra_parser/src/grammar/params.rs
@@ -41,9 +41,20 @@ fn list_(p: &mut Parser, flavor: Flavor) {
41 let m = p.start(); 41 let m = p.start();
42 p.bump(); 42 p.bump();
43 if flavor.type_required() { 43 if flavor.type_required() {
44 // test self_param_outer_attr
45 // fn f(#[must_use] self) {}
46 attributes::outer_attributes(p);
44 opt_self_param(p); 47 opt_self_param(p);
45 } 48 }
46 while !p.at(EOF) && !p.at(ket) && !(flavor.type_required() && p.at(T![...])) { 49 while !p.at(EOF) && !p.at(ket) {
50 // test param_outer_arg
51 // fn f(#[attr1] pat: Type) {}
52 attributes::outer_attributes(p);
53
54 if flavor.type_required() && p.at(T![...]) {
55 break;
56 }
57
47 if !p.at_ts(VALUE_PARAMETER_FIRST) { 58 if !p.at_ts(VALUE_PARAMETER_FIRST) {
48 p.error("expected value parameter"); 59 p.error("expected value parameter");
49 break; 60 break;