aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/test_data/parser/err
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_syntax/test_data/parser/err')
-rw-r--r--crates/ra_syntax/test_data/parser/err/0000_struct_field_missing_comma.rast68
-rw-r--r--crates/ra_syntax/test_data/parser/err/0001_item_recovery_in_file.rast36
-rw-r--r--crates/ra_syntax/test_data/parser/err/0002_duplicate_shebang.rast78
-rw-r--r--crates/ra_syntax/test_data/parser/err/0003_C++_semicolon.rast76
-rw-r--r--crates/ra_syntax/test_data/parser/err/0004_use_path_bad_segment.rast32
-rw-r--r--crates/ra_syntax/test_data/parser/err/0005_attribute_recover.rast120
-rw-r--r--crates/ra_syntax/test_data/parser/err/0006_named_field_recovery.rast148
-rw-r--r--crates/ra_syntax/test_data/parser/err/0007_stray_curly_in_file.rast66
-rw-r--r--crates/ra_syntax/test_data/parser/err/0008_item_block_recovery.rast162
-rw-r--r--crates/ra_syntax/test_data/parser/err/0009_broken_struct_type_parameter.rast116
-rw-r--r--crates/ra_syntax/test_data/parser/err/0010_unsafe_lambda_block.rast90
-rw-r--r--crates/ra_syntax/test_data/parser/err/0011_extern_struct.rast26
-rw-r--r--crates/ra_syntax/test_data/parser/err/0012_broken_lambda.rast636
-rw-r--r--crates/ra_syntax/test_data/parser/err/0013_invalid_type.rast178
-rw-r--r--crates/ra_syntax/test_data/parser/err/0014_where_no_bounds.rast64
-rw-r--r--crates/ra_syntax/test_data/parser/err/0015_curly_in_params.rast48
-rw-r--r--crates/ra_syntax/test_data/parser/err/0016_missing_semi.rast88
-rw-r--r--crates/ra_syntax/test_data/parser/err/0017_incomplete_binexpr.rast94
-rw-r--r--crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast264
-rw-r--r--crates/ra_syntax/test_data/parser/err/0019_let_recover.rast214
-rw-r--r--crates/ra_syntax/test_data/parser/err/0020_fn_recover.rast42
-rw-r--r--crates/ra_syntax/test_data/parser/err/0021_incomplete_param.rast70
-rw-r--r--crates/ra_syntax/test_data/parser/err/0022_bad_exprs.rast366
-rw-r--r--crates/ra_syntax/test_data/parser/err/0023_mismatched_paren.rast88
-rw-r--r--crates/ra_syntax/test_data/parser/err/0024_many_type_parens.rast642
-rw-r--r--crates/ra_syntax/test_data/parser/err/0025_nope.rast408
-rw-r--r--crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast98
-rw-r--r--crates/ra_syntax/test_data/parser/err/0027_incomplere_where_for.rast58
-rw-r--r--crates/ra_syntax/test_data/parser/err/0029_field_completion.rast72
-rw-r--r--crates/ra_syntax/test_data/parser/err/0031_block_inner_attrs.rast250
-rw-r--r--crates/ra_syntax/test_data/parser/err/0032_match_arms_inner_attrs.rast408
-rw-r--r--crates/ra_syntax/test_data/parser/err/0033_match_arms_outer_attrs.rast134
-rw-r--r--crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rast192
-rw-r--r--crates/ra_syntax/test_data/parser/err/0035_use_recover.rast108
-rw-r--r--crates/ra_syntax/test_data/parser/err/0036_partial_use.rast102
-rw-r--r--crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast198
-rw-r--r--crates/ra_syntax/test_data/parser/err/0038_endless_inclusive_range.rast60
-rw-r--r--crates/ra_syntax/test_data/parser/err/0039_lambda_recovery.rast166
38 files changed, 3033 insertions, 3033 deletions
diff --git a/crates/ra_syntax/test_data/parser/err/0000_struct_field_missing_comma.rast b/crates/ra_syntax/test_data/parser/err/0000_struct_field_missing_comma.rast
index edcd936b0..81f0f575c 100644
--- a/crates/ra_syntax/test_data/parser/err/0000_struct_field_missing_comma.rast
+++ b/crates/ra_syntax/test_data/parser/err/0000_struct_field_missing_comma.rast
@@ -1,34 +1,34 @@
1SOURCE_FILE@[0; 34) 1SOURCE_FILE@0..34
2 STRUCT_DEF@[0; 34) 2 STRUCT_DEF@0..34
3 STRUCT_KW@[0; 6) "struct" 3 STRUCT_KW@0..6 "struct"
4 WHITESPACE@[6; 7) " " 4 WHITESPACE@6..7 " "
5 NAME@[7; 8) 5 NAME@7..8
6 IDENT@[7; 8) "S" 6 IDENT@7..8 "S"
7 WHITESPACE@[8; 9) " " 7 WHITESPACE@8..9 " "
8 RECORD_FIELD_DEF_LIST@[9; 34) 8 RECORD_FIELD_DEF_LIST@9..34
9 L_CURLY@[9; 10) "{" 9 L_CURLY@9..10 "{"
10 WHITESPACE@[10; 15) "\n " 10 WHITESPACE@10..15 "\n "
11 RECORD_FIELD_DEF@[15; 21) 11 RECORD_FIELD_DEF@15..21
12 NAME@[15; 16) 12 NAME@15..16
13 IDENT@[15; 16) "a" 13 IDENT@15..16 "a"
14 COLON@[16; 17) ":" 14 COLON@16..17 ":"
15 WHITESPACE@[17; 18) " " 15 WHITESPACE@17..18 " "
16 PATH_TYPE@[18; 21) 16 PATH_TYPE@18..21
17 PATH@[18; 21) 17 PATH@18..21
18 PATH_SEGMENT@[18; 21) 18 PATH_SEGMENT@18..21
19 NAME_REF@[18; 21) 19 NAME_REF@18..21
20 IDENT@[18; 21) "u32" 20 IDENT@18..21 "u32"
21 WHITESPACE@[21; 26) "\n " 21 WHITESPACE@21..26 "\n "
22 RECORD_FIELD_DEF@[26; 32) 22 RECORD_FIELD_DEF@26..32
23 NAME@[26; 27) 23 NAME@26..27
24 IDENT@[26; 27) "b" 24 IDENT@26..27 "b"
25 COLON@[27; 28) ":" 25 COLON@27..28 ":"
26 WHITESPACE@[28; 29) " " 26 WHITESPACE@28..29 " "
27 PATH_TYPE@[29; 32) 27 PATH_TYPE@29..32
28 PATH@[29; 32) 28 PATH@29..32
29 PATH_SEGMENT@[29; 32) 29 PATH_SEGMENT@29..32
30 NAME_REF@[29; 32) 30 NAME_REF@29..32
31 IDENT@[29; 32) "u32" 31 IDENT@29..32 "u32"
32 WHITESPACE@[32; 33) "\n" 32 WHITESPACE@32..33 "\n"
33 R_CURLY@[33; 34) "}" 33 R_CURLY@33..34 "}"
34error [21; 21): expected COMMA 34error 21..21: expected COMMA
diff --git a/crates/ra_syntax/test_data/parser/err/0001_item_recovery_in_file.rast b/crates/ra_syntax/test_data/parser/err/0001_item_recovery_in_file.rast
index 2d653715e..97d0fe910 100644
--- a/crates/ra_syntax/test_data/parser/err/0001_item_recovery_in_file.rast
+++ b/crates/ra_syntax/test_data/parser/err/0001_item_recovery_in_file.rast
@@ -1,18 +1,18 @@
1SOURCE_FILE@[0; 21) 1SOURCE_FILE@0..21
2 ERROR@[0; 2) 2 ERROR@0..2
3 IF_KW@[0; 2) "if" 3 IF_KW@0..2 "if"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 ERROR@[3; 8) 5 ERROR@3..8
6 MATCH_KW@[3; 8) "match" 6 MATCH_KW@3..8 "match"
7 WHITESPACE@[8; 10) "\n\n" 7 WHITESPACE@8..10 "\n\n"
8 STRUCT_DEF@[10; 21) 8 STRUCT_DEF@10..21
9 STRUCT_KW@[10; 16) "struct" 9 STRUCT_KW@10..16 "struct"
10 WHITESPACE@[16; 17) " " 10 WHITESPACE@16..17 " "
11 NAME@[17; 18) 11 NAME@17..18
12 IDENT@[17; 18) "S" 12 IDENT@17..18 "S"
13 WHITESPACE@[18; 19) " " 13 WHITESPACE@18..19 " "
14 RECORD_FIELD_DEF_LIST@[19; 21) 14 RECORD_FIELD_DEF_LIST@19..21
15 L_CURLY@[19; 20) "{" 15 L_CURLY@19..20 "{"
16 R_CURLY@[20; 21) "}" 16 R_CURLY@20..21 "}"
17error [0; 0): expected an item 17error 0..0: expected an item
18error [3; 3): expected an item 18error 3..3: expected an item
diff --git a/crates/ra_syntax/test_data/parser/err/0002_duplicate_shebang.rast b/crates/ra_syntax/test_data/parser/err/0002_duplicate_shebang.rast
index 831bbf83f..6717995e9 100644
--- a/crates/ra_syntax/test_data/parser/err/0002_duplicate_shebang.rast
+++ b/crates/ra_syntax/test_data/parser/err/0002_duplicate_shebang.rast
@@ -1,39 +1,39 @@
1SOURCE_FILE@[0; 42) 1SOURCE_FILE@0..42
2 SHEBANG@[0; 20) "#!/use/bin/env rusti" 2 SHEBANG@0..20 "#!/use/bin/env rusti"
3 WHITESPACE@[20; 21) "\n" 3 WHITESPACE@20..21 "\n"
4 ATTR@[21; 23) 4 ATTR@21..23
5 POUND@[21; 22) "#" 5 POUND@21..22 "#"
6 BANG@[22; 23) "!" 6 BANG@22..23 "!"
7 ERROR@[23; 24) 7 ERROR@23..24
8 SLASH@[23; 24) "/" 8 SLASH@23..24 "/"
9 USE_ITEM@[24; 28) 9 USE_ITEM@24..28
10 USE_KW@[24; 27) "use" 10 USE_KW@24..27 "use"
11 ERROR@[27; 28) 11 ERROR@27..28
12 SLASH@[27; 28) "/" 12 SLASH@27..28 "/"
13 MACRO_CALL@[28; 31) 13 MACRO_CALL@28..31
14 PATH@[28; 31) 14 PATH@28..31
15 PATH_SEGMENT@[28; 31) 15 PATH_SEGMENT@28..31
16 NAME_REF@[28; 31) 16 NAME_REF@28..31
17 IDENT@[28; 31) "bin" 17 IDENT@28..31 "bin"
18 ERROR@[31; 32) 18 ERROR@31..32
19 SLASH@[31; 32) "/" 19 SLASH@31..32 "/"
20 MACRO_CALL@[32; 41) 20 MACRO_CALL@32..41
21 PATH@[32; 35) 21 PATH@32..35
22 PATH_SEGMENT@[32; 35) 22 PATH_SEGMENT@32..35
23 NAME_REF@[32; 35) 23 NAME_REF@32..35
24 IDENT@[32; 35) "env" 24 IDENT@32..35 "env"
25 WHITESPACE@[35; 36) " " 25 WHITESPACE@35..36 " "
26 NAME@[36; 41) 26 NAME@36..41
27 IDENT@[36; 41) "rusti" 27 IDENT@36..41 "rusti"
28 WHITESPACE@[41; 42) "\n" 28 WHITESPACE@41..42 "\n"
29error [23; 23): expected `[` 29error 23..23: expected `[`
30error [23; 23): expected an item 30error 23..23: expected an item
31error [27; 27): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 31error 27..27: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
32error [28; 28): expected SEMICOLON 32error 28..28: expected SEMICOLON
33error [31; 31): expected BANG 33error 31..31: expected BANG
34error [31; 31): expected `{`, `[`, `(` 34error 31..31: expected `{`, `[`, `(`
35error [31; 31): expected SEMICOLON 35error 31..31: expected SEMICOLON
36error [31; 31): expected an item 36error 31..31: expected an item
37error [35; 35): expected BANG 37error 35..35: expected BANG
38error [41; 41): expected `{`, `[`, `(` 38error 41..41: expected `{`, `[`, `(`
39error [41; 41): expected SEMICOLON 39error 41..41: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0003_C++_semicolon.rast b/crates/ra_syntax/test_data/parser/err/0003_C++_semicolon.rast
index 6b89e7572..21c255698 100644
--- a/crates/ra_syntax/test_data/parser/err/0003_C++_semicolon.rast
+++ b/crates/ra_syntax/test_data/parser/err/0003_C++_semicolon.rast
@@ -1,39 +1,39 @@
1SOURCE_FILE@[0; 40) 1SOURCE_FILE@0..40
2 STRUCT_DEF@[0; 39) 2 STRUCT_DEF@0..39
3 STRUCT_KW@[0; 6) "struct" 3 STRUCT_KW@0..6 "struct"
4 WHITESPACE@[6; 7) " " 4 WHITESPACE@6..7 " "
5 NAME@[7; 8) 5 NAME@7..8
6 IDENT@[7; 8) "S" 6 IDENT@7..8 "S"
7 WHITESPACE@[8; 9) " " 7 WHITESPACE@8..9 " "
8 RECORD_FIELD_DEF_LIST@[9; 39) 8 RECORD_FIELD_DEF_LIST@9..39
9 L_CURLY@[9; 10) "{" 9 L_CURLY@9..10 "{"
10 WHITESPACE@[10; 15) "\n " 10 WHITESPACE@10..15 "\n "
11 RECORD_FIELD_DEF@[15; 21) 11 RECORD_FIELD_DEF@15..21
12 NAME@[15; 16) 12 NAME@15..16
13 IDENT@[15; 16) "a" 13 IDENT@15..16 "a"
14 COLON@[16; 17) ":" 14 COLON@16..17 ":"
15 WHITESPACE@[17; 18) " " 15 WHITESPACE@17..18 " "
16 PATH_TYPE@[18; 21) 16 PATH_TYPE@18..21
17 PATH@[18; 21) 17 PATH@18..21
18 PATH_SEGMENT@[18; 21) 18 PATH_SEGMENT@18..21
19 NAME_REF@[18; 21) 19 NAME_REF@18..21
20 IDENT@[18; 21) "i32" 20 IDENT@18..21 "i32"
21 COMMA@[21; 22) "," 21 COMMA@21..22 ","
22 WHITESPACE@[22; 27) "\n " 22 WHITESPACE@22..27 "\n "
23 RECORD_FIELD_DEF@[27; 36) 23 RECORD_FIELD_DEF@27..36
24 NAME@[27; 28) 24 NAME@27..28
25 IDENT@[27; 28) "b" 25 IDENT@27..28 "b"
26 COLON@[28; 29) ":" 26 COLON@28..29 ":"
27 WHITESPACE@[29; 30) " " 27 WHITESPACE@29..30 " "
28 PATH_TYPE@[30; 36) 28 PATH_TYPE@30..36
29 PATH@[30; 36) 29 PATH@30..36
30 PATH_SEGMENT@[30; 36) 30 PATH_SEGMENT@30..36
31 NAME_REF@[30; 36) 31 NAME_REF@30..36
32 IDENT@[30; 36) "String" 32 IDENT@30..36 "String"
33 COMMA@[36; 37) "," 33 COMMA@36..37 ","
34 WHITESPACE@[37; 38) "\n" 34 WHITESPACE@37..38 "\n"
35 R_CURLY@[38; 39) "}" 35 R_CURLY@38..39 "}"
36 ERROR@[39; 40) 36 ERROR@39..40
37 SEMICOLON@[39; 40) ";" 37 SEMICOLON@39..40 ";"
38error [39; 39): expected item, found `;` 38error 39..39: expected item, found `;`
39consider removing this semicolon 39consider removing this semicolon
diff --git a/crates/ra_syntax/test_data/parser/err/0004_use_path_bad_segment.rast b/crates/ra_syntax/test_data/parser/err/0004_use_path_bad_segment.rast
index 1d27d4cd6..8c6b89dc2 100644
--- a/crates/ra_syntax/test_data/parser/err/0004_use_path_bad_segment.rast
+++ b/crates/ra_syntax/test_data/parser/err/0004_use_path_bad_segment.rast
@@ -1,16 +1,16 @@
1SOURCE_FILE@[0; 12) 1SOURCE_FILE@0..12
2 USE_ITEM@[0; 12) 2 USE_ITEM@0..12
3 USE_KW@[0; 3) "use" 3 USE_KW@0..3 "use"
4 WHITESPACE@[3; 4) " " 4 WHITESPACE@3..4 " "
5 USE_TREE@[4; 11) 5 USE_TREE@4..11
6 PATH@[4; 11) 6 PATH@4..11
7 PATH@[4; 7) 7 PATH@4..7
8 PATH_SEGMENT@[4; 7) 8 PATH_SEGMENT@4..7
9 NAME_REF@[4; 7) 9 NAME_REF@4..7
10 IDENT@[4; 7) "foo" 10 IDENT@4..7 "foo"
11 COLON2@[7; 9) "::" 11 COLON2@7..9 "::"
12 PATH_SEGMENT@[9; 11) 12 PATH_SEGMENT@9..11
13 ERROR@[9; 11) 13 ERROR@9..11
14 INT_NUMBER@[9; 11) "92" 14 INT_NUMBER@9..11 "92"
15 SEMICOLON@[11; 12) ";" 15 SEMICOLON@11..12 ";"
16error [9; 9): expected identifier 16error 9..9: expected identifier
diff --git a/crates/ra_syntax/test_data/parser/err/0005_attribute_recover.rast b/crates/ra_syntax/test_data/parser/err/0005_attribute_recover.rast
index cc11421a9..95cc83caa 100644
--- a/crates/ra_syntax/test_data/parser/err/0005_attribute_recover.rast
+++ b/crates/ra_syntax/test_data/parser/err/0005_attribute_recover.rast
@@ -1,60 +1,60 @@
1SOURCE_FILE@[0; 54) 1SOURCE_FILE@0..54
2 FN_DEF@[0; 31) 2 FN_DEF@0..31
3 ATTR@[0; 18) 3 ATTR@0..18
4 POUND@[0; 1) "#" 4 POUND@0..1 "#"
5 L_BRACK@[1; 2) "[" 5 L_BRACK@1..2 "["
6 PATH@[2; 5) 6 PATH@2..5
7 PATH_SEGMENT@[2; 5) 7 PATH_SEGMENT@2..5
8 NAME_REF@[2; 5) 8 NAME_REF@2..5
9 IDENT@[2; 5) "foo" 9 IDENT@2..5 "foo"
10 TOKEN_TREE@[5; 17) 10 TOKEN_TREE@5..17
11 L_PAREN@[5; 6) "(" 11 L_PAREN@5..6 "("
12 IDENT@[6; 9) "foo" 12 IDENT@6..9 "foo"
13 COMMA@[9; 10) "," 13 COMMA@9..10 ","
14 WHITESPACE@[10; 11) " " 14 WHITESPACE@10..11 " "
15 PLUS@[11; 12) "+" 15 PLUS@11..12 "+"
16 COMMA@[12; 13) "," 16 COMMA@12..13 ","
17 WHITESPACE@[13; 14) " " 17 WHITESPACE@13..14 " "
18 INT_NUMBER@[14; 16) "92" 18 INT_NUMBER@14..16 "92"
19 R_PAREN@[16; 17) ")" 19 R_PAREN@16..17 ")"
20 R_BRACK@[17; 18) "]" 20 R_BRACK@17..18 "]"
21 WHITESPACE@[18; 19) "\n" 21 WHITESPACE@18..19 "\n"
22 FN_KW@[19; 21) "fn" 22 FN_KW@19..21 "fn"
23 WHITESPACE@[21; 22) " " 23 WHITESPACE@21..22 " "
24 NAME@[22; 25) 24 NAME@22..25
25 IDENT@[22; 25) "foo" 25 IDENT@22..25 "foo"
26 PARAM_LIST@[25; 27) 26 PARAM_LIST@25..27
27 L_PAREN@[25; 26) "(" 27 L_PAREN@25..26 "("
28 R_PAREN@[26; 27) ")" 28 R_PAREN@26..27 ")"
29 WHITESPACE@[27; 28) " " 29 WHITESPACE@27..28 " "
30 BLOCK_EXPR@[28; 31) 30 BLOCK_EXPR@28..31
31 BLOCK@[28; 31) 31 BLOCK@28..31
32 L_CURLY@[28; 29) "{" 32 L_CURLY@28..29 "{"
33 WHITESPACE@[29; 30) "\n" 33 WHITESPACE@29..30 "\n"
34 R_CURLY@[30; 31) "}" 34 R_CURLY@30..31 "}"
35 WHITESPACE@[31; 34) "\n\n\n" 35 WHITESPACE@31..34 "\n\n\n"
36 ATTR@[34; 53) 36 ATTR@34..53
37 POUND@[34; 35) "#" 37 POUND@34..35 "#"
38 L_BRACK@[35; 36) "[" 38 L_BRACK@35..36 "["
39 PATH@[36; 39) 39 PATH@36..39
40 PATH_SEGMENT@[36; 39) 40 PATH_SEGMENT@36..39
41 NAME_REF@[36; 39) 41 NAME_REF@36..39
42 IDENT@[36; 39) "foo" 42 IDENT@36..39 "foo"
43 TOKEN_TREE@[39; 53) 43 TOKEN_TREE@39..53
44 L_PAREN@[39; 40) "(" 44 L_PAREN@39..40 "("
45 WHITESPACE@[40; 41) "\n" 45 WHITESPACE@40..41 "\n"
46 FN_KW@[41; 43) "fn" 46 FN_KW@41..43 "fn"
47 WHITESPACE@[43; 44) " " 47 WHITESPACE@43..44 " "
48 IDENT@[44; 47) "foo" 48 IDENT@44..47 "foo"
49 TOKEN_TREE@[47; 49) 49 TOKEN_TREE@47..49
50 L_PAREN@[47; 48) "(" 50 L_PAREN@47..48 "("
51 R_PAREN@[48; 49) ")" 51 R_PAREN@48..49 ")"
52 WHITESPACE@[49; 50) " " 52 WHITESPACE@49..50 " "
53 TOKEN_TREE@[50; 53) 53 TOKEN_TREE@50..53
54 L_CURLY@[50; 51) "{" 54 L_CURLY@50..51 "{"
55 WHITESPACE@[51; 52) "\n" 55 WHITESPACE@51..52 "\n"
56 R_CURLY@[52; 53) "}" 56 R_CURLY@52..53 "}"
57 WHITESPACE@[53; 54) "\n" 57 WHITESPACE@53..54 "\n"
58error [53; 53): expected R_PAREN 58error 53..53: expected R_PAREN
59error [53; 53): expected `]` 59error 53..53: expected `]`
60error [53; 53): expected an item 60error 53..53: expected an item
diff --git a/crates/ra_syntax/test_data/parser/err/0006_named_field_recovery.rast b/crates/ra_syntax/test_data/parser/err/0006_named_field_recovery.rast
index 84fd92862..2d6364998 100644
--- a/crates/ra_syntax/test_data/parser/err/0006_named_field_recovery.rast
+++ b/crates/ra_syntax/test_data/parser/err/0006_named_field_recovery.rast
@@ -1,74 +1,74 @@
1SOURCE_FILE@[0; 74) 1SOURCE_FILE@0..74
2 STRUCT_DEF@[0; 73) 2 STRUCT_DEF@0..73
3 STRUCT_KW@[0; 6) "struct" 3 STRUCT_KW@0..6 "struct"
4 WHITESPACE@[6; 7) " " 4 WHITESPACE@6..7 " "
5 NAME@[7; 8) 5 NAME@7..8
6 IDENT@[7; 8) "S" 6 IDENT@7..8 "S"
7 WHITESPACE@[8; 9) " " 7 WHITESPACE@8..9 " "
8 RECORD_FIELD_DEF_LIST@[9; 73) 8 RECORD_FIELD_DEF_LIST@9..73
9 L_CURLY@[9; 10) "{" 9 L_CURLY@9..10 "{"
10 WHITESPACE@[10; 15) "\n " 10 WHITESPACE@10..15 "\n "
11 RECORD_FIELD_DEF@[15; 21) 11 RECORD_FIELD_DEF@15..21
12 NAME@[15; 16) 12 NAME@15..16
13 IDENT@[15; 16) "f" 13 IDENT@15..16 "f"
14 COLON@[16; 17) ":" 14 COLON@16..17 ":"
15 WHITESPACE@[17; 18) " " 15 WHITESPACE@17..18 " "
16 PATH_TYPE@[18; 21) 16 PATH_TYPE@18..21
17 PATH@[18; 21) 17 PATH@18..21
18 PATH_SEGMENT@[18; 21) 18 PATH_SEGMENT@18..21
19 NAME_REF@[18; 21) 19 NAME_REF@18..21
20 IDENT@[18; 21) "u32" 20 IDENT@18..21 "u32"
21 COMMA@[21; 22) "," 21 COMMA@21..22 ","
22 WHITESPACE@[22; 27) "\n " 22 WHITESPACE@22..27 "\n "
23 VISIBILITY@[27; 30) 23 VISIBILITY@27..30
24 PUB_KW@[27; 30) "pub" 24 PUB_KW@27..30 "pub"
25 WHITESPACE@[30; 31) " " 25 WHITESPACE@30..31 " "
26 ERROR@[31; 33) 26 ERROR@31..33
27 INT_NUMBER@[31; 33) "92" 27 INT_NUMBER@31..33 "92"
28 WHITESPACE@[33; 38) "\n " 28 WHITESPACE@33..38 "\n "
29 ERROR@[38; 39) 29 ERROR@38..39
30 PLUS@[38; 39) "+" 30 PLUS@38..39 "+"
31 WHITESPACE@[39; 40) " " 31 WHITESPACE@39..40 " "
32 ERROR@[40; 41) 32 ERROR@40..41
33 MINUS@[40; 41) "-" 33 MINUS@40..41 "-"
34 WHITESPACE@[41; 42) " " 34 WHITESPACE@41..42 " "
35 ERROR@[42; 43) 35 ERROR@42..43
36 STAR@[42; 43) "*" 36 STAR@42..43 "*"
37 WHITESPACE@[43; 48) "\n " 37 WHITESPACE@43..48 "\n "
38 RECORD_FIELD_DEF@[48; 58) 38 RECORD_FIELD_DEF@48..58
39 VISIBILITY@[48; 51) 39 VISIBILITY@48..51
40 PUB_KW@[48; 51) "pub" 40 PUB_KW@48..51 "pub"
41 WHITESPACE@[51; 52) " " 41 WHITESPACE@51..52 " "
42 NAME@[52; 53) 42 NAME@52..53
43 IDENT@[52; 53) "x" 43 IDENT@52..53 "x"
44 COLON@[53; 54) ":" 44 COLON@53..54 ":"
45 WHITESPACE@[54; 55) " " 45 WHITESPACE@54..55 " "
46 PATH_TYPE@[55; 58) 46 PATH_TYPE@55..58
47 PATH@[55; 58) 47 PATH@55..58
48 PATH_SEGMENT@[55; 58) 48 PATH_SEGMENT@55..58
49 NAME_REF@[55; 58) 49 NAME_REF@55..58
50 IDENT@[55; 58) "u32" 50 IDENT@55..58 "u32"
51 COMMA@[58; 59) "," 51 COMMA@58..59 ","
52 WHITESPACE@[59; 64) "\n " 52 WHITESPACE@59..64 "\n "
53 RECORD_FIELD_DEF@[64; 70) 53 RECORD_FIELD_DEF@64..70
54 NAME@[64; 65) 54 NAME@64..65
55 IDENT@[64; 65) "z" 55 IDENT@64..65 "z"
56 COLON@[65; 66) ":" 56 COLON@65..66 ":"
57 WHITESPACE@[66; 67) " " 57 WHITESPACE@66..67 " "
58 PATH_TYPE@[67; 70) 58 PATH_TYPE@67..70
59 PATH@[67; 70) 59 PATH@67..70
60 PATH_SEGMENT@[67; 70) 60 PATH_SEGMENT@67..70
61 NAME_REF@[67; 70) 61 NAME_REF@67..70
62 IDENT@[67; 70) "f64" 62 IDENT@67..70 "f64"
63 COMMA@[70; 71) "," 63 COMMA@70..71 ","
64 WHITESPACE@[71; 72) "\n" 64 WHITESPACE@71..72 "\n"
65 R_CURLY@[72; 73) "}" 65 R_CURLY@72..73 "}"
66 WHITESPACE@[73; 74) "\n" 66 WHITESPACE@73..74 "\n"
67error [31; 31): expected field declaration 67error 31..31: expected field declaration
68error [33; 33): expected COMMA 68error 33..33: expected COMMA
69error [38; 38): expected field declaration 69error 38..38: expected field declaration
70error [39; 39): expected COMMA 70error 39..39: expected COMMA
71error [40; 40): expected field declaration 71error 40..40: expected field declaration
72error [41; 41): expected COMMA 72error 41..41: expected COMMA
73error [42; 42): expected field declaration 73error 42..42: expected field declaration
74error [43; 43): expected COMMA 74error 43..43: expected COMMA
diff --git a/crates/ra_syntax/test_data/parser/err/0007_stray_curly_in_file.rast b/crates/ra_syntax/test_data/parser/err/0007_stray_curly_in_file.rast
index c24e478f3..dc3e12091 100644
--- a/crates/ra_syntax/test_data/parser/err/0007_stray_curly_in_file.rast
+++ b/crates/ra_syntax/test_data/parser/err/0007_stray_curly_in_file.rast
@@ -1,33 +1,33 @@
1SOURCE_FILE@[0; 31) 1SOURCE_FILE@0..31
2 ERROR@[0; 1) 2 ERROR@0..1
3 R_CURLY@[0; 1) "}" 3 R_CURLY@0..1 "}"
4 WHITESPACE@[1; 3) "\n\n" 4 WHITESPACE@1..3 "\n\n"
5 STRUCT_DEF@[3; 12) 5 STRUCT_DEF@3..12
6 STRUCT_KW@[3; 9) "struct" 6 STRUCT_KW@3..9 "struct"
7 WHITESPACE@[9; 10) " " 7 WHITESPACE@9..10 " "
8 NAME@[10; 11) 8 NAME@10..11
9 IDENT@[10; 11) "S" 9 IDENT@10..11 "S"
10 SEMICOLON@[11; 12) ";" 10 SEMICOLON@11..12 ";"
11 WHITESPACE@[12; 14) "\n\n" 11 WHITESPACE@12..14 "\n\n"
12 ERROR@[14; 15) 12 ERROR@14..15
13 R_CURLY@[14; 15) "}" 13 R_CURLY@14..15 "}"
14 WHITESPACE@[15; 17) "\n\n" 14 WHITESPACE@15..17 "\n\n"
15 FN_DEF@[17; 27) 15 FN_DEF@17..27
16 FN_KW@[17; 19) "fn" 16 FN_KW@17..19 "fn"
17 WHITESPACE@[19; 20) " " 17 WHITESPACE@19..20 " "
18 NAME@[20; 23) 18 NAME@20..23
19 IDENT@[20; 23) "foo" 19 IDENT@20..23 "foo"
20 PARAM_LIST@[23; 25) 20 PARAM_LIST@23..25
21 L_PAREN@[23; 24) "(" 21 L_PAREN@23..24 "("
22 R_PAREN@[24; 25) ")" 22 R_PAREN@24..25 ")"
23 BLOCK_EXPR@[25; 27) 23 BLOCK_EXPR@25..27
24 BLOCK@[25; 27) 24 BLOCK@25..27
25 L_CURLY@[25; 26) "{" 25 L_CURLY@25..26 "{"
26 R_CURLY@[26; 27) "}" 26 R_CURLY@26..27 "}"
27 WHITESPACE@[27; 29) "\n\n" 27 WHITESPACE@27..29 "\n\n"
28 ERROR@[29; 30) 28 ERROR@29..30
29 R_CURLY@[29; 30) "}" 29 R_CURLY@29..30 "}"
30 WHITESPACE@[30; 31) "\n" 30 WHITESPACE@30..31 "\n"
31error [0; 0): unmatched `}` 31error 0..0: unmatched `}`
32error [14; 14): unmatched `}` 32error 14..14: unmatched `}`
33error [29; 29): unmatched `}` 33error 29..29: unmatched `}`
diff --git a/crates/ra_syntax/test_data/parser/err/0008_item_block_recovery.rast b/crates/ra_syntax/test_data/parser/err/0008_item_block_recovery.rast
index 9f5041ae4..97539fcf2 100644
--- a/crates/ra_syntax/test_data/parser/err/0008_item_block_recovery.rast
+++ b/crates/ra_syntax/test_data/parser/err/0008_item_block_recovery.rast
@@ -1,81 +1,81 @@
1SOURCE_FILE@[0; 95) 1SOURCE_FILE@0..95
2 FN_DEF@[0; 12) 2 FN_DEF@0..12
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 BLOCK_EXPR@[9; 12) 11 BLOCK_EXPR@9..12
12 BLOCK@[9; 12) 12 BLOCK@9..12
13 L_CURLY@[9; 10) "{" 13 L_CURLY@9..10 "{"
14 WHITESPACE@[10; 11) "\n" 14 WHITESPACE@10..11 "\n"
15 R_CURLY@[11; 12) "}" 15 R_CURLY@11..12 "}"
16 WHITESPACE@[12; 14) "\n\n" 16 WHITESPACE@12..14 "\n\n"
17 MACRO_CALL@[14; 19) 17 MACRO_CALL@14..19
18 PATH@[14; 17) 18 PATH@14..17
19 PATH_SEGMENT@[14; 17) 19 PATH_SEGMENT@14..17
20 NAME_REF@[14; 17) 20 NAME_REF@14..17
21 IDENT@[14; 17) "bar" 21 IDENT@14..17 "bar"
22 TOKEN_TREE@[17; 19) 22 TOKEN_TREE@17..19
23 L_PAREN@[17; 18) "(" 23 L_PAREN@17..18 "("
24 R_PAREN@[18; 19) ")" 24 R_PAREN@18..19 ")"
25 WHITESPACE@[19; 20) " " 25 WHITESPACE@19..20 " "
26 ERROR@[20; 80) 26 ERROR@20..80
27 L_CURLY@[20; 21) "{" 27 L_CURLY@20..21 "{"
28 WHITESPACE@[21; 26) "\n " 28 WHITESPACE@21..26 "\n "
29 IF_EXPR@[26; 78) 29 IF_EXPR@26..78
30 IF_KW@[26; 28) "if" 30 IF_KW@26..28 "if"
31 WHITESPACE@[28; 29) " " 31 WHITESPACE@28..29 " "
32 CONDITION@[29; 33) 32 CONDITION@29..33
33 LITERAL@[29; 33) 33 LITERAL@29..33
34 TRUE_KW@[29; 33) "true" 34 TRUE_KW@29..33 "true"
35 WHITESPACE@[33; 34) " " 35 WHITESPACE@33..34 " "
36 BLOCK_EXPR@[34; 51) 36 BLOCK_EXPR@34..51
37 BLOCK@[34; 51) 37 BLOCK@34..51
38 L_CURLY@[34; 35) "{" 38 L_CURLY@34..35 "{"
39 WHITESPACE@[35; 44) "\n " 39 WHITESPACE@35..44 "\n "
40 LITERAL@[44; 45) 40 LITERAL@44..45
41 INT_NUMBER@[44; 45) "1" 41 INT_NUMBER@44..45 "1"
42 WHITESPACE@[45; 50) "\n " 42 WHITESPACE@45..50 "\n "
43 R_CURLY@[50; 51) "}" 43 R_CURLY@50..51 "}"
44 WHITESPACE@[51; 52) " " 44 WHITESPACE@51..52 " "
45 ELSE_KW@[52; 56) "else" 45 ELSE_KW@52..56 "else"
46 WHITESPACE@[56; 57) " " 46 WHITESPACE@56..57 " "
47 BLOCK_EXPR@[57; 78) 47 BLOCK_EXPR@57..78
48 BLOCK@[57; 78) 48 BLOCK@57..78
49 L_CURLY@[57; 58) "{" 49 L_CURLY@57..58 "{"
50 WHITESPACE@[58; 67) "\n " 50 WHITESPACE@58..67 "\n "
51 BIN_EXPR@[67; 72) 51 BIN_EXPR@67..72
52 LITERAL@[67; 68) 52 LITERAL@67..68
53 INT_NUMBER@[67; 68) "2" 53 INT_NUMBER@67..68 "2"
54 WHITESPACE@[68; 69) " " 54 WHITESPACE@68..69 " "
55 PLUS@[69; 70) "+" 55 PLUS@69..70 "+"
56 WHITESPACE@[70; 71) " " 56 WHITESPACE@70..71 " "
57 LITERAL@[71; 72) 57 LITERAL@71..72
58 INT_NUMBER@[71; 72) "3" 58 INT_NUMBER@71..72 "3"
59 WHITESPACE@[72; 77) "\n " 59 WHITESPACE@72..77 "\n "
60 R_CURLY@[77; 78) "}" 60 R_CURLY@77..78 "}"
61 WHITESPACE@[78; 79) "\n" 61 WHITESPACE@78..79 "\n"
62 R_CURLY@[79; 80) "}" 62 R_CURLY@79..80 "}"
63 WHITESPACE@[80; 82) "\n\n" 63 WHITESPACE@80..82 "\n\n"
64 FN_DEF@[82; 94) 64 FN_DEF@82..94
65 FN_KW@[82; 84) "fn" 65 FN_KW@82..84 "fn"
66 WHITESPACE@[84; 85) " " 66 WHITESPACE@84..85 " "
67 NAME@[85; 88) 67 NAME@85..88
68 IDENT@[85; 88) "baz" 68 IDENT@85..88 "baz"
69 PARAM_LIST@[88; 90) 69 PARAM_LIST@88..90
70 L_PAREN@[88; 89) "(" 70 L_PAREN@88..89 "("
71 R_PAREN@[89; 90) ")" 71 R_PAREN@89..90 ")"
72 WHITESPACE@[90; 91) " " 72 WHITESPACE@90..91 " "
73 BLOCK_EXPR@[91; 94) 73 BLOCK_EXPR@91..94
74 BLOCK@[91; 94) 74 BLOCK@91..94
75 L_CURLY@[91; 92) "{" 75 L_CURLY@91..92 "{"
76 WHITESPACE@[92; 93) "\n" 76 WHITESPACE@92..93 "\n"
77 R_CURLY@[93; 94) "}" 77 R_CURLY@93..94 "}"
78 WHITESPACE@[94; 95) "\n" 78 WHITESPACE@94..95 "\n"
79error [17; 17): expected BANG 79error 17..17: expected BANG
80error [19; 19): expected SEMICOLON 80error 19..19: expected SEMICOLON
81error [20; 20): expected an item 81error 20..20: expected an item
diff --git a/crates/ra_syntax/test_data/parser/err/0009_broken_struct_type_parameter.rast b/crates/ra_syntax/test_data/parser/err/0009_broken_struct_type_parameter.rast
index 7ed80477d..aca02ece4 100644
--- a/crates/ra_syntax/test_data/parser/err/0009_broken_struct_type_parameter.rast
+++ b/crates/ra_syntax/test_data/parser/err/0009_broken_struct_type_parameter.rast
@@ -1,58 +1,58 @@
1SOURCE_FILE@[0; 43) 1SOURCE_FILE@0..43
2 STRUCT_DEF@[0; 11) 2 STRUCT_DEF@0..11
3 STRUCT_KW@[0; 6) "struct" 3 STRUCT_KW@0..6 "struct"
4 WHITESPACE@[6; 7) " " 4 WHITESPACE@6..7 " "
5 NAME@[7; 8) 5 NAME@7..8
6 IDENT@[7; 8) "S" 6 IDENT@7..8 "S"
7 TYPE_PARAM_LIST@[8; 11) 7 TYPE_PARAM_LIST@8..11
8 L_ANGLE@[8; 9) "<" 8 L_ANGLE@8..9 "<"
9 ERROR@[9; 11) 9 ERROR@9..11
10 INT_NUMBER@[9; 11) "90" 10 INT_NUMBER@9..11 "90"
11 WHITESPACE@[11; 12) " " 11 WHITESPACE@11..12 " "
12 ERROR@[12; 13) 12 ERROR@12..13
13 PLUS@[12; 13) "+" 13 PLUS@12..13 "+"
14 WHITESPACE@[13; 14) " " 14 WHITESPACE@13..14 " "
15 ERROR@[14; 15) 15 ERROR@14..15
16 INT_NUMBER@[14; 15) "2" 16 INT_NUMBER@14..15 "2"
17 ERROR@[15; 16) 17 ERROR@15..16
18 R_ANGLE@[15; 16) ">" 18 R_ANGLE@15..16 ">"
19 WHITESPACE@[16; 17) " " 19 WHITESPACE@16..17 " "
20 ERROR@[17; 31) 20 ERROR@17..31
21 L_CURLY@[17; 18) "{" 21 L_CURLY@17..18 "{"
22 WHITESPACE@[18; 23) "\n " 22 WHITESPACE@18..23 "\n "
23 EXPR_STMT@[23; 24) 23 EXPR_STMT@23..24
24 PATH_EXPR@[23; 24) 24 PATH_EXPR@23..24
25 PATH@[23; 24) 25 PATH@23..24
26 PATH_SEGMENT@[23; 24) 26 PATH_SEGMENT@23..24
27 NAME_REF@[23; 24) 27 NAME_REF@23..24
28 IDENT@[23; 24) "f" 28 IDENT@23..24 "f"
29 EXPR_STMT@[24; 25) 29 EXPR_STMT@24..25
30 ERROR@[24; 25) 30 ERROR@24..25
31 COLON@[24; 25) ":" 31 COLON@24..25 ":"
32 WHITESPACE@[25; 26) " " 32 WHITESPACE@25..26 " "
33 PATH_EXPR@[26; 29) 33 PATH_EXPR@26..29
34 PATH@[26; 29) 34 PATH@26..29
35 PATH_SEGMENT@[26; 29) 35 PATH_SEGMENT@26..29
36 NAME_REF@[26; 29) 36 NAME_REF@26..29
37 IDENT@[26; 29) "u32" 37 IDENT@26..29 "u32"
38 WHITESPACE@[29; 30) "\n" 38 WHITESPACE@29..30 "\n"
39 R_CURLY@[30; 31) "}" 39 R_CURLY@30..31 "}"
40 WHITESPACE@[31; 33) "\n\n" 40 WHITESPACE@31..33 "\n\n"
41 STRUCT_DEF@[33; 42) 41 STRUCT_DEF@33..42
42 STRUCT_KW@[33; 39) "struct" 42 STRUCT_KW@33..39 "struct"
43 WHITESPACE@[39; 40) " " 43 WHITESPACE@39..40 " "
44 NAME@[40; 41) 44 NAME@40..41
45 IDENT@[40; 41) "T" 45 IDENT@40..41 "T"
46 SEMICOLON@[41; 42) ";" 46 SEMICOLON@41..42 ";"
47 WHITESPACE@[42; 43) "\n" 47 WHITESPACE@42..43 "\n"
48error [9; 9): expected type parameter 48error 9..9: expected type parameter
49error [11; 11): expected COMMA 49error 11..11: expected COMMA
50error [11; 11): expected R_ANGLE 50error 11..11: expected R_ANGLE
51error [11; 11): expected `;`, `{`, or `(` 51error 11..11: expected `;`, `{`, or `(`
52error [12; 12): expected an item 52error 12..12: expected an item
53error [14; 14): expected an item 53error 14..14: expected an item
54error [15; 15): expected an item 54error 15..15: expected an item
55error [17; 17): expected an item 55error 17..17: expected an item
56error [24; 24): expected SEMICOLON 56error 24..24: expected SEMICOLON
57error [24; 24): expected expression 57error 24..24: expected expression
58error [25; 25): expected SEMICOLON 58error 25..25: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0010_unsafe_lambda_block.rast b/crates/ra_syntax/test_data/parser/err/0010_unsafe_lambda_block.rast
index 5559c3297..e10bb8174 100644
--- a/crates/ra_syntax/test_data/parser/err/0010_unsafe_lambda_block.rast
+++ b/crates/ra_syntax/test_data/parser/err/0010_unsafe_lambda_block.rast
@@ -1,45 +1,45 @@
1SOURCE_FILE@[0; 42) 1SOURCE_FILE@0..42
2 FN_DEF@[0; 41) 2 FN_DEF@0..41
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 7) 5 NAME@3..7
6 IDENT@[3; 7) "main" 6 IDENT@3..7 "main"
7 PARAM_LIST@[7; 9) 7 PARAM_LIST@7..9
8 L_PAREN@[7; 8) "(" 8 L_PAREN@7..8 "("
9 R_PAREN@[8; 9) ")" 9 R_PAREN@8..9 ")"
10 WHITESPACE@[9; 10) " " 10 WHITESPACE@9..10 " "
11 BLOCK_EXPR@[10; 41) 11 BLOCK_EXPR@10..41
12 BLOCK@[10; 41) 12 BLOCK@10..41
13 L_CURLY@[10; 11) "{" 13 L_CURLY@10..11 "{"
14 WHITESPACE@[11; 16) "\n " 14 WHITESPACE@11..16 "\n "
15 EXPR_STMT@[16; 24) 15 EXPR_STMT@16..24
16 LAMBDA_EXPR@[16; 24) 16 LAMBDA_EXPR@16..24
17 PARAM_LIST@[16; 18) 17 PARAM_LIST@16..18
18 PIPE@[16; 17) "|" 18 PIPE@16..17 "|"
19 PIPE@[17; 18) "|" 19 PIPE@17..18 "|"
20 WHITESPACE@[18; 19) " " 20 WHITESPACE@18..19 " "
21 RET_TYPE@[19; 24) 21 RET_TYPE@19..24
22 THIN_ARROW@[19; 21) "->" 22 THIN_ARROW@19..21 "->"
23 WHITESPACE@[21; 22) " " 23 WHITESPACE@21..22 " "
24 TUPLE_TYPE@[22; 24) 24 TUPLE_TYPE@22..24
25 L_PAREN@[22; 23) "(" 25 L_PAREN@22..23 "("
26 R_PAREN@[23; 24) ")" 26 R_PAREN@23..24 ")"
27 WHITESPACE@[24; 25) " " 27 WHITESPACE@24..25 " "
28 EXPR_STMT@[25; 39) 28 EXPR_STMT@25..39
29 BLOCK_EXPR@[25; 38) 29 BLOCK_EXPR@25..38
30 UNSAFE_KW@[25; 31) "unsafe" 30 UNSAFE_KW@25..31 "unsafe"
31 WHITESPACE@[31; 32) " " 31 WHITESPACE@31..32 " "
32 BLOCK@[32; 38) 32 BLOCK@32..38
33 L_CURLY@[32; 33) "{" 33 L_CURLY@32..33 "{"
34 WHITESPACE@[33; 34) " " 34 WHITESPACE@33..34 " "
35 TUPLE_EXPR@[34; 36) 35 TUPLE_EXPR@34..36
36 L_PAREN@[34; 35) "(" 36 L_PAREN@34..35 "("
37 R_PAREN@[35; 36) ")" 37 R_PAREN@35..36 ")"
38 WHITESPACE@[36; 37) " " 38 WHITESPACE@36..37 " "
39 R_CURLY@[37; 38) "}" 39 R_CURLY@37..38 "}"
40 SEMICOLON@[38; 39) ";" 40 SEMICOLON@38..39 ";"
41 WHITESPACE@[39; 40) "\n" 41 WHITESPACE@39..40 "\n"
42 R_CURLY@[40; 41) "}" 42 R_CURLY@40..41 "}"
43 WHITESPACE@[41; 42) "\n" 43 WHITESPACE@41..42 "\n"
44error [24; 24): expected `{` 44error 24..24: expected `{`
45error [24; 24): expected SEMICOLON 45error 24..24: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0011_extern_struct.rast b/crates/ra_syntax/test_data/parser/err/0011_extern_struct.rast
index 99c212fd6..87c54c32c 100644
--- a/crates/ra_syntax/test_data/parser/err/0011_extern_struct.rast
+++ b/crates/ra_syntax/test_data/parser/err/0011_extern_struct.rast
@@ -1,13 +1,13 @@
1SOURCE_FILE@[0; 19) 1SOURCE_FILE@0..19
2 ERROR@[0; 6) 2 ERROR@0..6
3 ABI@[0; 6) 3 ABI@0..6
4 EXTERN_KW@[0; 6) "extern" 4 EXTERN_KW@0..6 "extern"
5 WHITESPACE@[6; 7) " " 5 WHITESPACE@6..7 " "
6 STRUCT_DEF@[7; 18) 6 STRUCT_DEF@7..18
7 STRUCT_KW@[7; 13) "struct" 7 STRUCT_KW@7..13 "struct"
8 WHITESPACE@[13; 14) " " 8 WHITESPACE@13..14 " "
9 NAME@[14; 17) 9 NAME@14..17
10 IDENT@[14; 17) "Foo" 10 IDENT@14..17 "Foo"
11 SEMICOLON@[17; 18) ";" 11 SEMICOLON@17..18 ";"
12 WHITESPACE@[18; 19) "\n" 12 WHITESPACE@18..19 "\n"
13error [6; 6): expected existential, fn, trait or impl 13error 6..6: expected existential, fn, trait or impl
diff --git a/crates/ra_syntax/test_data/parser/err/0012_broken_lambda.rast b/crates/ra_syntax/test_data/parser/err/0012_broken_lambda.rast
index 0a3c0313d..e1e782f5f 100644
--- a/crates/ra_syntax/test_data/parser/err/0012_broken_lambda.rast
+++ b/crates/ra_syntax/test_data/parser/err/0012_broken_lambda.rast
@@ -1,387 +1,387 @@
1SOURCE_FILE@[0; 389) 1SOURCE_FILE@0..389
2 FN_DEF@[0; 389) 2 FN_DEF@0..389
3 VISIBILITY@[0; 10) 3 VISIBILITY@0..10
4 PUB_KW@[0; 3) 4 PUB_KW@0..3
5 L_PAREN@[3; 4) 5 L_PAREN@3..4
6 SUPER_KW@[4; 9) 6 SUPER_KW@4..9
7 R_PAREN@[9; 10) 7 R_PAREN@9..10
8 WHITESPACE@[10; 11) 8 WHITESPACE@10..11
9 FN_KW@[11; 13) 9 FN_KW@11..13
10 WHITESPACE@[13; 14) 10 WHITESPACE@13..14
11 NAME@[14; 21) 11 NAME@14..21
12 IDENT@[14; 21) "process" 12 IDENT@14..21 "process"
13 TYPE_PARAM_LIST@[21; 38) 13 TYPE_PARAM_LIST@21..38
14 L_ANGLE@[21; 22) 14 L_ANGLE@21..22
15 LIFETIME_PARAM@[22; 24) 15 LIFETIME_PARAM@22..24
16 LIFETIME@[22; 24) "'a" 16 LIFETIME@22..24 "'a"
17 COMMA@[24; 25) 17 COMMA@24..25
18 WHITESPACE@[25; 26) 18 WHITESPACE@25..26
19 TYPE_PARAM@[26; 37) 19 TYPE_PARAM@26..37
20 NAME@[26; 27) 20 NAME@26..27
21 IDENT@[26; 27) "S" 21 IDENT@26..27 "S"
22 COLON@[27; 28) 22 COLON@27..28
23 WHITESPACE@[28; 29) 23 WHITESPACE@28..29
24 PATH@[29; 37) 24 PATH@29..37
25 PATH_SEGMENT@[29; 37) 25 PATH_SEGMENT@29..37
26 NAME_REF@[29; 33) 26 NAME_REF@29..33
27 IDENT@[29; 33) "Sink" 27 IDENT@29..33 "Sink"
28 TYPE_ARG_LIST@[33; 37) 28 TYPE_ARG_LIST@33..37
29 L_ANGLE@[33; 34) 29 L_ANGLE@33..34
30 LIFETIME_ARG@[34; 36) 30 LIFETIME_ARG@34..36
31 LIFETIME@[34; 36) "'a" 31 LIFETIME@34..36 "'a"
32 R_ANGLE@[36; 37) 32 R_ANGLE@36..37
33 R_ANGLE@[37; 38) 33 R_ANGLE@37..38
34 PARAM_LIST@[38; 93) 34 PARAM_LIST@38..93
35 L_PAREN@[38; 39) 35 L_PAREN@38..39
36 PARAM@[39; 54) 36 PARAM@39..54
37 BIND_PAT@[39; 46) 37 BIND_PAT@39..46
38 NAME@[39; 46) 38 NAME@39..46
39 IDENT@[39; 46) "builder" 39 IDENT@39..46 "builder"
40 COLON@[46; 47) 40 COLON@46..47
41 WHITESPACE@[47; 48) 41 WHITESPACE@47..48
42 REFERENCE_TYPE@[48; 54) 42 REFERENCE_TYPE@48..54
43 AMP@[48; 49) 43 AMP@48..49
44 MUT_KW@[49; 52) 44 MUT_KW@49..52
45 WHITESPACE@[52; 53) 45 WHITESPACE@52..53
46 PATH_TYPE@[53; 54) 46 PATH_TYPE@53..54
47 PATH@[53; 54) 47 PATH@53..54
48 PATH_SEGMENT@[53; 54) 48 PATH_SEGMENT@53..54
49 NAME_REF@[53; 54) 49 NAME_REF@53..54
50 IDENT@[53; 54) "S" 50 IDENT@53..54 "S"
51 COMMA@[54; 55) 51 COMMA@54..55
52 WHITESPACE@[55; 56) 52 WHITESPACE@55..56
53 PARAM@[56; 72) 53 PARAM@56..72
54 BIND_PAT@[56; 62) 54 BIND_PAT@56..62
55 NAME@[56; 62) 55 NAME@56..62
56 IDENT@[56; 62) "tokens" 56 IDENT@56..62 "tokens"
57 COLON@[62; 63) 57 COLON@62..63
58 WHITESPACE@[63; 64) 58 WHITESPACE@63..64
59 REFERENCE_TYPE@[64; 72) 59 REFERENCE_TYPE@64..72
60 AMP@[64; 65) 60 AMP@64..65
61 SLICE_TYPE@[65; 72) 61 SLICE_TYPE@65..72
62 L_BRACK@[65; 66) 62 L_BRACK@65..66
63 PATH_TYPE@[66; 71) 63 PATH_TYPE@66..71
64 PATH@[66; 71) 64 PATH@66..71
65 PATH_SEGMENT@[66; 71) 65 PATH_SEGMENT@66..71
66 NAME_REF@[66; 71) 66 NAME_REF@66..71
67 IDENT@[66; 71) "Token" 67 IDENT@66..71 "Token"
68 R_BRACK@[71; 72) 68 R_BRACK@71..72
69 COMMA@[72; 73) 69 COMMA@72..73
70 WHITESPACE@[73; 74) 70 WHITESPACE@73..74
71 PARAM@[74; 92) 71 PARAM@74..92
72 BIND_PAT@[74; 80) 72 BIND_PAT@74..80
73 NAME@[74; 80) 73 NAME@74..80
74 IDENT@[74; 80) "events" 74 IDENT@74..80 "events"
75 COLON@[80; 81) 75 COLON@80..81
76 WHITESPACE@[81; 82) 76 WHITESPACE@81..82
77 PATH_TYPE@[82; 92) 77 PATH_TYPE@82..92
78 PATH@[82; 92) 78 PATH@82..92
79 PATH_SEGMENT@[82; 92) 79 PATH_SEGMENT@82..92
80 NAME_REF@[82; 85) 80 NAME_REF@82..85
81 IDENT@[82; 85) "Vec" 81 IDENT@82..85 "Vec"
82 TYPE_ARG_LIST@[85; 92) 82 TYPE_ARG_LIST@85..92
83 L_ANGLE@[85; 86) 83 L_ANGLE@85..86
84 TYPE_ARG@[86; 91) 84 TYPE_ARG@86..91
85 PATH_TYPE@[86; 91) 85 PATH_TYPE@86..91
86 PATH@[86; 91) 86 PATH@86..91
87 PATH_SEGMENT@[86; 91) 87 PATH_SEGMENT@86..91
88 NAME_REF@[86; 91) 88 NAME_REF@86..91
89 IDENT@[86; 91) "Event" 89 IDENT@86..91 "Event"
90 R_ANGLE@[91; 92) 90 R_ANGLE@91..92
91 R_PAREN@[92; 93) 91 R_PAREN@92..93
92 WHITESPACE@[93; 94) 92 WHITESPACE@93..94
93 BLOCK_EXPR@[94; 389) 93 BLOCK_EXPR@94..389
94 L_CURLY@[94; 95) 94 L_CURLY@94..95
95 WHITESPACE@[95; 100) 95 WHITESPACE@95..100
96 LET_STMT@[100; 125) 96 LET_STMT@100..125
97 LET_KW@[100; 103) 97 LET_KW@100..103
98 WHITESPACE@[103; 104) 98 WHITESPACE@103..104
99 BIND_PAT@[104; 120) 99 BIND_PAT@104..120
100 MUT_KW@[104; 107) 100 MUT_KW@104..107
101 WHITESPACE@[107; 108) 101 WHITESPACE@107..108
102 NAME@[108; 120) 102 NAME@108..120
103 IDENT@[108; 120) "next_tok_idx" 103 IDENT@108..120 "next_tok_idx"
104 WHITESPACE@[120; 121) 104 WHITESPACE@120..121
105 EQ@[121; 122) 105 EQ@121..122
106 WHITESPACE@[122; 123) 106 WHITESPACE@122..123
107 LITERAL@[123; 124) 107 LITERAL@123..124
108 INT_NUMBER@[123; 124) "0" 108 INT_NUMBER@123..124 "0"
109 SEMICOLON@[124; 125) 109 SEMICOLON@124..125
110 WHITESPACE@[125; 130) 110 WHITESPACE@125..130
111 LET_STMT@[130; 389) 111 LET_STMT@130..389
112 LET_KW@[130; 133) 112 LET_KW@130..133
113 WHITESPACE@[133; 134) 113 WHITESPACE@133..134
114 BIND_PAT@[134; 140) 114 BIND_PAT@134..140
115 NAME@[134; 140) 115 NAME@134..140
116 IDENT@[134; 140) "eat_ws" 116 IDENT@134..140 "eat_ws"
117 WHITESPACE@[140; 141) 117 WHITESPACE@140..141
118 EQ@[141; 142) 118 EQ@141..142
119 WHITESPACE@[142; 143) 119 WHITESPACE@142..143
120 LAMBDA_EXPR@[143; 389) 120 LAMBDA_EXPR@143..389
121 PARAM_LIST@[143; 388) 121 PARAM_LIST@143..388
122 PIPE@[143; 144) 122 PIPE@143..144
123 PARAM@[144; 159) 123 PARAM@144..159
124 BIND_PAT@[144; 147) 124 BIND_PAT@144..147
125 NAME@[144; 147) 125 NAME@144..147
126 IDENT@[144; 147) "idx" 126 IDENT@144..147 "idx"
127 COLON@[147; 148) 127 COLON@147..148
128 WHITESPACE@[148; 149) 128 WHITESPACE@148..149
129 REFERENCE_TYPE@[149; 159) 129 REFERENCE_TYPE@149..159
130 AMP@[149; 150) 130 AMP@149..150
131 MUT_KW@[150; 153) 131 MUT_KW@150..153
132 WHITESPACE@[153; 154) 132 WHITESPACE@153..154
133 PATH_TYPE@[154; 159) 133 PATH_TYPE@154..159
134 PATH@[154; 159) 134 PATH@154..159
135 PATH_SEGMENT@[154; 159) 135 PATH_SEGMENT@154..159
136 NAME_REF@[154; 159) 136 NAME_REF@154..159
137 IDENT@[154; 159) "usize" 137 IDENT@154..159 "usize"
138 COMMA@[159; 160) 138 COMMA@159..160
139 WHITESPACE@[160; 161) 139 WHITESPACE@160..161
140 PARAM@[161; 167) 140 PARAM@161..167
141 REF_PAT@[161; 167) 141 REF_PAT@161..167
142 AMP@[161; 162) 142 AMP@161..162
143 MUT_KW@[162; 165) 143 MUT_KW@162..165
144 WHITESPACE@[165; 166) 144 WHITESPACE@165..166
145 err: `expected pattern` 145 err: `expected pattern`
146 ERROR@[166; 167) 146 ERROR@166..167
147 PIPE@[166; 167) 147 PIPE@166..167
148 err: `expected COMMA` 148 err: `expected COMMA`
149 WHITESPACE@[167; 168) 149 WHITESPACE@167..168
150 err: `expected pattern` 150 err: `expected pattern`
151 PARAM@[168; 169) 151 PARAM@168..169
152 ERROR@[168; 169) 152 ERROR@168..169
153 L_CURLY@[168; 169) 153 L_CURLY@168..169
154 err: `expected COMMA` 154 err: `expected COMMA`
155 WHITESPACE@[169; 178) 155 WHITESPACE@169..178
156 err: `expected pattern` 156 err: `expected pattern`
157 PARAM@[178; 183) 157 PARAM@178..183
158 ERROR@[178; 183) 158 ERROR@178..183
159 WHILE_KW@[178; 183) 159 WHILE_KW@178..183
160 err: `expected COMMA` 160 err: `expected COMMA`
161 WHITESPACE@[183; 184) 161 WHITESPACE@183..184
162 err: `expected pattern` 162 err: `expected pattern`
163 PARAM@[184; 187) 163 PARAM@184..187
164 ERROR@[184; 187) 164 ERROR@184..187
165 LET_KW@[184; 187) 165 LET_KW@184..187
166 err: `expected COMMA` 166 err: `expected COMMA`
167 WHITESPACE@[187; 188) 167 WHITESPACE@187..188
168 PARAM@[188; 199) 168 PARAM@188..199
169 TUPLE_STRUCT_PAT@[188; 199) 169 TUPLE_STRUCT_PAT@188..199
170 PATH@[188; 192) 170 PATH@188..192
171 PATH_SEGMENT@[188; 192) 171 PATH_SEGMENT@188..192
172 NAME_REF@[188; 192) 172 NAME_REF@188..192
173 IDENT@[188; 192) "Some" 173 IDENT@188..192 "Some"
174 L_PAREN@[192; 193) 174 L_PAREN@192..193
175 BIND_PAT@[193; 198) 175 BIND_PAT@193..198
176 NAME@[193; 198) 176 NAME@193..198
177 IDENT@[193; 198) "token" 177 IDENT@193..198 "token"
178 R_PAREN@[198; 199) 178 R_PAREN@198..199
179 err: `expected COMMA` 179 err: `expected COMMA`
180 WHITESPACE@[199; 200) 180 WHITESPACE@199..200
181 err: `expected pattern` 181 err: `expected pattern`
182 PARAM@[200; 201) 182 PARAM@200..201
183 ERROR@[200; 201) 183 ERROR@200..201
184 EQ@[200; 201) 184 EQ@200..201
185 err: `expected COMMA` 185 err: `expected COMMA`
186 WHITESPACE@[201; 202) 186 WHITESPACE@201..202
187 PARAM@[202; 208) 187 PARAM@202..208
188 BIND_PAT@[202; 208) 188 BIND_PAT@202..208
189 NAME@[202; 208) 189 NAME@202..208
190 IDENT@[202; 208) "tokens" 190 IDENT@202..208 "tokens"
191 err: `expected COMMA` 191 err: `expected COMMA`
192 err: `expected pattern` 192 err: `expected pattern`
193 PARAM@[208; 209) 193 PARAM@208..209
194 ERROR@[208; 209) 194 ERROR@208..209
195 DOT@[208; 209) 195 DOT@208..209
196 err: `expected COMMA` 196 err: `expected COMMA`
197 PARAM@[209; 218) 197 PARAM@209..218
198 TUPLE_STRUCT_PAT@[209; 218) 198 TUPLE_STRUCT_PAT@209..218
199 PATH@[209; 212) 199 PATH@209..212
200 PATH_SEGMENT@[209; 212) 200 PATH_SEGMENT@209..212
201 NAME_REF@[209; 212) 201 NAME_REF@209..212
202 IDENT@[209; 212) "get" 202 IDENT@209..212 "get"
203 L_PAREN@[212; 213) 203 L_PAREN@212..213
204 err: `expected pattern` 204 err: `expected pattern`
205 ERROR@[213; 214) 205 ERROR@213..214
206 STAR@[213; 214) 206 STAR@213..214
207 err: `expected COMMA` 207 err: `expected COMMA`
208 BIND_PAT@[214; 217) 208 BIND_PAT@214..217
209 NAME@[214; 217) 209 NAME@214..217
210 IDENT@[214; 217) "idx" 210 IDENT@214..217 "idx"
211 R_PAREN@[217; 218) 211 R_PAREN@217..218
212 err: `expected COMMA` 212 err: `expected COMMA`
213 WHITESPACE@[218; 219) 213 WHITESPACE@218..219
214 err: `expected pattern` 214 err: `expected pattern`
215 PARAM@[219; 220) 215 PARAM@219..220
216 ERROR@[219; 220) 216 ERROR@219..220
217 L_CURLY@[219; 220) 217 L_CURLY@219..220
218 err: `expected COMMA` 218 err: `expected COMMA`
219 WHITESPACE@[220; 233) 219 WHITESPACE@220..233
220 err: `expected pattern` 220 err: `expected pattern`
221 PARAM@[233; 235) 221 PARAM@233..235
222 ERROR@[233; 235) 222 ERROR@233..235
223 IF_KW@[233; 235) 223 IF_KW@233..235
224 err: `expected COMMA` 224 err: `expected COMMA`
225 WHITESPACE@[235; 236) 225 WHITESPACE@235..236
226 err: `expected pattern` 226 err: `expected pattern`
227 PARAM@[236; 237) 227 PARAM@236..237
228 ERROR@[236; 237) 228 ERROR@236..237
229 BANG@[236; 237) 229 BANG@236..237
230 err: `expected COMMA` 230 err: `expected COMMA`
231 PARAM@[237; 242) 231 PARAM@237..242
232 BIND_PAT@[237; 242) 232 BIND_PAT@237..242
233 NAME@[237; 242) 233 NAME@237..242
234 IDENT@[237; 242) "token" 234 IDENT@237..242 "token"
235 err: `expected COMMA` 235 err: `expected COMMA`
236 err: `expected pattern` 236 err: `expected pattern`
237 PARAM@[242; 243) 237 PARAM@242..243
238 ERROR@[242; 243) 238 ERROR@242..243
239 DOT@[242; 243) 239 DOT@242..243
240 err: `expected COMMA` 240 err: `expected COMMA`
241 PARAM@[243; 247) 241 PARAM@243..247
242 BIND_PAT@[243; 247) 242 BIND_PAT@243..247
243 NAME@[243; 247) 243 NAME@243..247
244 IDENT@[243; 247) "kind" 244 IDENT@243..247 "kind"
245 err: `expected COMMA` 245 err: `expected COMMA`
246 err: `expected pattern` 246 err: `expected pattern`
247 PARAM@[247; 248) 247 PARAM@247..248
248 ERROR@[247; 248) 248 ERROR@247..248
249 DOT@[247; 248) 249 DOT@247..248
250 err: `expected COMMA` 250 err: `expected COMMA`
251 PARAM@[248; 259) 251 PARAM@248..259
252 TUPLE_STRUCT_PAT@[248; 259) 252 TUPLE_STRUCT_PAT@248..259
253 PATH@[248; 257) 253 PATH@248..257
254 PATH_SEGMENT@[248; 257) 254 PATH_SEGMENT@248..257
255 NAME_REF@[248; 257) 255 NAME_REF@248..257
256 IDENT@[248; 257) "is_trivia" 256 IDENT@248..257 "is_trivia"
257 L_PAREN@[257; 258) 257 L_PAREN@257..258
258 R_PAREN@[258; 259) 258 R_PAREN@258..259
259 err: `expected COMMA` 259 err: `expected COMMA`
260 WHITESPACE@[259; 260) 260 WHITESPACE@259..260
261 err: `expected pattern` 261 err: `expected pattern`
262 PARAM@[260; 261) 262 PARAM@260..261
263 ERROR@[260; 261) 263 ERROR@260..261
264 L_CURLY@[260; 261) 264 L_CURLY@260..261
265 err: `expected COMMA` 265 err: `expected COMMA`
266 WHITESPACE@[261; 278) 266 WHITESPACE@261..278
267 PARAM@[278; 283) 267 PARAM@278..283
268 BIND_PAT@[278; 283) 268 BIND_PAT@278..283
269 NAME@[278; 283) 269 NAME@278..283
270 IDENT@[278; 283) "break" 270 IDENT@278..283 "break"
271 err: `expected COMMA` 271 err: `expected COMMA`
272 err: `expected pattern` 272 err: `expected pattern`
273 PARAM@[283; 284) 273 PARAM@283..284
274 ERROR@[283; 284) 274 ERROR@283..284
275 SEMICOLON@[283; 284) 275 SEMICOLON@283..284
276 err: `expected COMMA` 276 err: `expected COMMA`
277 WHITESPACE@[284; 297) 277 WHITESPACE@284..297
278 err: `expected pattern` 278 err: `expected pattern`
279 PARAM@[297; 298) 279 PARAM@297..298
280 ERROR@[297; 298) 280 ERROR@297..298
281 R_CURLY@[297; 298) 281 R_CURLY@297..298
282 err: `expected COMMA` 282 err: `expected COMMA`
283 WHITESPACE@[298; 311) 283 WHITESPACE@298..311
284 PARAM@[311; 318) 284 PARAM@311..318
285 BIND_PAT@[311; 318) 285 BIND_PAT@311..318
286 NAME@[311; 318) 286 NAME@311..318
287 IDENT@[311; 318) "builder" 287 IDENT@311..318 "builder"
288 err: `expected COMMA` 288 err: `expected COMMA`
289 err: `expected pattern` 289 err: `expected pattern`
290 PARAM@[318; 319) 290 PARAM@318..319
291 ERROR@[318; 319) 291 ERROR@318..319
292 DOT@[318; 319) 292 DOT@318..319
293 err: `expected COMMA` 293 err: `expected COMMA`
294 PARAM@[319; 346) 294 PARAM@319..346
295 TUPLE_STRUCT_PAT@[319; 346) 295 TUPLE_STRUCT_PAT@319..346
296 PATH@[319; 323) 296 PATH@319..323
297 PATH_SEGMENT@[319; 323) 297 PATH_SEGMENT@319..323
298 NAME_REF@[319; 323) 298 NAME_REF@319..323
299 IDENT@[319; 323) "leaf" 299 IDENT@319..323 "leaf"
300 L_PAREN@[323; 324) 300 L_PAREN@323..324
301 BIND_PAT@[324; 329) 301 BIND_PAT@324..329
302 NAME@[324; 329) 302 NAME@324..329
303 IDENT@[324; 329) "token" 303 IDENT@324..329 "token"
304 err: `expected COMMA` 304 err: `expected COMMA`
305 err: `expected pattern` 305 err: `expected pattern`
306 ERROR@[329; 330) 306 ERROR@329..330
307 DOT@[329; 330) 307 DOT@329..330
308 err: `expected COMMA` 308 err: `expected COMMA`
309 BIND_PAT@[330; 334) 309 BIND_PAT@330..334
310 NAME@[330; 334) 310 NAME@330..334
311 IDENT@[330; 334) "kind" 311 IDENT@330..334 "kind"
312 COMMA@[334; 335) 312 COMMA@334..335
313 WHITESPACE@[335; 336) 313 WHITESPACE@335..336
314 BIND_PAT@[336; 341) 314 BIND_PAT@336..341
315 NAME@[336; 341) 315 NAME@336..341
316 IDENT@[336; 341) "token" 316 IDENT@336..341 "token"
317 err: `expected COMMA` 317 err: `expected COMMA`
318 err: `expected pattern` 318 err: `expected pattern`
319 ERROR@[341; 342) 319 ERROR@341..342
320 DOT@[341; 342) 320 DOT@341..342
321 err: `expected COMMA` 321 err: `expected COMMA`
322 BIND_PAT@[342; 345) 322 BIND_PAT@342..345
323 NAME@[342; 345) 323 NAME@342..345
324 IDENT@[342; 345) "len" 324 IDENT@342..345 "len"
325 R_PAREN@[345; 346) 325 R_PAREN@345..346
326 err: `expected COMMA` 326 err: `expected COMMA`
327 err: `expected pattern` 327 err: `expected pattern`
328 PARAM@[346; 347) 328 PARAM@346..347
329 ERROR@[346; 347) 329 ERROR@346..347
330 SEMICOLON@[346; 347) 330 SEMICOLON@346..347
331 err: `expected COMMA` 331 err: `expected COMMA`
332 WHITESPACE@[347; 360) 332 WHITESPACE@347..360
333 err: `expected pattern` 333 err: `expected pattern`
334 PARAM@[360; 361) 334 PARAM@360..361
335 ERROR@[360; 361) 335 ERROR@360..361
336 STAR@[360; 361) 336 STAR@360..361
337 err: `expected COMMA` 337 err: `expected COMMA`
338 PARAM@[361; 364) 338 PARAM@361..364
339 BIND_PAT@[361; 364) 339 BIND_PAT@361..364
340 NAME@[361; 364) 340 NAME@361..364
341 IDENT@[361; 364) "idx" 341 IDENT@361..364 "idx"
342 err: `expected COMMA` 342 err: `expected COMMA`
343 WHITESPACE@[364; 365) 343 WHITESPACE@364..365
344 err: `expected pattern` 344 err: `expected pattern`
345 PARAM@[365; 366) 345 PARAM@365..366
346 ERROR@[365; 366) 346 ERROR@365..366
347 PLUS@[365; 366) 347 PLUS@365..366
348 err: `expected COMMA` 348 err: `expected COMMA`
349 err: `expected pattern` 349 err: `expected pattern`
350 PARAM@[366; 367) 350 PARAM@366..367
351 ERROR@[366; 367) 351 ERROR@366..367
352 EQ@[366; 367) 352 EQ@366..367
353 err: `expected COMMA` 353 err: `expected COMMA`
354 WHITESPACE@[367; 368) 354 WHITESPACE@367..368
355 PARAM@[368; 369) 355 PARAM@368..369
356 LITERAL@[368; 369) 356 LITERAL@368..369
357 INT_NUMBER@[368; 369) "1" 357 INT_NUMBER@368..369 "1"
358 err: `expected COMMA` 358 err: `expected COMMA`
359 WHITESPACE@[369; 378) 359 WHITESPACE@369..378
360 err: `expected pattern` 360 err: `expected pattern`
361 PARAM@[378; 379) 361 PARAM@378..379
362 ERROR@[378; 379) 362 ERROR@378..379
363 R_CURLY@[378; 379) 363 R_CURLY@378..379
364 err: `expected COMMA` 364 err: `expected COMMA`
365 WHITESPACE@[379; 384) 365 WHITESPACE@379..384
366 err: `expected pattern` 366 err: `expected pattern`
367 PARAM@[384; 385) 367 PARAM@384..385
368 ERROR@[384; 385) 368 ERROR@384..385
369 R_CURLY@[384; 385) 369 R_CURLY@384..385
370 err: `expected COMMA` 370 err: `expected COMMA`
371 err: `expected pattern` 371 err: `expected pattern`
372 PARAM@[385; 386) 372 PARAM@385..386
373 ERROR@[385; 386) 373 ERROR@385..386
374 SEMICOLON@[385; 386) 374 SEMICOLON@385..386
375 err: `expected COMMA` 375 err: `expected COMMA`
376 WHITESPACE@[386; 387) 376 WHITESPACE@386..387
377 err: `expected pattern` 377 err: `expected pattern`
378 PARAM@[387; 388) 378 PARAM@387..388
379 ERROR@[387; 388) 379 ERROR@387..388
380 R_CURLY@[387; 388) 380 R_CURLY@387..388
381 err: `expected COMMA` 381 err: `expected COMMA`
382 err: `expected PIPE` 382 err: `expected PIPE`
383 WHITESPACE@[388; 389) 383 WHITESPACE@388..389
384 err: `expected expression` 384 err: `expected expression`
385 err: `expected SEMI` 385 err: `expected SEMI`
386 err: `expected R_CURLY` 386 err: `expected R_CURLY`
387 ERROR@[389; 389) 387 ERROR@389..389
diff --git a/crates/ra_syntax/test_data/parser/err/0013_invalid_type.rast b/crates/ra_syntax/test_data/parser/err/0013_invalid_type.rast
index cb570dc1c..211e5fd46 100644
--- a/crates/ra_syntax/test_data/parser/err/0013_invalid_type.rast
+++ b/crates/ra_syntax/test_data/parser/err/0013_invalid_type.rast
@@ -1,89 +1,89 @@
1SOURCE_FILE@[0; 86) 1SOURCE_FILE@0..86
2 STRUCT_DEF@[0; 72) 2 STRUCT_DEF@0..72
3 VISIBILITY@[0; 3) 3 VISIBILITY@0..3
4 PUB_KW@[0; 3) "pub" 4 PUB_KW@0..3 "pub"
5 WHITESPACE@[3; 4) " " 5 WHITESPACE@3..4 " "
6 STRUCT_KW@[4; 10) "struct" 6 STRUCT_KW@4..10 "struct"
7 WHITESPACE@[10; 11) " " 7 WHITESPACE@10..11 " "
8 NAME@[11; 16) 8 NAME@11..16
9 IDENT@[11; 16) "Cache" 9 IDENT@11..16 "Cache"
10 TUPLE_FIELD_DEF_LIST@[16; 72) 10 TUPLE_FIELD_DEF_LIST@16..72
11 L_PAREN@[16; 17) "(" 11 L_PAREN@16..17 "("
12 WHITESPACE@[17; 22) "\n " 12 WHITESPACE@17..22 "\n "
13 TUPLE_FIELD_DEF@[22; 68) 13 TUPLE_FIELD_DEF@22..68
14 PATH_TYPE@[22; 68) 14 PATH_TYPE@22..68
15 PATH@[22; 68) 15 PATH@22..68
16 PATH_SEGMENT@[22; 68) 16 PATH_SEGMENT@22..68
17 NAME_REF@[22; 29) 17 NAME_REF@22..29
18 IDENT@[22; 29) "RefCell" 18 IDENT@22..29 "RefCell"
19 TYPE_ARG_LIST@[29; 68) 19 TYPE_ARG_LIST@29..68
20 L_ANGLE@[29; 30) "<" 20 L_ANGLE@29..30 "<"
21 TYPE_ARG@[30; 68) 21 TYPE_ARG@30..68
22 PATH_TYPE@[30; 68) 22 PATH_TYPE@30..68
23 PATH@[30; 68) 23 PATH@30..68
24 PATH_SEGMENT@[30; 68) 24 PATH_SEGMENT@30..68
25 NAME_REF@[30; 37) 25 NAME_REF@30..37
26 IDENT@[30; 37) "HashMap" 26 IDENT@30..37 "HashMap"
27 TYPE_ARG_LIST@[37; 68) 27 TYPE_ARG_LIST@37..68
28 L_ANGLE@[37; 38) "<" 28 L_ANGLE@37..38 "<"
29 WHITESPACE@[38; 47) "\n " 29 WHITESPACE@38..47 "\n "
30 TYPE_ARG@[47; 53) 30 TYPE_ARG@47..53
31 PATH_TYPE@[47; 53) 31 PATH_TYPE@47..53
32 PATH@[47; 53) 32 PATH@47..53
33 PATH_SEGMENT@[47; 53) 33 PATH_SEGMENT@47..53
34 NAME_REF@[47; 53) 34 NAME_REF@47..53
35 IDENT@[47; 53) "TypeId" 35 IDENT@47..53 "TypeId"
36 COMMA@[53; 54) "," 36 COMMA@53..54 ","
37 WHITESPACE@[54; 63) "\n " 37 WHITESPACE@54..63 "\n "
38 TYPE_ARG@[63; 68) 38 TYPE_ARG@63..68
39 PATH_TYPE@[63; 68) 39 PATH_TYPE@63..68
40 PATH@[63; 68) 40 PATH@63..68
41 PATH_SEGMENT@[63; 68) 41 PATH_SEGMENT@63..68
42 NAME_REF@[63; 66) 42 NAME_REF@63..66
43 IDENT@[63; 66) "Box" 43 IDENT@63..66 "Box"
44 TYPE_ARG_LIST@[66; 68) 44 TYPE_ARG_LIST@66..68
45 L_ANGLE@[66; 67) "<" 45 L_ANGLE@66..67 "<"
46 TYPE_ARG@[67; 68) 46 TYPE_ARG@67..68
47 ERROR@[67; 68) 47 ERROR@67..68
48 AT@[67; 68) "@" 48 AT@67..68 "@"
49 WHITESPACE@[68; 69) " " 49 WHITESPACE@68..69 " "
50 TUPLE_FIELD_DEF@[69; 72) 50 TUPLE_FIELD_DEF@69..72
51 PATH_TYPE@[69; 72) 51 PATH_TYPE@69..72
52 PATH@[69; 72) 52 PATH@69..72
53 PATH_SEGMENT@[69; 72) 53 PATH_SEGMENT@69..72
54 NAME_REF@[69; 72) 54 NAME_REF@69..72
55 IDENT@[69; 72) "Any" 55 IDENT@69..72 "Any"
56 ERROR@[72; 72) 56 ERROR@72..72
57 ERROR@[72; 73) 57 ERROR@72..73
58 R_ANGLE@[72; 73) ">" 58 R_ANGLE@72..73 ">"
59 ERROR@[73; 74) 59 ERROR@73..74
60 COMMA@[73; 74) "," 60 COMMA@73..74 ","
61 WHITESPACE@[74; 79) "\n " 61 WHITESPACE@74..79 "\n "
62 ERROR@[79; 80) 62 ERROR@79..80
63 R_ANGLE@[79; 80) ">" 63 R_ANGLE@79..80 ">"
64 ERROR@[80; 81) 64 ERROR@80..81
65 R_ANGLE@[80; 81) ">" 65 R_ANGLE@80..81 ">"
66 WHITESPACE@[81; 82) "\n" 66 WHITESPACE@81..82 "\n"
67 ERROR@[82; 83) 67 ERROR@82..83
68 R_PAREN@[82; 83) ")" 68 R_PAREN@82..83 ")"
69 ERROR@[83; 84) 69 ERROR@83..84
70 SEMICOLON@[83; 84) ";" 70 SEMICOLON@83..84 ";"
71 WHITESPACE@[84; 86) "\n\n" 71 WHITESPACE@84..86 "\n\n"
72error [67; 67): expected type 72error 67..67: expected type
73error [68; 68): expected COMMA 73error 68..68: expected COMMA
74error [68; 68): expected R_ANGLE 74error 68..68: expected R_ANGLE
75error [68; 68): expected COMMA 75error 68..68: expected COMMA
76error [68; 68): expected R_ANGLE 76error 68..68: expected R_ANGLE
77error [68; 68): expected COMMA 77error 68..68: expected COMMA
78error [68; 68): expected R_ANGLE 78error 68..68: expected R_ANGLE
79error [68; 68): expected COMMA 79error 68..68: expected COMMA
80error [72; 72): expected COMMA 80error 72..72: expected COMMA
81error [72; 72): expected a type 81error 72..72: expected a type
82error [72; 72): expected R_PAREN 82error 72..72: expected R_PAREN
83error [72; 72): expected SEMICOLON 83error 72..72: expected SEMICOLON
84error [72; 72): expected an item 84error 72..72: expected an item
85error [73; 73): expected an item 85error 73..73: expected an item
86error [79; 79): expected an item 86error 79..79: expected an item
87error [80; 80): expected an item 87error 80..80: expected an item
88error [82; 82): expected an item 88error 82..82: expected an item
89error [83; 83): expected an item 89error 83..83: expected an item
diff --git a/crates/ra_syntax/test_data/parser/err/0014_where_no_bounds.rast b/crates/ra_syntax/test_data/parser/err/0014_where_no_bounds.rast
index a25d641b8..61c361833 100644
--- a/crates/ra_syntax/test_data/parser/err/0014_where_no_bounds.rast
+++ b/crates/ra_syntax/test_data/parser/err/0014_where_no_bounds.rast
@@ -1,32 +1,32 @@
1SOURCE_FILE@[0; 23) 1SOURCE_FILE@0..23
2 FN_DEF@[0; 22) 2 FN_DEF@0..22
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 TYPE_PARAM_LIST@[6; 9) 7 TYPE_PARAM_LIST@6..9
8 L_ANGLE@[6; 7) "<" 8 L_ANGLE@6..7 "<"
9 TYPE_PARAM@[7; 8) 9 TYPE_PARAM@7..8
10 NAME@[7; 8) 10 NAME@7..8
11 IDENT@[7; 8) "T" 11 IDENT@7..8 "T"
12 R_ANGLE@[8; 9) ">" 12 R_ANGLE@8..9 ">"
13 PARAM_LIST@[9; 11) 13 PARAM_LIST@9..11
14 L_PAREN@[9; 10) "(" 14 L_PAREN@9..10 "("
15 R_PAREN@[10; 11) ")" 15 R_PAREN@10..11 ")"
16 WHITESPACE@[11; 12) " " 16 WHITESPACE@11..12 " "
17 WHERE_CLAUSE@[12; 19) 17 WHERE_CLAUSE@12..19
18 WHERE_KW@[12; 17) "where" 18 WHERE_KW@12..17 "where"
19 WHITESPACE@[17; 18) " " 19 WHITESPACE@17..18 " "
20 WHERE_PRED@[18; 19) 20 WHERE_PRED@18..19
21 PATH_TYPE@[18; 19) 21 PATH_TYPE@18..19
22 PATH@[18; 19) 22 PATH@18..19
23 PATH_SEGMENT@[18; 19) 23 PATH_SEGMENT@18..19
24 NAME_REF@[18; 19) 24 NAME_REF@18..19
25 IDENT@[18; 19) "T" 25 IDENT@18..19 "T"
26 WHITESPACE@[19; 20) " " 26 WHITESPACE@19..20 " "
27 BLOCK_EXPR@[20; 22) 27 BLOCK_EXPR@20..22
28 BLOCK@[20; 22) 28 BLOCK@20..22
29 L_CURLY@[20; 21) "{" 29 L_CURLY@20..21 "{"
30 R_CURLY@[21; 22) "}" 30 R_CURLY@21..22 "}"
31 WHITESPACE@[22; 23) "\n" 31 WHITESPACE@22..23 "\n"
32error [19; 19): expected colon 32error 19..19: expected colon
diff --git a/crates/ra_syntax/test_data/parser/err/0015_curly_in_params.rast b/crates/ra_syntax/test_data/parser/err/0015_curly_in_params.rast
index 36b848be3..b18378cff 100644
--- a/crates/ra_syntax/test_data/parser/err/0015_curly_in_params.rast
+++ b/crates/ra_syntax/test_data/parser/err/0015_curly_in_params.rast
@@ -1,24 +1,24 @@
1SOURCE_FILE@[0; 14) 1SOURCE_FILE@0..14
2 FN_DEF@[0; 7) 2 FN_DEF@0..7
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 7) 7 PARAM_LIST@6..7
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 ERROR@[7; 8) 9 ERROR@7..8
10 R_CURLY@[7; 8) "}" 10 R_CURLY@7..8 "}"
11 ERROR@[8; 9) 11 ERROR@8..9
12 R_PAREN@[8; 9) ")" 12 R_PAREN@8..9 ")"
13 WHITESPACE@[9; 10) " " 13 WHITESPACE@9..10 " "
14 ERROR@[10; 13) 14 ERROR@10..13
15 L_CURLY@[10; 11) "{" 15 L_CURLY@10..11 "{"
16 WHITESPACE@[11; 12) "\n" 16 WHITESPACE@11..12 "\n"
17 R_CURLY@[12; 13) "}" 17 R_CURLY@12..13 "}"
18 WHITESPACE@[13; 14) "\n" 18 WHITESPACE@13..14 "\n"
19error [7; 7): expected value parameter 19error 7..7: expected value parameter
20error [7; 7): expected R_PAREN 20error 7..7: expected R_PAREN
21error [7; 7): expected a block 21error 7..7: expected a block
22error [7; 7): unmatched `}` 22error 7..7: unmatched `}`
23error [8; 8): expected an item 23error 8..8: expected an item
24error [10; 10): expected an item 24error 10..10: expected an item
diff --git a/crates/ra_syntax/test_data/parser/err/0016_missing_semi.rast b/crates/ra_syntax/test_data/parser/err/0016_missing_semi.rast
index aca5a3ada..92bb47316 100644
--- a/crates/ra_syntax/test_data/parser/err/0016_missing_semi.rast
+++ b/crates/ra_syntax/test_data/parser/err/0016_missing_semi.rast
@@ -1,44 +1,44 @@
1SOURCE_FILE@[0; 56) 1SOURCE_FILE@0..56
2 FN_DEF@[0; 55) 2 FN_DEF@0..55
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 BLOCK_EXPR@[9; 55) 11 BLOCK_EXPR@9..55
12 BLOCK@[9; 55) 12 BLOCK@9..55
13 L_CURLY@[9; 10) "{" 13 L_CURLY@9..10 "{"
14 WHITESPACE@[10; 15) "\n " 14 WHITESPACE@10..15 "\n "
15 EXPR_STMT@[15; 38) 15 EXPR_STMT@15..38
16 CALL_EXPR@[15; 38) 16 CALL_EXPR@15..38
17 PATH_EXPR@[15; 18) 17 PATH_EXPR@15..18
18 PATH@[15; 18) 18 PATH@15..18
19 PATH_SEGMENT@[15; 18) 19 PATH_SEGMENT@15..18
20 NAME_REF@[15; 18) 20 NAME_REF@15..18
21 IDENT@[15; 18) "foo" 21 IDENT@15..18 "foo"
22 ARG_LIST@[18; 38) 22 ARG_LIST@18..38
23 L_PAREN@[18; 19) "(" 23 L_PAREN@18..19 "("
24 WHITESPACE@[19; 28) "\n " 24 WHITESPACE@19..28 "\n "
25 LITERAL@[28; 29) 25 LITERAL@28..29
26 INT_NUMBER@[28; 29) "1" 26 INT_NUMBER@28..29 "1"
27 COMMA@[29; 30) "," 27 COMMA@29..30 ","
28 WHITESPACE@[30; 31) " " 28 WHITESPACE@30..31 " "
29 LITERAL@[31; 32) 29 LITERAL@31..32
30 INT_NUMBER@[31; 32) "2" 30 INT_NUMBER@31..32 "2"
31 WHITESPACE@[32; 37) "\n " 31 WHITESPACE@32..37 "\n "
32 R_PAREN@[37; 38) ")" 32 R_PAREN@37..38 ")"
33 WHITESPACE@[38; 43) "\n " 33 WHITESPACE@38..43 "\n "
34 EXPR_STMT@[43; 53) 34 EXPR_STMT@43..53
35 RETURN_EXPR@[43; 52) 35 RETURN_EXPR@43..52
36 RETURN_KW@[43; 49) "return" 36 RETURN_KW@43..49 "return"
37 WHITESPACE@[49; 50) " " 37 WHITESPACE@49..50 " "
38 LITERAL@[50; 52) 38 LITERAL@50..52
39 INT_NUMBER@[50; 52) "92" 39 INT_NUMBER@50..52 "92"
40 SEMICOLON@[52; 53) ";" 40 SEMICOLON@52..53 ";"
41 WHITESPACE@[53; 54) "\n" 41 WHITESPACE@53..54 "\n"
42 R_CURLY@[54; 55) "}" 42 R_CURLY@54..55 "}"
43 WHITESPACE@[55; 56) "\n" 43 WHITESPACE@55..56 "\n"
44error [38; 38): expected SEMICOLON 44error 38..38: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0017_incomplete_binexpr.rast b/crates/ra_syntax/test_data/parser/err/0017_incomplete_binexpr.rast
index f9f4b9bc2..7bc718302 100644
--- a/crates/ra_syntax/test_data/parser/err/0017_incomplete_binexpr.rast
+++ b/crates/ra_syntax/test_data/parser/err/0017_incomplete_binexpr.rast
@@ -1,47 +1,47 @@
1SOURCE_FILE@[0; 47) 1SOURCE_FILE@0..47
2 FN_DEF@[0; 46) 2 FN_DEF@0..46
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 16) 7 PARAM_LIST@6..16
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 PARAM@[7; 15) 9 PARAM@7..15
10 BIND_PAT@[7; 10) 10 BIND_PAT@7..10
11 NAME@[7; 10) 11 NAME@7..10
12 IDENT@[7; 10) "foo" 12 IDENT@7..10 "foo"
13 COLON@[10; 11) ":" 13 COLON@10..11 ":"
14 WHITESPACE@[11; 12) " " 14 WHITESPACE@11..12 " "
15 PATH_TYPE@[12; 15) 15 PATH_TYPE@12..15
16 PATH@[12; 15) 16 PATH@12..15
17 PATH_SEGMENT@[12; 15) 17 PATH_SEGMENT@12..15
18 NAME_REF@[12; 15) 18 NAME_REF@12..15
19 IDENT@[12; 15) "i32" 19 IDENT@12..15 "i32"
20 R_PAREN@[15; 16) ")" 20 R_PAREN@15..16 ")"
21 WHITESPACE@[16; 17) " " 21 WHITESPACE@16..17 " "
22 BLOCK_EXPR@[17; 46) 22 BLOCK_EXPR@17..46
23 BLOCK@[17; 46) 23 BLOCK@17..46
24 L_CURLY@[17; 18) "{" 24 L_CURLY@17..18 "{"
25 WHITESPACE@[18; 23) "\n " 25 WHITESPACE@18..23 "\n "
26 LET_STMT@[23; 36) 26 LET_STMT@23..36
27 LET_KW@[23; 26) "let" 27 LET_KW@23..26 "let"
28 WHITESPACE@[26; 27) " " 28 WHITESPACE@26..27 " "
29 BIND_PAT@[27; 30) 29 BIND_PAT@27..30
30 NAME@[27; 30) 30 NAME@27..30
31 IDENT@[27; 30) "bar" 31 IDENT@27..30 "bar"
32 WHITESPACE@[30; 31) " " 32 WHITESPACE@30..31 " "
33 EQ@[31; 32) "=" 33 EQ@31..32 "="
34 WHITESPACE@[32; 33) " " 34 WHITESPACE@32..33 " "
35 LITERAL@[33; 35) 35 LITERAL@33..35
36 INT_NUMBER@[33; 35) "92" 36 INT_NUMBER@33..35 "92"
37 SEMICOLON@[35; 36) ";" 37 SEMICOLON@35..36 ";"
38 WHITESPACE@[36; 41) "\n " 38 WHITESPACE@36..41 "\n "
39 BIN_EXPR@[41; 44) 39 BIN_EXPR@41..44
40 LITERAL@[41; 42) 40 LITERAL@41..42
41 INT_NUMBER@[41; 42) "1" 41 INT_NUMBER@41..42 "1"
42 WHITESPACE@[42; 43) " " 42 WHITESPACE@42..43 " "
43 PLUS@[43; 44) "+" 43 PLUS@43..44 "+"
44 WHITESPACE@[44; 45) "\n" 44 WHITESPACE@44..45 "\n"
45 R_CURLY@[45; 46) "}" 45 R_CURLY@45..46 "}"
46 WHITESPACE@[46; 47) "\n" 46 WHITESPACE@46..47 "\n"
47error [44; 44): expected expression 47error 44..44: expected expression
diff --git a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
index 9a8f76673..63194f974 100644
--- a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
+++ b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.rast
@@ -1,132 +1,132 @@
1SOURCE_FILE@[0; 183) 1SOURCE_FILE@0..183
2 IMPL_DEF@[0; 182) 2 IMPL_DEF@0..182
3 IMPL_KW@[0; 4) "impl" 3 IMPL_KW@0..4 "impl"
4 WHITESPACE@[4; 5) " " 4 WHITESPACE@4..5 " "
5 PATH_TYPE@[5; 13) 5 PATH_TYPE@5..13
6 PATH@[5; 13) 6 PATH@5..13
7 PATH_SEGMENT@[5; 13) 7 PATH_SEGMENT@5..13
8 NAME_REF@[5; 13) 8 NAME_REF@5..13
9 IDENT@[5; 13) "FnScopes" 9 IDENT@5..13 "FnScopes"
10 WHITESPACE@[13; 14) " " 10 WHITESPACE@13..14 " "
11 ITEM_LIST@[14; 182) 11 ITEM_LIST@14..182
12 L_CURLY@[14; 15) "{" 12 L_CURLY@14..15 "{"
13 WHITESPACE@[15; 20) "\n " 13 WHITESPACE@15..20 "\n "
14 FN_DEF@[20; 161) 14 FN_DEF@20..161
15 FN_KW@[20; 22) "fn" 15 FN_KW@20..22 "fn"
16 WHITESPACE@[22; 23) " " 16 WHITESPACE@22..23 " "
17 NAME@[23; 32) 17 NAME@23..32
18 IDENT@[23; 32) "new_scope" 18 IDENT@23..32 "new_scope"
19 PARAM_LIST@[32; 35) 19 PARAM_LIST@32..35
20 L_PAREN@[32; 33) "(" 20 L_PAREN@32..33 "("
21 PARAM@[33; 34) 21 PARAM@33..34
22 REF_PAT@[33; 34) 22 REF_PAT@33..34
23 AMP@[33; 34) "&" 23 AMP@33..34 "&"
24 R_PAREN@[34; 35) ")" 24 R_PAREN@34..35 ")"
25 WHITESPACE@[35; 36) " " 25 WHITESPACE@35..36 " "
26 RET_TYPE@[36; 46) 26 RET_TYPE@36..46
27 THIN_ARROW@[36; 38) "->" 27 THIN_ARROW@36..38 "->"
28 WHITESPACE@[38; 39) " " 28 WHITESPACE@38..39 " "
29 PATH_TYPE@[39; 46) 29 PATH_TYPE@39..46
30 PATH@[39; 46) 30 PATH@39..46
31 PATH_SEGMENT@[39; 46) 31 PATH_SEGMENT@39..46
32 NAME_REF@[39; 46) 32 NAME_REF@39..46
33 IDENT@[39; 46) "ScopeId" 33 IDENT@39..46 "ScopeId"
34 WHITESPACE@[46; 47) " " 34 WHITESPACE@46..47 " "
35 BLOCK_EXPR@[47; 161) 35 BLOCK_EXPR@47..161
36 BLOCK@[47; 161) 36 BLOCK@47..161
37 L_CURLY@[47; 48) "{" 37 L_CURLY@47..48 "{"
38 WHITESPACE@[48; 57) "\n " 38 WHITESPACE@48..57 "\n "
39 LET_STMT@[57; 85) 39 LET_STMT@57..85
40 LET_KW@[57; 60) "let" 40 LET_KW@57..60 "let"
41 WHITESPACE@[60; 61) " " 41 WHITESPACE@60..61 " "
42 BIND_PAT@[61; 64) 42 BIND_PAT@61..64
43 NAME@[61; 64) 43 NAME@61..64
44 IDENT@[61; 64) "res" 44 IDENT@61..64 "res"
45 WHITESPACE@[64; 65) " " 45 WHITESPACE@64..65 " "
46 EQ@[65; 66) "=" 46 EQ@65..66 "="
47 WHITESPACE@[66; 67) " " 47 WHITESPACE@66..67 " "
48 METHOD_CALL_EXPR@[67; 84) 48 METHOD_CALL_EXPR@67..84
49 FIELD_EXPR@[67; 78) 49 FIELD_EXPR@67..78
50 PATH_EXPR@[67; 71) 50 PATH_EXPR@67..71
51 PATH@[67; 71) 51 PATH@67..71
52 PATH_SEGMENT@[67; 71) 52 PATH_SEGMENT@67..71
53 SELF_KW@[67; 71) "self" 53 SELF_KW@67..71 "self"
54 DOT@[71; 72) "." 54 DOT@71..72 "."
55 NAME_REF@[72; 78) 55 NAME_REF@72..78
56 IDENT@[72; 78) "scopes" 56 IDENT@72..78 "scopes"
57 DOT@[78; 79) "." 57 DOT@78..79 "."
58 NAME_REF@[79; 82) 58 NAME_REF@79..82
59 IDENT@[79; 82) "len" 59 IDENT@79..82 "len"
60 ARG_LIST@[82; 84) 60 ARG_LIST@82..84
61 L_PAREN@[82; 83) "(" 61 L_PAREN@82..83 "("
62 R_PAREN@[83; 84) ")" 62 R_PAREN@83..84 ")"
63 SEMICOLON@[84; 85) ";" 63 SEMICOLON@84..85 ";"
64 WHITESPACE@[85; 94) "\n " 64 WHITESPACE@85..94 "\n "
65 METHOD_CALL_EXPR@[94; 155) 65 METHOD_CALL_EXPR@94..155
66 FIELD_EXPR@[94; 105) 66 FIELD_EXPR@94..105
67 PATH_EXPR@[94; 98) 67 PATH_EXPR@94..98
68 PATH@[94; 98) 68 PATH@94..98
69 PATH_SEGMENT@[94; 98) 69 PATH_SEGMENT@94..98
70 SELF_KW@[94; 98) "self" 70 SELF_KW@94..98 "self"
71 DOT@[98; 99) "." 71 DOT@98..99 "."
72 NAME_REF@[99; 105) 72 NAME_REF@99..105
73 IDENT@[99; 105) "scopes" 73 IDENT@99..105 "scopes"
74 DOT@[105; 106) "." 74 DOT@105..106 "."
75 NAME_REF@[106; 110) 75 NAME_REF@106..110
76 IDENT@[106; 110) "push" 76 IDENT@106..110 "push"
77 ARG_LIST@[110; 155) 77 ARG_LIST@110..155
78 L_PAREN@[110; 111) "(" 78 L_PAREN@110..111 "("
79 RECORD_LIT@[111; 154) 79 RECORD_LIT@111..154
80 PATH@[111; 120) 80 PATH@111..120
81 PATH_SEGMENT@[111; 120) 81 PATH_SEGMENT@111..120
82 NAME_REF@[111; 120) 82 NAME_REF@111..120
83 IDENT@[111; 120) "ScopeData" 83 IDENT@111..120 "ScopeData"
84 WHITESPACE@[120; 121) " " 84 WHITESPACE@120..121 " "
85 RECORD_FIELD_LIST@[121; 154) 85 RECORD_FIELD_LIST@121..154
86 L_CURLY@[121; 122) "{" 86 L_CURLY@121..122 "{"
87 WHITESPACE@[122; 123) " " 87 WHITESPACE@122..123 " "
88 RECORD_FIELD@[123; 135) 88 RECORD_FIELD@123..135
89 NAME_REF@[123; 129) 89 NAME_REF@123..129
90 IDENT@[123; 129) "parent" 90 IDENT@123..129 "parent"
91 COLON@[129; 130) ":" 91 COLON@129..130 ":"
92 WHITESPACE@[130; 131) " " 92 WHITESPACE@130..131 " "
93 PATH_EXPR@[131; 135) 93 PATH_EXPR@131..135
94 PATH@[131; 135) 94 PATH@131..135
95 PATH_SEGMENT@[131; 135) 95 PATH_SEGMENT@131..135
96 NAME_REF@[131; 135) 96 NAME_REF@131..135
97 IDENT@[131; 135) "None" 97 IDENT@131..135 "None"
98 COMMA@[135; 136) "," 98 COMMA@135..136 ","
99 WHITESPACE@[136; 137) " " 99 WHITESPACE@136..137 " "
100 RECORD_FIELD@[137; 152) 100 RECORD_FIELD@137..152
101 NAME_REF@[137; 144) 101 NAME_REF@137..144
102 IDENT@[137; 144) "entries" 102 IDENT@137..144 "entries"
103 COLON@[144; 145) ":" 103 COLON@144..145 ":"
104 WHITESPACE@[145; 146) " " 104 WHITESPACE@145..146 " "
105 MACRO_CALL@[146; 152) 105 MACRO_CALL@146..152
106 PATH@[146; 149) 106 PATH@146..149
107 PATH_SEGMENT@[146; 149) 107 PATH_SEGMENT@146..149
108 NAME_REF@[146; 149) 108 NAME_REF@146..149
109 IDENT@[146; 149) "vec" 109 IDENT@146..149 "vec"
110 BANG@[149; 150) "!" 110 BANG@149..150 "!"
111 TOKEN_TREE@[150; 152) 111 TOKEN_TREE@150..152
112 L_BRACK@[150; 151) "[" 112 L_BRACK@150..151 "["
113 R_BRACK@[151; 152) "]" 113 R_BRACK@151..152 "]"
114 WHITESPACE@[152; 153) " " 114 WHITESPACE@152..153 " "
115 R_CURLY@[153; 154) "}" 115 R_CURLY@153..154 "}"
116 R_PAREN@[154; 155) ")" 116 R_PAREN@154..155 ")"
117 WHITESPACE@[155; 160) "\n " 117 WHITESPACE@155..160 "\n "
118 R_CURLY@[160; 161) "}" 118 R_CURLY@160..161 "}"
119 WHITESPACE@[161; 167) "\n\n " 119 WHITESPACE@161..167 "\n\n "
120 FN_DEF@[167; 180) 120 FN_DEF@167..180
121 FN_KW@[167; 169) "fn" 121 FN_KW@167..169 "fn"
122 WHITESPACE@[169; 170) " " 122 WHITESPACE@169..170 " "
123 NAME@[170; 180) 123 NAME@170..180
124 IDENT@[170; 180) "set_parent" 124 IDENT@170..180 "set_parent"
125 WHITESPACE@[180; 181) "\n" 125 WHITESPACE@180..181 "\n"
126 R_CURLY@[181; 182) "}" 126 R_CURLY@181..182 "}"
127 WHITESPACE@[182; 183) "\n" 127 WHITESPACE@182..183 "\n"
128error [34; 34): expected pattern 128error 34..34: expected pattern
129error [34; 34): expected COLON 129error 34..34: expected COLON
130error [34; 34): expected type 130error 34..34: expected type
131error [180; 180): expected function arguments 131error 180..180: expected function arguments
132error [180; 180): expected a block 132error 180..180: expected a block
diff --git a/crates/ra_syntax/test_data/parser/err/0019_let_recover.rast b/crates/ra_syntax/test_data/parser/err/0019_let_recover.rast
index e283091e1..d20bb60f1 100644
--- a/crates/ra_syntax/test_data/parser/err/0019_let_recover.rast
+++ b/crates/ra_syntax/test_data/parser/err/0019_let_recover.rast
@@ -1,107 +1,107 @@
1SOURCE_FILE@[0; 139) 1SOURCE_FILE@0..139
2 FN_DEF@[0; 138) 2 FN_DEF@0..138
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 BLOCK_EXPR@[9; 138) 11 BLOCK_EXPR@9..138
12 BLOCK@[9; 138) 12 BLOCK@9..138
13 L_CURLY@[9; 10) "{" 13 L_CURLY@9..10 "{"
14 WHITESPACE@[10; 15) "\n " 14 WHITESPACE@10..15 "\n "
15 LET_STMT@[15; 24) 15 LET_STMT@15..24
16 LET_KW@[15; 18) "let" 16 LET_KW@15..18 "let"
17 WHITESPACE@[18; 19) " " 17 WHITESPACE@18..19 " "
18 BIND_PAT@[19; 22) 18 BIND_PAT@19..22
19 NAME@[19; 22) 19 NAME@19..22
20 IDENT@[19; 22) "foo" 20 IDENT@19..22 "foo"
21 WHITESPACE@[22; 23) " " 21 WHITESPACE@22..23 " "
22 EQ@[23; 24) "=" 22 EQ@23..24 "="
23 WHITESPACE@[24; 29) "\n " 23 WHITESPACE@24..29 "\n "
24 LET_STMT@[29; 41) 24 LET_STMT@29..41
25 LET_KW@[29; 32) "let" 25 LET_KW@29..32 "let"
26 WHITESPACE@[32; 33) " " 26 WHITESPACE@32..33 " "
27 BIND_PAT@[33; 36) 27 BIND_PAT@33..36
28 NAME@[33; 36) 28 NAME@33..36
29 IDENT@[33; 36) "bar" 29 IDENT@33..36 "bar"
30 WHITESPACE@[36; 37) " " 30 WHITESPACE@36..37 " "
31 EQ@[37; 38) "=" 31 EQ@37..38 "="
32 WHITESPACE@[38; 39) " " 32 WHITESPACE@38..39 " "
33 LITERAL@[39; 40) 33 LITERAL@39..40
34 INT_NUMBER@[39; 40) "1" 34 INT_NUMBER@39..40 "1"
35 SEMICOLON@[40; 41) ";" 35 SEMICOLON@40..41 ";"
36 WHITESPACE@[41; 46) "\n " 36 WHITESPACE@41..46 "\n "
37 LET_STMT@[46; 49) 37 LET_STMT@46..49
38 LET_KW@[46; 49) "let" 38 LET_KW@46..49 "let"
39 WHITESPACE@[49; 54) "\n " 39 WHITESPACE@49..54 "\n "
40 LET_STMT@[54; 67) 40 LET_STMT@54..67
41 LET_KW@[54; 57) "let" 41 LET_KW@54..57 "let"
42 WHITESPACE@[57; 58) " " 42 WHITESPACE@57..58 " "
43 BIND_PAT@[58; 61) 43 BIND_PAT@58..61
44 NAME@[58; 61) 44 NAME@58..61
45 IDENT@[58; 61) "baz" 45 IDENT@58..61 "baz"
46 WHITESPACE@[61; 62) " " 46 WHITESPACE@61..62 " "
47 EQ@[62; 63) "=" 47 EQ@62..63 "="
48 WHITESPACE@[63; 64) " " 48 WHITESPACE@63..64 " "
49 LITERAL@[64; 66) 49 LITERAL@64..66
50 INT_NUMBER@[64; 66) "92" 50 INT_NUMBER@64..66 "92"
51 SEMICOLON@[66; 67) ";" 51 SEMICOLON@66..67 ";"
52 WHITESPACE@[67; 72) "\n " 52 WHITESPACE@67..72 "\n "
53 LET_STMT@[72; 75) 53 LET_STMT@72..75
54 LET_KW@[72; 75) "let" 54 LET_KW@72..75 "let"
55 WHITESPACE@[75; 80) "\n " 55 WHITESPACE@75..80 "\n "
56 EXPR_STMT@[80; 90) 56 EXPR_STMT@80..90
57 IF_EXPR@[80; 90) 57 IF_EXPR@80..90
58 IF_KW@[80; 82) "if" 58 IF_KW@80..82 "if"
59 WHITESPACE@[82; 83) " " 59 WHITESPACE@82..83 " "
60 CONDITION@[83; 87) 60 CONDITION@83..87
61 LITERAL@[83; 87) 61 LITERAL@83..87
62 TRUE_KW@[83; 87) "true" 62 TRUE_KW@83..87 "true"
63 WHITESPACE@[87; 88) " " 63 WHITESPACE@87..88 " "
64 BLOCK_EXPR@[88; 90) 64 BLOCK_EXPR@88..90
65 BLOCK@[88; 90) 65 BLOCK@88..90
66 L_CURLY@[88; 89) "{" 66 L_CURLY@88..89 "{"
67 R_CURLY@[89; 90) "}" 67 R_CURLY@89..90 "}"
68 WHITESPACE@[90; 95) "\n " 68 WHITESPACE@90..95 "\n "
69 LET_STMT@[95; 98) 69 LET_STMT@95..98
70 LET_KW@[95; 98) "let" 70 LET_KW@95..98 "let"
71 WHITESPACE@[98; 103) "\n " 71 WHITESPACE@98..103 "\n "
72 EXPR_STMT@[103; 116) 72 EXPR_STMT@103..116
73 WHILE_EXPR@[103; 116) 73 WHILE_EXPR@103..116
74 WHILE_KW@[103; 108) "while" 74 WHILE_KW@103..108 "while"
75 WHITESPACE@[108; 109) " " 75 WHITESPACE@108..109 " "
76 CONDITION@[109; 113) 76 CONDITION@109..113
77 LITERAL@[109; 113) 77 LITERAL@109..113
78 TRUE_KW@[109; 113) "true" 78 TRUE_KW@109..113 "true"
79 WHITESPACE@[113; 114) " " 79 WHITESPACE@113..114 " "
80 BLOCK_EXPR@[114; 116) 80 BLOCK_EXPR@114..116
81 BLOCK@[114; 116) 81 BLOCK@114..116
82 L_CURLY@[114; 115) "{" 82 L_CURLY@114..115 "{"
83 R_CURLY@[115; 116) "}" 83 R_CURLY@115..116 "}"
84 WHITESPACE@[116; 121) "\n " 84 WHITESPACE@116..121 "\n "
85 LET_STMT@[121; 124) 85 LET_STMT@121..124
86 LET_KW@[121; 124) "let" 86 LET_KW@121..124 "let"
87 WHITESPACE@[124; 129) "\n " 87 WHITESPACE@124..129 "\n "
88 LOOP_EXPR@[129; 136) 88 LOOP_EXPR@129..136
89 LOOP_KW@[129; 133) "loop" 89 LOOP_KW@129..133 "loop"
90 WHITESPACE@[133; 134) " " 90 WHITESPACE@133..134 " "
91 BLOCK_EXPR@[134; 136) 91 BLOCK_EXPR@134..136
92 BLOCK@[134; 136) 92 BLOCK@134..136
93 L_CURLY@[134; 135) "{" 93 L_CURLY@134..135 "{"
94 R_CURLY@[135; 136) "}" 94 R_CURLY@135..136 "}"
95 WHITESPACE@[136; 137) "\n" 95 WHITESPACE@136..137 "\n"
96 R_CURLY@[137; 138) "}" 96 R_CURLY@137..138 "}"
97 WHITESPACE@[138; 139) "\n" 97 WHITESPACE@138..139 "\n"
98error [24; 24): expected expression 98error 24..24: expected expression
99error [24; 24): expected SEMICOLON 99error 24..24: expected SEMICOLON
100error [49; 49): expected pattern 100error 49..49: expected pattern
101error [49; 49): expected SEMICOLON 101error 49..49: expected SEMICOLON
102error [75; 75): expected pattern 102error 75..75: expected pattern
103error [75; 75): expected SEMICOLON 103error 75..75: expected SEMICOLON
104error [98; 98): expected pattern 104error 98..98: expected pattern
105error [98; 98): expected SEMICOLON 105error 98..98: expected SEMICOLON
106error [124; 124): expected pattern 106error 124..124: expected pattern
107error [124; 124): expected SEMICOLON 107error 124..124: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0020_fn_recover.rast b/crates/ra_syntax/test_data/parser/err/0020_fn_recover.rast
index c11dc23f5..1185f44f9 100644
--- a/crates/ra_syntax/test_data/parser/err/0020_fn_recover.rast
+++ b/crates/ra_syntax/test_data/parser/err/0020_fn_recover.rast
@@ -1,21 +1,21 @@
1SOURCE_FILE@[0; 16) 1SOURCE_FILE@0..16
2 FN_DEF@[0; 2) 2 FN_DEF@0..2
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 4) "\n\n" 4 WHITESPACE@2..4 "\n\n"
5 FN_DEF@[4; 15) 5 FN_DEF@4..15
6 FN_KW@[4; 6) "fn" 6 FN_KW@4..6 "fn"
7 WHITESPACE@[6; 7) " " 7 WHITESPACE@6..7 " "
8 NAME@[7; 10) 8 NAME@7..10
9 IDENT@[7; 10) "foo" 9 IDENT@7..10 "foo"
10 PARAM_LIST@[10; 12) 10 PARAM_LIST@10..12
11 L_PAREN@[10; 11) "(" 11 L_PAREN@10..11 "("
12 R_PAREN@[11; 12) ")" 12 R_PAREN@11..12 ")"
13 WHITESPACE@[12; 13) " " 13 WHITESPACE@12..13 " "
14 BLOCK_EXPR@[13; 15) 14 BLOCK_EXPR@13..15
15 BLOCK@[13; 15) 15 BLOCK@13..15
16 L_CURLY@[13; 14) "{" 16 L_CURLY@13..14 "{"
17 R_CURLY@[14; 15) "}" 17 R_CURLY@14..15 "}"
18 WHITESPACE@[15; 16) "\n" 18 WHITESPACE@15..16 "\n"
19error [2; 2): expected a name 19error 2..2: expected a name
20error [2; 2): expected function arguments 20error 2..2: expected function arguments
21error [2; 2): expected a block 21error 2..2: expected a block
diff --git a/crates/ra_syntax/test_data/parser/err/0021_incomplete_param.rast b/crates/ra_syntax/test_data/parser/err/0021_incomplete_param.rast
index ae04122d8..c7bf4caa0 100644
--- a/crates/ra_syntax/test_data/parser/err/0021_incomplete_param.rast
+++ b/crates/ra_syntax/test_data/parser/err/0021_incomplete_param.rast
@@ -1,35 +1,35 @@
1SOURCE_FILE@[0; 22) 1SOURCE_FILE@0..22
2 FN_DEF@[0; 21) 2 FN_DEF@0..21
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 17) 7 PARAM_LIST@6..17
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 PARAM@[7; 13) 9 PARAM@7..13
10 BIND_PAT@[7; 8) 10 BIND_PAT@7..8
11 NAME@[7; 8) 11 NAME@7..8
12 IDENT@[7; 8) "x" 12 IDENT@7..8 "x"
13 COLON@[8; 9) ":" 13 COLON@8..9 ":"
14 WHITESPACE@[9; 10) " " 14 WHITESPACE@9..10 " "
15 PATH_TYPE@[10; 13) 15 PATH_TYPE@10..13
16 PATH@[10; 13) 16 PATH@10..13
17 PATH_SEGMENT@[10; 13) 17 PATH_SEGMENT@10..13
18 NAME_REF@[10; 13) 18 NAME_REF@10..13
19 IDENT@[10; 13) "i32" 19 IDENT@10..13 "i32"
20 COMMA@[13; 14) "," 20 COMMA@13..14 ","
21 WHITESPACE@[14; 15) " " 21 WHITESPACE@14..15 " "
22 PARAM@[15; 16) 22 PARAM@15..16
23 BIND_PAT@[15; 16) 23 BIND_PAT@15..16
24 NAME@[15; 16) 24 NAME@15..16
25 IDENT@[15; 16) "y" 25 IDENT@15..16 "y"
26 R_PAREN@[16; 17) ")" 26 R_PAREN@16..17 ")"
27 WHITESPACE@[17; 18) " " 27 WHITESPACE@17..18 " "
28 BLOCK_EXPR@[18; 21) 28 BLOCK_EXPR@18..21
29 BLOCK@[18; 21) 29 BLOCK@18..21
30 L_CURLY@[18; 19) "{" 30 L_CURLY@18..19 "{"
31 WHITESPACE@[19; 20) "\n" 31 WHITESPACE@19..20 "\n"
32 R_CURLY@[20; 21) "}" 32 R_CURLY@20..21 "}"
33 WHITESPACE@[21; 22) "\n" 33 WHITESPACE@21..22 "\n"
34error [16; 16): expected COLON 34error 16..16: expected COLON
35error [16; 16): expected type 35error 16..16: expected type
diff --git a/crates/ra_syntax/test_data/parser/err/0022_bad_exprs.rast b/crates/ra_syntax/test_data/parser/err/0022_bad_exprs.rast
index 465749f95..cc0d75cc8 100644
--- a/crates/ra_syntax/test_data/parser/err/0022_bad_exprs.rast
+++ b/crates/ra_syntax/test_data/parser/err/0022_bad_exprs.rast
@@ -1,183 +1,183 @@
1SOURCE_FILE@[0; 112) 1SOURCE_FILE@0..112
2 FN_DEF@[0; 33) 2 FN_DEF@0..33
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 4) 5 NAME@3..4
6 IDENT@[3; 4) "a" 6 IDENT@3..4 "a"
7 PARAM_LIST@[4; 6) 7 PARAM_LIST@4..6
8 L_PAREN@[4; 5) "(" 8 L_PAREN@4..5 "("
9 R_PAREN@[5; 6) ")" 9 R_PAREN@5..6 ")"
10 WHITESPACE@[6; 7) " " 10 WHITESPACE@6..7 " "
11 BLOCK_EXPR@[7; 33) 11 BLOCK_EXPR@7..33
12 BLOCK@[7; 33) 12 BLOCK@7..33
13 L_CURLY@[7; 8) "{" 13 L_CURLY@7..8 "{"
14 WHITESPACE@[8; 9) " " 14 WHITESPACE@8..9 " "
15 EXPR_STMT@[9; 17) 15 EXPR_STMT@9..17
16 ARRAY_EXPR@[9; 17) 16 ARRAY_EXPR@9..17
17 L_BRACK@[9; 10) "[" 17 L_BRACK@9..10 "["
18 LITERAL@[10; 11) 18 LITERAL@10..11
19 INT_NUMBER@[10; 11) "1" 19 INT_NUMBER@10..11 "1"
20 COMMA@[11; 12) "," 20 COMMA@11..12 ","
21 WHITESPACE@[12; 13) " " 21 WHITESPACE@12..13 " "
22 LITERAL@[13; 14) 22 LITERAL@13..14
23 INT_NUMBER@[13; 14) "2" 23 INT_NUMBER@13..14 "2"
24 COMMA@[14; 15) "," 24 COMMA@14..15 ","
25 WHITESPACE@[15; 16) " " 25 WHITESPACE@15..16 " "
26 ERROR@[16; 17) 26 ERROR@16..17
27 AT@[16; 17) "@" 27 AT@16..17 "@"
28 EXPR_STMT@[17; 18) 28 EXPR_STMT@17..18
29 ERROR@[17; 18) 29 ERROR@17..18
30 COMMA@[17; 18) "," 30 COMMA@17..18 ","
31 WHITESPACE@[18; 19) " " 31 WHITESPACE@18..19 " "
32 STRUCT_DEF@[19; 26) 32 STRUCT_DEF@19..26
33 STRUCT_KW@[19; 25) "struct" 33 STRUCT_KW@19..25 "struct"
34 ERROR@[25; 26) 34 ERROR@25..26
35 COMMA@[25; 26) "," 35 COMMA@25..26 ","
36 WHITESPACE@[26; 27) " " 36 WHITESPACE@26..27 " "
37 LET_STMT@[27; 31) 37 LET_STMT@27..31
38 LET_KW@[27; 30) "let" 38 LET_KW@27..30 "let"
39 ERROR@[30; 31) 39 ERROR@30..31
40 R_BRACK@[30; 31) "]" 40 R_BRACK@30..31 "]"
41 WHITESPACE@[31; 32) " " 41 WHITESPACE@31..32 " "
42 R_CURLY@[32; 33) "}" 42 R_CURLY@32..33 "}"
43 WHITESPACE@[33; 34) "\n" 43 WHITESPACE@33..34 "\n"
44 FN_DEF@[34; 68) 44 FN_DEF@34..68
45 FN_KW@[34; 36) "fn" 45 FN_KW@34..36 "fn"
46 WHITESPACE@[36; 37) " " 46 WHITESPACE@36..37 " "
47 NAME@[37; 38) 47 NAME@37..38
48 IDENT@[37; 38) "b" 48 IDENT@37..38 "b"
49 PARAM_LIST@[38; 40) 49 PARAM_LIST@38..40
50 L_PAREN@[38; 39) "(" 50 L_PAREN@38..39 "("
51 R_PAREN@[39; 40) ")" 51 R_PAREN@39..40 ")"
52 WHITESPACE@[40; 41) " " 52 WHITESPACE@40..41 " "
53 BLOCK_EXPR@[41; 68) 53 BLOCK_EXPR@41..68
54 BLOCK@[41; 68) 54 BLOCK@41..68
55 L_CURLY@[41; 42) "{" 55 L_CURLY@41..42 "{"
56 WHITESPACE@[42; 43) " " 56 WHITESPACE@42..43 " "
57 EXPR_STMT@[43; 54) 57 EXPR_STMT@43..54
58 CALL_EXPR@[43; 54) 58 CALL_EXPR@43..54
59 PATH_EXPR@[43; 46) 59 PATH_EXPR@43..46
60 PATH@[43; 46) 60 PATH@43..46
61 PATH_SEGMENT@[43; 46) 61 PATH_SEGMENT@43..46
62 NAME_REF@[43; 46) 62 NAME_REF@43..46
63 IDENT@[43; 46) "foo" 63 IDENT@43..46 "foo"
64 ARG_LIST@[46; 54) 64 ARG_LIST@46..54
65 L_PAREN@[46; 47) "(" 65 L_PAREN@46..47 "("
66 LITERAL@[47; 48) 66 LITERAL@47..48
67 INT_NUMBER@[47; 48) "1" 67 INT_NUMBER@47..48 "1"
68 COMMA@[48; 49) "," 68 COMMA@48..49 ","
69 WHITESPACE@[49; 50) " " 69 WHITESPACE@49..50 " "
70 LITERAL@[50; 51) 70 LITERAL@50..51
71 INT_NUMBER@[50; 51) "2" 71 INT_NUMBER@50..51 "2"
72 COMMA@[51; 52) "," 72 COMMA@51..52 ","
73 WHITESPACE@[52; 53) " " 73 WHITESPACE@52..53 " "
74 ERROR@[53; 54) 74 ERROR@53..54
75 AT@[53; 54) "@" 75 AT@53..54 "@"
76 EXPR_STMT@[54; 55) 76 EXPR_STMT@54..55
77 ERROR@[54; 55) 77 ERROR@54..55
78 COMMA@[54; 55) "," 78 COMMA@54..55 ","
79 WHITESPACE@[55; 56) " " 79 WHITESPACE@55..56 " "
80 IMPL_DEF@[56; 60) 80 IMPL_DEF@56..60
81 IMPL_KW@[56; 60) "impl" 81 IMPL_KW@56..60 "impl"
82 EXPR_STMT@[60; 61) 82 EXPR_STMT@60..61
83 ERROR@[60; 61) 83 ERROR@60..61
84 COMMA@[60; 61) "," 84 COMMA@60..61 ","
85 WHITESPACE@[61; 62) " " 85 WHITESPACE@61..62 " "
86 LET_STMT@[62; 65) 86 LET_STMT@62..65
87 LET_KW@[62; 65) "let" 87 LET_KW@62..65 "let"
88 ERROR@[65; 66) 88 ERROR@65..66
89 R_PAREN@[65; 66) ")" 89 R_PAREN@65..66 ")"
90 WHITESPACE@[66; 67) " " 90 WHITESPACE@66..67 " "
91 R_CURLY@[67; 68) "}" 91 R_CURLY@67..68 "}"
92 WHITESPACE@[68; 69) "\n" 92 WHITESPACE@68..69 "\n"
93 FN_DEF@[69; 111) 93 FN_DEF@69..111
94 FN_KW@[69; 71) "fn" 94 FN_KW@69..71 "fn"
95 WHITESPACE@[71; 72) " " 95 WHITESPACE@71..72 " "
96 NAME@[72; 73) 96 NAME@72..73
97 IDENT@[72; 73) "c" 97 IDENT@72..73 "c"
98 PARAM_LIST@[73; 75) 98 PARAM_LIST@73..75
99 L_PAREN@[73; 74) "(" 99 L_PAREN@73..74 "("
100 R_PAREN@[74; 75) ")" 100 R_PAREN@74..75 ")"
101 WHITESPACE@[75; 76) " " 101 WHITESPACE@75..76 " "
102 BLOCK_EXPR@[76; 111) 102 BLOCK_EXPR@76..111
103 BLOCK@[76; 111) 103 BLOCK@76..111
104 L_CURLY@[76; 77) "{" 104 L_CURLY@76..77 "{"
105 WHITESPACE@[77; 78) " " 105 WHITESPACE@77..78 " "
106 EXPR_STMT@[78; 93) 106 EXPR_STMT@78..93
107 METHOD_CALL_EXPR@[78; 93) 107 METHOD_CALL_EXPR@78..93
108 PATH_EXPR@[78; 81) 108 PATH_EXPR@78..81
109 PATH@[78; 81) 109 PATH@78..81
110 PATH_SEGMENT@[78; 81) 110 PATH_SEGMENT@78..81
111 NAME_REF@[78; 81) 111 NAME_REF@78..81
112 IDENT@[78; 81) "foo" 112 IDENT@78..81 "foo"
113 DOT@[81; 82) "." 113 DOT@81..82 "."
114 NAME_REF@[82; 85) 114 NAME_REF@82..85
115 IDENT@[82; 85) "bar" 115 IDENT@82..85 "bar"
116 ARG_LIST@[85; 93) 116 ARG_LIST@85..93
117 L_PAREN@[85; 86) "(" 117 L_PAREN@85..86 "("
118 LITERAL@[86; 87) 118 LITERAL@86..87
119 INT_NUMBER@[86; 87) "1" 119 INT_NUMBER@86..87 "1"
120 COMMA@[87; 88) "," 120 COMMA@87..88 ","
121 WHITESPACE@[88; 89) " " 121 WHITESPACE@88..89 " "
122 LITERAL@[89; 90) 122 LITERAL@89..90
123 INT_NUMBER@[89; 90) "2" 123 INT_NUMBER@89..90 "2"
124 COMMA@[90; 91) "," 124 COMMA@90..91 ","
125 WHITESPACE@[91; 92) " " 125 WHITESPACE@91..92 " "
126 ERROR@[92; 93) 126 ERROR@92..93
127 AT@[92; 93) "@" 127 AT@92..93 "@"
128 EXPR_STMT@[93; 94) 128 EXPR_STMT@93..94
129 ERROR@[93; 94) 129 ERROR@93..94
130 COMMA@[93; 94) "," 130 COMMA@93..94 ","
131 WHITESPACE@[94; 95) " " 131 WHITESPACE@94..95 " "
132 EXPR_STMT@[95; 96) 132 EXPR_STMT@95..96
133 ERROR@[95; 96) 133 ERROR@95..96
134 R_BRACK@[95; 96) "]" 134 R_BRACK@95..96 "]"
135 EXPR_STMT@[96; 97) 135 EXPR_STMT@96..97
136 ERROR@[96; 97) 136 ERROR@96..97
137 COMMA@[96; 97) "," 137 COMMA@96..97 ","
138 WHITESPACE@[97; 98) " " 138 WHITESPACE@97..98 " "
139 TRAIT_DEF@[98; 104) 139 TRAIT_DEF@98..104
140 TRAIT_KW@[98; 103) "trait" 140 TRAIT_KW@98..103 "trait"
141 ERROR@[103; 104) 141 ERROR@103..104
142 COMMA@[103; 104) "," 142 COMMA@103..104 ","
143 WHITESPACE@[104; 105) " " 143 WHITESPACE@104..105 " "
144 LET_STMT@[105; 108) 144 LET_STMT@105..108
145 LET_KW@[105; 108) "let" 145 LET_KW@105..108 "let"
146 ERROR@[108; 109) 146 ERROR@108..109
147 R_PAREN@[108; 109) ")" 147 R_PAREN@108..109 ")"
148 WHITESPACE@[109; 110) " " 148 WHITESPACE@109..110 " "
149 R_CURLY@[110; 111) "}" 149 R_CURLY@110..111 "}"
150 WHITESPACE@[111; 112) "\n" 150 WHITESPACE@111..112 "\n"
151error [16; 16): expected expression 151error 16..16: expected expression
152error [17; 17): expected R_BRACK 152error 17..17: expected R_BRACK
153error [17; 17): expected SEMICOLON 153error 17..17: expected SEMICOLON
154error [17; 17): expected expression 154error 17..17: expected expression
155error [18; 18): expected SEMICOLON 155error 18..18: expected SEMICOLON
156error [25; 25): expected a name 156error 25..25: expected a name
157error [26; 26): expected `;`, `{`, or `(` 157error 26..26: expected `;`, `{`, or `(`
158error [30; 30): expected pattern 158error 30..30: expected pattern
159error [31; 31): expected SEMICOLON 159error 31..31: expected SEMICOLON
160error [53; 53): expected expression 160error 53..53: expected expression
161error [54; 54): expected SEMICOLON 161error 54..54: expected SEMICOLON
162error [54; 54): expected expression 162error 54..54: expected expression
163error [55; 55): expected SEMICOLON 163error 55..55: expected SEMICOLON
164error [60; 60): expected type 164error 60..60: expected type
165error [60; 60): expected `{` 165error 60..60: expected `{`
166error [60; 60): expected expression 166error 60..60: expected expression
167error [61; 61): expected SEMICOLON 167error 61..61: expected SEMICOLON
168error [65; 65): expected pattern 168error 65..65: expected pattern
169error [65; 65): expected SEMICOLON 169error 65..65: expected SEMICOLON
170error [65; 65): expected expression 170error 65..65: expected expression
171error [92; 92): expected expression 171error 92..92: expected expression
172error [93; 93): expected SEMICOLON 172error 93..93: expected SEMICOLON
173error [93; 93): expected expression 173error 93..93: expected expression
174error [94; 94): expected SEMICOLON 174error 94..94: expected SEMICOLON
175error [95; 95): expected expression 175error 95..95: expected expression
176error [96; 96): expected SEMICOLON 176error 96..96: expected SEMICOLON
177error [96; 96): expected expression 177error 96..96: expected expression
178error [97; 97): expected SEMICOLON 178error 97..97: expected SEMICOLON
179error [103; 103): expected a name 179error 103..103: expected a name
180error [104; 104): expected `{` 180error 104..104: expected `{`
181error [108; 108): expected pattern 181error 108..108: expected pattern
182error [108; 108): expected SEMICOLON 182error 108..108: expected SEMICOLON
183error [108; 108): expected expression 183error 108..108: expected expression
diff --git a/crates/ra_syntax/test_data/parser/err/0023_mismatched_paren.rast b/crates/ra_syntax/test_data/parser/err/0023_mismatched_paren.rast
index 97abe9510..c37594146 100644
--- a/crates/ra_syntax/test_data/parser/err/0023_mismatched_paren.rast
+++ b/crates/ra_syntax/test_data/parser/err/0023_mismatched_paren.rast
@@ -1,44 +1,44 @@
1SOURCE_FILE@[0; 94) 1SOURCE_FILE@0..94
2 FN_DEF@[0; 55) 2 FN_DEF@0..55
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 7) 5 NAME@3..7
6 IDENT@[3; 7) "main" 6 IDENT@3..7 "main"
7 PARAM_LIST@[7; 9) 7 PARAM_LIST@7..9
8 L_PAREN@[7; 8) "(" 8 L_PAREN@7..8 "("
9 R_PAREN@[8; 9) ")" 9 R_PAREN@8..9 ")"
10 WHITESPACE@[9; 10) " " 10 WHITESPACE@9..10 " "
11 BLOCK_EXPR@[10; 55) 11 BLOCK_EXPR@10..55
12 BLOCK@[10; 55) 12 BLOCK@10..55
13 L_CURLY@[10; 11) "{" 13 L_CURLY@10..11 "{"
14 WHITESPACE@[11; 16) "\n " 14 WHITESPACE@11..16 "\n "
15 MACRO_CALL@[16; 49) 15 MACRO_CALL@16..49
16 PATH@[16; 19) 16 PATH@16..19
17 PATH_SEGMENT@[16; 19) 17 PATH_SEGMENT@16..19
18 NAME_REF@[16; 19) 18 NAME_REF@16..19
19 IDENT@[16; 19) "foo" 19 IDENT@16..19 "foo"
20 BANG@[19; 20) "!" 20 BANG@19..20 "!"
21 WHITESPACE@[20; 21) " " 21 WHITESPACE@20..21 " "
22 TOKEN_TREE@[21; 49) 22 TOKEN_TREE@21..49
23 L_PAREN@[21; 22) "(" 23 L_PAREN@21..22 "("
24 WHITESPACE@[22; 31) "\n " 24 WHITESPACE@22..31 "\n "
25 IDENT@[31; 34) "bar" 25 IDENT@31..34 "bar"
26 COMMA@[34; 35) "," 26 COMMA@34..35 ","
27 WHITESPACE@[35; 36) " " 27 WHITESPACE@35..36 " "
28 STRING@[36; 41) "\"baz\"" 28 STRING@36..41 "\"baz\""
29 COMMA@[41; 42) "," 29 COMMA@41..42 ","
30 WHITESPACE@[42; 43) " " 30 WHITESPACE@42..43 " "
31 INT_NUMBER@[43; 44) "1" 31 INT_NUMBER@43..44 "1"
32 COMMA@[44; 45) "," 32 COMMA@44..45 ","
33 WHITESPACE@[45; 46) " " 33 WHITESPACE@45..46 " "
34 FLOAT_NUMBER@[46; 49) "2.0" 34 FLOAT_NUMBER@46..49 "2.0"
35 WHITESPACE@[49; 54) "\n " 35 WHITESPACE@49..54 "\n "
36 R_CURLY@[54; 55) "}" 36 R_CURLY@54..55 "}"
37 WHITESPACE@[55; 56) " " 37 WHITESPACE@55..56 " "
38 COMMENT@[56; 91) "//~ ERROR incorrect c ..." 38 COMMENT@56..91 "//~ ERROR incorrect c ..."
39 WHITESPACE@[91; 92) "\n" 39 WHITESPACE@91..92 "\n"
40 ERROR@[92; 93) 40 ERROR@92..93
41 R_CURLY@[92; 93) "}" 41 R_CURLY@92..93 "}"
42 WHITESPACE@[93; 94) "\n" 42 WHITESPACE@93..94 "\n"
43error [49; 49): unmatched `}` 43error 49..49: unmatched `}`
44error [92; 92): unmatched `}` 44error 92..92: unmatched `}`
diff --git a/crates/ra_syntax/test_data/parser/err/0024_many_type_parens.rast b/crates/ra_syntax/test_data/parser/err/0024_many_type_parens.rast
index a3cf3e60a..4296355f2 100644
--- a/crates/ra_syntax/test_data/parser/err/0024_many_type_parens.rast
+++ b/crates/ra_syntax/test_data/parser/err/0024_many_type_parens.rast
@@ -1,321 +1,321 @@
1SOURCE_FILE@[0; 240) 1SOURCE_FILE@0..240
2 FN_DEF@[0; 53) 2 FN_DEF@0..53
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 4) 5 NAME@3..4
6 IDENT@[3; 4) "f" 6 IDENT@3..4 "f"
7 TYPE_PARAM_LIST@[4; 48) 7 TYPE_PARAM_LIST@4..48
8 L_ANGLE@[4; 5) "<" 8 L_ANGLE@4..5 "<"
9 TYPE_PARAM@[5; 47) 9 TYPE_PARAM@5..47
10 NAME@[5; 6) 10 NAME@5..6
11 IDENT@[5; 6) "T" 11 IDENT@5..6 "T"
12 COLON@[6; 7) ":" 12 COLON@6..7 ":"
13 WHITESPACE@[7; 8) " " 13 WHITESPACE@7..8 " "
14 TYPE_BOUND_LIST@[8; 47) 14 TYPE_BOUND_LIST@8..47
15 TYPE_BOUND@[8; 14) 15 TYPE_BOUND@8..14
16 L_PAREN@[8; 9) "(" 16 L_PAREN@8..9 "("
17 PATH_TYPE@[9; 13) 17 PATH_TYPE@9..13
18 PATH@[9; 13) 18 PATH@9..13
19 PATH_SEGMENT@[9; 13) 19 PATH_SEGMENT@9..13
20 NAME_REF@[9; 13) 20 NAME_REF@9..13
21 IDENT@[9; 13) "Copy" 21 IDENT@9..13 "Copy"
22 R_PAREN@[13; 14) ")" 22 R_PAREN@13..14 ")"
23 WHITESPACE@[14; 15) " " 23 WHITESPACE@14..15 " "
24 PLUS@[15; 16) "+" 24 PLUS@15..16 "+"
25 WHITESPACE@[16; 17) " " 25 WHITESPACE@16..17 " "
26 TYPE_BOUND@[17; 25) 26 TYPE_BOUND@17..25
27 L_PAREN@[17; 18) "(" 27 L_PAREN@17..18 "("
28 QUESTION@[18; 19) "?" 28 QUESTION@18..19 "?"
29 PATH_TYPE@[19; 24) 29 PATH_TYPE@19..24
30 PATH@[19; 24) 30 PATH@19..24
31 PATH_SEGMENT@[19; 24) 31 PATH_SEGMENT@19..24
32 NAME_REF@[19; 24) 32 NAME_REF@19..24
33 IDENT@[19; 24) "Sized" 33 IDENT@19..24 "Sized"
34 R_PAREN@[24; 25) ")" 34 R_PAREN@24..25 ")"
35 WHITESPACE@[25; 26) " " 35 WHITESPACE@25..26 " "
36 PLUS@[26; 27) "+" 36 PLUS@26..27 "+"
37 WHITESPACE@[27; 28) " " 37 WHITESPACE@27..28 " "
38 TYPE_BOUND@[28; 47) 38 TYPE_BOUND@28..47
39 L_PAREN@[28; 29) "(" 39 L_PAREN@28..29 "("
40 FOR_TYPE@[29; 46) 40 FOR_TYPE@29..46
41 FOR_KW@[29; 32) "for" 41 FOR_KW@29..32 "for"
42 TYPE_PARAM_LIST@[32; 36) 42 TYPE_PARAM_LIST@32..36
43 L_ANGLE@[32; 33) "<" 43 L_ANGLE@32..33 "<"
44 LIFETIME_PARAM@[33; 35) 44 LIFETIME_PARAM@33..35
45 LIFETIME@[33; 35) "\'a" 45 LIFETIME@33..35 "\'a"
46 R_ANGLE@[35; 36) ">" 46 R_ANGLE@35..36 ">"
47 WHITESPACE@[36; 37) " " 47 WHITESPACE@36..37 " "
48 PATH_TYPE@[37; 46) 48 PATH_TYPE@37..46
49 PATH@[37; 46) 49 PATH@37..46
50 PATH_SEGMENT@[37; 46) 50 PATH_SEGMENT@37..46
51 NAME_REF@[37; 42) 51 NAME_REF@37..42
52 IDENT@[37; 42) "Trait" 52 IDENT@37..42 "Trait"
53 TYPE_ARG_LIST@[42; 46) 53 TYPE_ARG_LIST@42..46
54 L_ANGLE@[42; 43) "<" 54 L_ANGLE@42..43 "<"
55 LIFETIME_ARG@[43; 45) 55 LIFETIME_ARG@43..45
56 LIFETIME@[43; 45) "\'a" 56 LIFETIME@43..45 "\'a"
57 R_ANGLE@[45; 46) ">" 57 R_ANGLE@45..46 ">"
58 R_PAREN@[46; 47) ")" 58 R_PAREN@46..47 ")"
59 R_ANGLE@[47; 48) ">" 59 R_ANGLE@47..48 ">"
60 PARAM_LIST@[48; 50) 60 PARAM_LIST@48..50
61 L_PAREN@[48; 49) "(" 61 L_PAREN@48..49 "("
62 R_PAREN@[49; 50) ")" 62 R_PAREN@49..50 ")"
63 WHITESPACE@[50; 51) " " 63 WHITESPACE@50..51 " "
64 BLOCK_EXPR@[51; 53) 64 BLOCK_EXPR@51..53
65 BLOCK@[51; 53) 65 BLOCK@51..53
66 L_CURLY@[51; 52) "{" 66 L_CURLY@51..52 "{"
67 R_CURLY@[52; 53) "}" 67 R_CURLY@52..53 "}"
68 WHITESPACE@[53; 55) "\n\n" 68 WHITESPACE@53..55 "\n\n"
69 FN_DEF@[55; 239) 69 FN_DEF@55..239
70 FN_KW@[55; 57) "fn" 70 FN_KW@55..57 "fn"
71 WHITESPACE@[57; 58) " " 71 WHITESPACE@57..58 " "
72 NAME@[58; 62) 72 NAME@58..62
73 IDENT@[58; 62) "main" 73 IDENT@58..62 "main"
74 PARAM_LIST@[62; 64) 74 PARAM_LIST@62..64
75 L_PAREN@[62; 63) "(" 75 L_PAREN@62..63 "("
76 R_PAREN@[63; 64) ")" 76 R_PAREN@63..64 ")"
77 WHITESPACE@[64; 65) " " 77 WHITESPACE@64..65 " "
78 BLOCK_EXPR@[65; 239) 78 BLOCK_EXPR@65..239
79 BLOCK@[65; 239) 79 BLOCK@65..239
80 L_CURLY@[65; 66) "{" 80 L_CURLY@65..66 "{"
81 WHITESPACE@[66; 71) "\n " 81 WHITESPACE@66..71 "\n "
82 LET_STMT@[71; 121) 82 LET_STMT@71..121
83 LET_KW@[71; 74) "let" 83 LET_KW@71..74 "let"
84 WHITESPACE@[74; 75) " " 84 WHITESPACE@74..75 " "
85 PLACEHOLDER_PAT@[75; 76) 85 PLACEHOLDER_PAT@75..76
86 UNDERSCORE@[75; 76) "_" 86 UNDERSCORE@75..76 "_"
87 COLON@[76; 77) ":" 87 COLON@76..77 ":"
88 WHITESPACE@[77; 78) " " 88 WHITESPACE@77..78 " "
89 DYN_TRAIT_TYPE@[78; 121) 89 DYN_TRAIT_TYPE@78..121
90 TYPE_BOUND_LIST@[78; 121) 90 TYPE_BOUND_LIST@78..121
91 TYPE_BOUND@[78; 88) 91 TYPE_BOUND@78..88
92 PATH_TYPE@[78; 88) 92 PATH_TYPE@78..88
93 PATH@[78; 88) 93 PATH@78..88
94 PATH_SEGMENT@[78; 88) 94 PATH_SEGMENT@78..88
95 NAME_REF@[78; 81) 95 NAME_REF@78..81
96 IDENT@[78; 81) "Box" 96 IDENT@78..81 "Box"
97 TYPE_ARG_LIST@[81; 88) 97 TYPE_ARG_LIST@81..88
98 L_ANGLE@[81; 82) "<" 98 L_ANGLE@81..82 "<"
99 TYPE_ARG@[82; 88) 99 TYPE_ARG@82..88
100 PAREN_TYPE@[82; 88) 100 PAREN_TYPE@82..88
101 L_PAREN@[82; 83) "(" 101 L_PAREN@82..83 "("
102 PATH_TYPE@[83; 87) 102 PATH_TYPE@83..87
103 PATH@[83; 87) 103 PATH@83..87
104 PATH_SEGMENT@[83; 87) 104 PATH_SEGMENT@83..87
105 NAME_REF@[83; 87) 105 NAME_REF@83..87
106 IDENT@[83; 87) "Copy" 106 IDENT@83..87 "Copy"
107 R_PAREN@[87; 88) ")" 107 R_PAREN@87..88 ")"
108 WHITESPACE@[88; 89) " " 108 WHITESPACE@88..89 " "
109 PLUS@[89; 90) "+" 109 PLUS@89..90 "+"
110 WHITESPACE@[90; 91) " " 110 WHITESPACE@90..91 " "
111 TYPE_BOUND@[91; 99) 111 TYPE_BOUND@91..99
112 L_PAREN@[91; 92) "(" 112 L_PAREN@91..92 "("
113 QUESTION@[92; 93) "?" 113 QUESTION@92..93 "?"
114 PATH_TYPE@[93; 98) 114 PATH_TYPE@93..98
115 PATH@[93; 98) 115 PATH@93..98
116 PATH_SEGMENT@[93; 98) 116 PATH_SEGMENT@93..98
117 NAME_REF@[93; 98) 117 NAME_REF@93..98
118 IDENT@[93; 98) "Sized" 118 IDENT@93..98 "Sized"
119 R_PAREN@[98; 99) ")" 119 R_PAREN@98..99 ")"
120 WHITESPACE@[99; 100) " " 120 WHITESPACE@99..100 " "
121 PLUS@[100; 101) "+" 121 PLUS@100..101 "+"
122 WHITESPACE@[101; 102) " " 122 WHITESPACE@101..102 " "
123 TYPE_BOUND@[102; 121) 123 TYPE_BOUND@102..121
124 L_PAREN@[102; 103) "(" 124 L_PAREN@102..103 "("
125 FOR_TYPE@[103; 120) 125 FOR_TYPE@103..120
126 FOR_KW@[103; 106) "for" 126 FOR_KW@103..106 "for"
127 TYPE_PARAM_LIST@[106; 110) 127 TYPE_PARAM_LIST@106..110
128 L_ANGLE@[106; 107) "<" 128 L_ANGLE@106..107 "<"
129 LIFETIME_PARAM@[107; 109) 129 LIFETIME_PARAM@107..109
130 LIFETIME@[107; 109) "\'a" 130 LIFETIME@107..109 "\'a"
131 R_ANGLE@[109; 110) ">" 131 R_ANGLE@109..110 ">"
132 WHITESPACE@[110; 111) " " 132 WHITESPACE@110..111 " "
133 PATH_TYPE@[111; 120) 133 PATH_TYPE@111..120
134 PATH@[111; 120) 134 PATH@111..120
135 PATH_SEGMENT@[111; 120) 135 PATH_SEGMENT@111..120
136 NAME_REF@[111; 116) 136 NAME_REF@111..116
137 IDENT@[111; 116) "Trait" 137 IDENT@111..116 "Trait"
138 TYPE_ARG_LIST@[116; 120) 138 TYPE_ARG_LIST@116..120
139 L_ANGLE@[116; 117) "<" 139 L_ANGLE@116..117 "<"
140 LIFETIME_ARG@[117; 119) 140 LIFETIME_ARG@117..119
141 LIFETIME@[117; 119) "\'a" 141 LIFETIME@117..119 "\'a"
142 R_ANGLE@[119; 120) ">" 142 R_ANGLE@119..120 ">"
143 R_PAREN@[120; 121) ")" 143 R_PAREN@120..121 ")"
144 EXPR_STMT@[121; 123) 144 EXPR_STMT@121..123
145 ERROR@[121; 122) 145 ERROR@121..122
146 R_ANGLE@[121; 122) ">" 146 R_ANGLE@121..122 ">"
147 SEMICOLON@[122; 123) ";" 147 SEMICOLON@122..123 ";"
148 WHITESPACE@[123; 128) "\n " 148 WHITESPACE@123..128 "\n "
149 LET_STMT@[128; 141) 149 LET_STMT@128..141
150 LET_KW@[128; 131) "let" 150 LET_KW@128..131 "let"
151 WHITESPACE@[131; 132) " " 151 WHITESPACE@131..132 " "
152 PLACEHOLDER_PAT@[132; 133) 152 PLACEHOLDER_PAT@132..133
153 UNDERSCORE@[132; 133) "_" 153 UNDERSCORE@132..133 "_"
154 COLON@[133; 134) ":" 154 COLON@133..134 ":"
155 WHITESPACE@[134; 135) " " 155 WHITESPACE@134..135 " "
156 PATH_TYPE@[135; 141) 156 PATH_TYPE@135..141
157 PATH@[135; 141) 157 PATH@135..141
158 PATH_SEGMENT@[135; 141) 158 PATH_SEGMENT@135..141
159 NAME_REF@[135; 138) 159 NAME_REF@135..138
160 IDENT@[135; 138) "Box" 160 IDENT@135..138 "Box"
161 TYPE_ARG_LIST@[138; 141) 161 TYPE_ARG_LIST@138..141
162 L_ANGLE@[138; 139) "<" 162 L_ANGLE@138..139 "<"
163 TYPE_ARG@[139; 141) 163 TYPE_ARG@139..141
164 PAREN_TYPE@[139; 141) 164 PAREN_TYPE@139..141
165 L_PAREN@[139; 140) "(" 165 L_PAREN@139..140 "("
166 ERROR@[140; 141) 166 ERROR@140..141
167 QUESTION@[140; 141) "?" 167 QUESTION@140..141 "?"
168 EXPR_STMT@[141; 146) 168 EXPR_STMT@141..146
169 PATH_EXPR@[141; 146) 169 PATH_EXPR@141..146
170 PATH@[141; 146) 170 PATH@141..146
171 PATH_SEGMENT@[141; 146) 171 PATH_SEGMENT@141..146
172 NAME_REF@[141; 146) 172 NAME_REF@141..146
173 IDENT@[141; 146) "Sized" 173 IDENT@141..146 "Sized"
174 EXPR_STMT@[146; 147) 174 EXPR_STMT@146..147
175 ERROR@[146; 147) 175 ERROR@146..147
176 R_PAREN@[146; 147) ")" 176 R_PAREN@146..147 ")"
177 WHITESPACE@[147; 148) " " 177 WHITESPACE@147..148 " "
178 EXPR_STMT@[148; 149) 178 EXPR_STMT@148..149
179 ERROR@[148; 149) 179 ERROR@148..149
180 PLUS@[148; 149) "+" 180 PLUS@148..149 "+"
181 WHITESPACE@[149; 150) " " 181 WHITESPACE@149..150 " "
182 EXPR_STMT@[150; 180) 182 EXPR_STMT@150..180
183 TUPLE_EXPR@[150; 180) 183 TUPLE_EXPR@150..180
184 L_PAREN@[150; 151) "(" 184 L_PAREN@150..151 "("
185 BIN_EXPR@[151; 180) 185 BIN_EXPR@151..180
186 BIN_EXPR@[151; 178) 186 BIN_EXPR@151..178
187 BIN_EXPR@[151; 169) 187 BIN_EXPR@151..169
188 BIN_EXPR@[151; 167) 188 BIN_EXPR@151..167
189 BIN_EXPR@[151; 164) 189 BIN_EXPR@151..164
190 FOR_EXPR@[151; 157) 190 FOR_EXPR@151..157
191 FOR_KW@[151; 154) "for" 191 FOR_KW@151..154 "for"
192 ERROR@[154; 155) 192 ERROR@154..155
193 L_ANGLE@[154; 155) "<" 193 L_ANGLE@154..155 "<"
194 ERROR@[155; 157) 194 ERROR@155..157
195 LIFETIME@[155; 157) "\'a" 195 LIFETIME@155..157 "\'a"
196 R_ANGLE@[157; 158) ">" 196 R_ANGLE@157..158 ">"
197 WHITESPACE@[158; 159) " " 197 WHITESPACE@158..159 " "
198 PATH_EXPR@[159; 164) 198 PATH_EXPR@159..164
199 PATH@[159; 164) 199 PATH@159..164
200 PATH_SEGMENT@[159; 164) 200 PATH_SEGMENT@159..164
201 NAME_REF@[159; 164) 201 NAME_REF@159..164
202 IDENT@[159; 164) "Trait" 202 IDENT@159..164 "Trait"
203 L_ANGLE@[164; 165) "<" 203 L_ANGLE@164..165 "<"
204 ERROR@[165; 167) 204 ERROR@165..167
205 LIFETIME@[165; 167) "\'a" 205 LIFETIME@165..167 "\'a"
206 R_ANGLE@[167; 168) ">" 206 R_ANGLE@167..168 ">"
207 ERROR@[168; 169) 207 ERROR@168..169
208 R_PAREN@[168; 169) ")" 208 R_PAREN@168..169 ")"
209 WHITESPACE@[169; 170) " " 209 WHITESPACE@169..170 " "
210 PLUS@[170; 171) "+" 210 PLUS@170..171 "+"
211 WHITESPACE@[171; 172) " " 211 WHITESPACE@171..172 " "
212 PAREN_EXPR@[172; 178) 212 PAREN_EXPR@172..178
213 L_PAREN@[172; 173) "(" 213 L_PAREN@172..173 "("
214 PATH_EXPR@[173; 177) 214 PATH_EXPR@173..177
215 PATH@[173; 177) 215 PATH@173..177
216 PATH_SEGMENT@[173; 177) 216 PATH_SEGMENT@173..177
217 NAME_REF@[173; 177) 217 NAME_REF@173..177
218 IDENT@[173; 177) "Copy" 218 IDENT@173..177 "Copy"
219 R_PAREN@[177; 178) ")" 219 R_PAREN@177..178 ")"
220 R_ANGLE@[178; 179) ">" 220 R_ANGLE@178..179 ">"
221 ERROR@[179; 180) 221 ERROR@179..180
222 SEMICOLON@[179; 180) ";" 222 SEMICOLON@179..180 ";"
223 WHITESPACE@[180; 185) "\n " 223 WHITESPACE@180..185 "\n "
224 LET_STMT@[185; 235) 224 LET_STMT@185..235
225 LET_KW@[185; 188) "let" 225 LET_KW@185..188 "let"
226 WHITESPACE@[188; 189) " " 226 WHITESPACE@188..189 " "
227 PLACEHOLDER_PAT@[189; 190) 227 PLACEHOLDER_PAT@189..190
228 UNDERSCORE@[189; 190) "_" 228 UNDERSCORE@189..190 "_"
229 COLON@[190; 191) ":" 229 COLON@190..191 ":"
230 WHITESPACE@[191; 192) " " 230 WHITESPACE@191..192 " "
231 DYN_TRAIT_TYPE@[192; 235) 231 DYN_TRAIT_TYPE@192..235
232 TYPE_BOUND_LIST@[192; 235) 232 TYPE_BOUND_LIST@192..235
233 TYPE_BOUND@[192; 215) 233 TYPE_BOUND@192..215
234 PATH_TYPE@[192; 215) 234 PATH_TYPE@192..215
235 PATH@[192; 215) 235 PATH@192..215
236 PATH_SEGMENT@[192; 215) 236 PATH_SEGMENT@192..215
237 NAME_REF@[192; 195) 237 NAME_REF@192..195
238 IDENT@[192; 195) "Box" 238 IDENT@192..195 "Box"
239 TYPE_ARG_LIST@[195; 215) 239 TYPE_ARG_LIST@195..215
240 L_ANGLE@[195; 196) "<" 240 L_ANGLE@195..196 "<"
241 TYPE_ARG@[196; 215) 241 TYPE_ARG@196..215
242 PAREN_TYPE@[196; 215) 242 PAREN_TYPE@196..215
243 L_PAREN@[196; 197) "(" 243 L_PAREN@196..197 "("
244 FOR_TYPE@[197; 214) 244 FOR_TYPE@197..214
245 FOR_KW@[197; 200) "for" 245 FOR_KW@197..200 "for"
246 TYPE_PARAM_LIST@[200; 204) 246 TYPE_PARAM_LIST@200..204
247 L_ANGLE@[200; 201) "<" 247 L_ANGLE@200..201 "<"
248 LIFETIME_PARAM@[201; 203) 248 LIFETIME_PARAM@201..203
249 LIFETIME@[201; 203) "\'a" 249 LIFETIME@201..203 "\'a"
250 R_ANGLE@[203; 204) ">" 250 R_ANGLE@203..204 ">"
251 WHITESPACE@[204; 205) " " 251 WHITESPACE@204..205 " "
252 PATH_TYPE@[205; 214) 252 PATH_TYPE@205..214
253 PATH@[205; 214) 253 PATH@205..214
254 PATH_SEGMENT@[205; 214) 254 PATH_SEGMENT@205..214
255 NAME_REF@[205; 210) 255 NAME_REF@205..210
256 IDENT@[205; 210) "Trait" 256 IDENT@205..210 "Trait"
257 TYPE_ARG_LIST@[210; 214) 257 TYPE_ARG_LIST@210..214
258 L_ANGLE@[210; 211) "<" 258 L_ANGLE@210..211 "<"
259 LIFETIME_ARG@[211; 213) 259 LIFETIME_ARG@211..213
260 LIFETIME@[211; 213) "\'a" 260 LIFETIME@211..213 "\'a"
261 R_ANGLE@[213; 214) ">" 261 R_ANGLE@213..214 ">"
262 R_PAREN@[214; 215) ")" 262 R_PAREN@214..215 ")"
263 WHITESPACE@[215; 216) " " 263 WHITESPACE@215..216 " "
264 PLUS@[216; 217) "+" 264 PLUS@216..217 "+"
265 WHITESPACE@[217; 218) " " 265 WHITESPACE@217..218 " "
266 TYPE_BOUND@[218; 224) 266 TYPE_BOUND@218..224
267 L_PAREN@[218; 219) "(" 267 L_PAREN@218..219 "("
268 PATH_TYPE@[219; 223) 268 PATH_TYPE@219..223
269 PATH@[219; 223) 269 PATH@219..223
270 PATH_SEGMENT@[219; 223) 270 PATH_SEGMENT@219..223
271 NAME_REF@[219; 223) 271 NAME_REF@219..223
272 IDENT@[219; 223) "Copy" 272 IDENT@219..223 "Copy"
273 R_PAREN@[223; 224) ")" 273 R_PAREN@223..224 ")"
274 WHITESPACE@[224; 225) " " 274 WHITESPACE@224..225 " "
275 PLUS@[225; 226) "+" 275 PLUS@225..226 "+"
276 WHITESPACE@[226; 227) " " 276 WHITESPACE@226..227 " "
277 TYPE_BOUND@[227; 235) 277 TYPE_BOUND@227..235
278 L_PAREN@[227; 228) "(" 278 L_PAREN@227..228 "("
279 QUESTION@[228; 229) "?" 279 QUESTION@228..229 "?"
280 PATH_TYPE@[229; 234) 280 PATH_TYPE@229..234
281 PATH@[229; 234) 281 PATH@229..234
282 PATH_SEGMENT@[229; 234) 282 PATH_SEGMENT@229..234
283 NAME_REF@[229; 234) 283 NAME_REF@229..234
284 IDENT@[229; 234) "Sized" 284 IDENT@229..234 "Sized"
285 R_PAREN@[234; 235) ")" 285 R_PAREN@234..235 ")"
286 EXPR_STMT@[235; 237) 286 EXPR_STMT@235..237
287 ERROR@[235; 236) 287 ERROR@235..236
288 R_ANGLE@[235; 236) ">" 288 R_ANGLE@235..236 ">"
289 SEMICOLON@[236; 237) ";" 289 SEMICOLON@236..237 ";"
290 WHITESPACE@[237; 238) "\n" 290 WHITESPACE@237..238 "\n"
291 R_CURLY@[238; 239) "}" 291 R_CURLY@238..239 "}"
292 WHITESPACE@[239; 240) "\n" 292 WHITESPACE@239..240 "\n"
293error [88; 88): expected COMMA 293error 88..88: expected COMMA
294error [88; 88): expected R_ANGLE 294error 88..88: expected R_ANGLE
295error [121; 121): expected SEMICOLON 295error 121..121: expected SEMICOLON
296error [121; 121): expected expression 296error 121..121: expected expression
297error [140; 140): expected type 297error 140..140: expected type
298error [141; 141): expected R_PAREN 298error 141..141: expected R_PAREN
299error [141; 141): expected COMMA 299error 141..141: expected COMMA
300error [141; 141): expected R_ANGLE 300error 141..141: expected R_ANGLE
301error [141; 141): expected SEMICOLON 301error 141..141: expected SEMICOLON
302error [146; 146): expected SEMICOLON 302error 146..146: expected SEMICOLON
303error [146; 146): expected expression 303error 146..146: expected expression
304error [147; 147): expected SEMICOLON 304error 147..147: expected SEMICOLON
305error [148; 148): expected expression 305error 148..148: expected expression
306error [149; 149): expected SEMICOLON 306error 149..149: expected SEMICOLON
307error [154; 154): expected pattern 307error 154..154: expected pattern
308error [155; 155): expected IN_KW 308error 155..155: expected IN_KW
309error [155; 155): expected expression 309error 155..155: expected expression
310error [157; 157): expected a block 310error 157..157: expected a block
311error [165; 165): expected expression 311error 165..165: expected expression
312error [168; 168): expected expression 312error 168..168: expected expression
313error [179; 179): expected expression 313error 179..179: expected expression
314error [180; 180): expected COMMA 314error 180..180: expected COMMA
315error [180; 180): expected expression 315error 180..180: expected expression
316error [180; 180): expected R_PAREN 316error 180..180: expected R_PAREN
317error [180; 180): expected SEMICOLON 317error 180..180: expected SEMICOLON
318error [215; 215): expected COMMA 318error 215..215: expected COMMA
319error [215; 215): expected R_ANGLE 319error 215..215: expected R_ANGLE
320error [235; 235): expected SEMICOLON 320error 235..235: expected SEMICOLON
321error [235; 235): expected expression 321error 235..235: expected expression
diff --git a/crates/ra_syntax/test_data/parser/err/0025_nope.rast b/crates/ra_syntax/test_data/parser/err/0025_nope.rast
index 2b37ce94d..195c08bd9 100644
--- a/crates/ra_syntax/test_data/parser/err/0025_nope.rast
+++ b/crates/ra_syntax/test_data/parser/err/0025_nope.rast
@@ -1,204 +1,204 @@
1SOURCE_FILE@[0; 575) 1SOURCE_FILE@0..575
2 FN_DEF@[0; 574) 2 FN_DEF@0..574
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 7) 5 NAME@3..7
6 IDENT@[3; 7) "main" 6 IDENT@3..7 "main"
7 PARAM_LIST@[7; 9) 7 PARAM_LIST@7..9
8 L_PAREN@[7; 8) "(" 8 L_PAREN@7..8 "("
9 R_PAREN@[8; 9) ")" 9 R_PAREN@8..9 ")"
10 WHITESPACE@[9; 10) " " 10 WHITESPACE@9..10 " "
11 BLOCK_EXPR@[10; 574) 11 BLOCK_EXPR@10..574
12 BLOCK@[10; 574) 12 BLOCK@10..574
13 L_CURLY@[10; 11) "{" 13 L_CURLY@10..11 "{"
14 WHITESPACE@[11; 16) "\n " 14 WHITESPACE@11..16 "\n "
15 ENUM_DEF@[16; 152) 15 ENUM_DEF@16..152
16 ENUM_KW@[16; 20) "enum" 16 ENUM_KW@16..20 "enum"
17 WHITESPACE@[20; 21) " " 17 WHITESPACE@20..21 " "
18 NAME@[21; 25) 18 NAME@21..25
19 IDENT@[21; 25) "Test" 19 IDENT@21..25 "Test"
20 WHITESPACE@[25; 26) " " 20 WHITESPACE@25..26 " "
21 ENUM_VARIANT_LIST@[26; 152) 21 ENUM_VARIANT_LIST@26..152
22 L_CURLY@[26; 27) "{" 22 L_CURLY@26..27 "{"
23 WHITESPACE@[27; 36) "\n " 23 WHITESPACE@27..36 "\n "
24 ENUM_VARIANT@[36; 40) 24 ENUM_VARIANT@36..40
25 NAME@[36; 40) 25 NAME@36..40
26 IDENT@[36; 40) "Var1" 26 IDENT@36..40 "Var1"
27 COMMA@[40; 41) "," 27 COMMA@40..41 ","
28 WHITESPACE@[41; 50) "\n " 28 WHITESPACE@41..50 "\n "
29 ENUM_VARIANT@[50; 62) 29 ENUM_VARIANT@50..62
30 NAME@[50; 54) 30 NAME@50..54
31 IDENT@[50; 54) "Var2" 31 IDENT@50..54 "Var2"
32 TUPLE_FIELD_DEF_LIST@[54; 62) 32 TUPLE_FIELD_DEF_LIST@54..62
33 L_PAREN@[54; 55) "(" 33 L_PAREN@54..55 "("
34 TUPLE_FIELD_DEF@[55; 61) 34 TUPLE_FIELD_DEF@55..61
35 PATH_TYPE@[55; 61) 35 PATH_TYPE@55..61
36 PATH@[55; 61) 36 PATH@55..61
37 PATH_SEGMENT@[55; 61) 37 PATH_SEGMENT@55..61
38 NAME_REF@[55; 61) 38 NAME_REF@55..61
39 IDENT@[55; 61) "String" 39 IDENT@55..61 "String"
40 R_PAREN@[61; 62) ")" 40 R_PAREN@61..62 ")"
41 COMMA@[62; 63) "," 41 COMMA@62..63 ","
42 WHITESPACE@[63; 72) "\n " 42 WHITESPACE@63..72 "\n "
43 ENUM_VARIANT@[72; 145) 43 ENUM_VARIANT@72..145
44 NAME@[72; 76) 44 NAME@72..76
45 IDENT@[72; 76) "Var3" 45 IDENT@72..76 "Var3"
46 WHITESPACE@[76; 77) " " 46 WHITESPACE@76..77 " "
47 RECORD_FIELD_DEF_LIST@[77; 145) 47 RECORD_FIELD_DEF_LIST@77..145
48 L_CURLY@[77; 78) "{" 48 L_CURLY@77..78 "{"
49 WHITESPACE@[78; 91) "\n " 49 WHITESPACE@78..91 "\n "
50 RECORD_FIELD_DEF@[91; 95) 50 RECORD_FIELD_DEF@91..95
51 NAME@[91; 94) 51 NAME@91..94
52 IDENT@[91; 94) "abc" 52 IDENT@91..94 "abc"
53 COLON@[94; 95) ":" 53 COLON@94..95 ":"
54 WHITESPACE@[95; 96) " " 54 WHITESPACE@95..96 " "
55 ERROR@[96; 98) 55 ERROR@96..98
56 L_CURLY@[96; 97) "{" 56 L_CURLY@96..97 "{"
57 R_CURLY@[97; 98) "}" 57 R_CURLY@97..98 "}"
58 ERROR@[98; 99) 58 ERROR@98..99
59 COMMA@[98; 99) "," 59 COMMA@98..99 ","
60 WHITESPACE@[99; 100) " " 60 WHITESPACE@99..100 " "
61 COMMENT@[100; 135) "//~ ERROR: expected t ..." 61 COMMENT@100..135 "//~ ERROR: expected t ..."
62 WHITESPACE@[135; 144) "\n " 62 WHITESPACE@135..144 "\n "
63 R_CURLY@[144; 145) "}" 63 R_CURLY@144..145 "}"
64 COMMA@[145; 146) "," 64 COMMA@145..146 ","
65 WHITESPACE@[146; 151) "\n " 65 WHITESPACE@146..151 "\n "
66 R_CURLY@[151; 152) "}" 66 R_CURLY@151..152 "}"
67 WHITESPACE@[152; 158) "\n\n " 67 WHITESPACE@152..158 "\n\n "
68 COMMENT@[158; 171) "// recover..." 68 COMMENT@158..171 "// recover..."
69 WHITESPACE@[171; 176) "\n " 69 WHITESPACE@171..176 "\n "
70 LET_STMT@[176; 186) 70 LET_STMT@176..186
71 LET_KW@[176; 179) "let" 71 LET_KW@176..179 "let"
72 WHITESPACE@[179; 180) " " 72 WHITESPACE@179..180 " "
73 BIND_PAT@[180; 181) 73 BIND_PAT@180..181
74 NAME@[180; 181) 74 NAME@180..181
75 IDENT@[180; 181) "a" 75 IDENT@180..181 "a"
76 WHITESPACE@[181; 182) " " 76 WHITESPACE@181..182 " "
77 EQ@[182; 183) "=" 77 EQ@182..183 "="
78 WHITESPACE@[183; 184) " " 78 WHITESPACE@183..184 " "
79 LITERAL@[184; 185) 79 LITERAL@184..185
80 INT_NUMBER@[184; 185) "1" 80 INT_NUMBER@184..185 "1"
81 SEMICOLON@[185; 186) ";" 81 SEMICOLON@185..186 ";"
82 WHITESPACE@[186; 191) "\n " 82 WHITESPACE@186..191 "\n "
83 ENUM_DEF@[191; 223) 83 ENUM_DEF@191..223
84 ENUM_KW@[191; 195) "enum" 84 ENUM_KW@191..195 "enum"
85 WHITESPACE@[195; 196) " " 85 WHITESPACE@195..196 " "
86 NAME@[196; 201) 86 NAME@196..201
87 IDENT@[196; 201) "Test2" 87 IDENT@196..201 "Test2"
88 WHITESPACE@[201; 202) " " 88 WHITESPACE@201..202 " "
89 ENUM_VARIANT_LIST@[202; 223) 89 ENUM_VARIANT_LIST@202..223
90 L_CURLY@[202; 203) "{" 90 L_CURLY@202..203 "{"
91 WHITESPACE@[203; 212) "\n " 91 WHITESPACE@203..212 "\n "
92 ENUM_VARIANT@[212; 216) 92 ENUM_VARIANT@212..216
93 NAME@[212; 216) 93 NAME@212..216
94 IDENT@[212; 216) "Fine" 94 IDENT@212..216 "Fine"
95 COMMA@[216; 217) "," 95 COMMA@216..217 ","
96 WHITESPACE@[217; 222) "\n " 96 WHITESPACE@217..222 "\n "
97 R_CURLY@[222; 223) "}" 97 R_CURLY@222..223 "}"
98 WHITESPACE@[223; 229) "\n\n " 98 WHITESPACE@223..229 "\n\n "
99 ENUM_DEF@[229; 300) 99 ENUM_DEF@229..300
100 ENUM_KW@[229; 233) "enum" 100 ENUM_KW@229..233 "enum"
101 WHITESPACE@[233; 234) " " 101 WHITESPACE@233..234 " "
102 NAME@[234; 239) 102 NAME@234..239
103 IDENT@[234; 239) "Test3" 103 IDENT@234..239 "Test3"
104 WHITESPACE@[239; 240) " " 104 WHITESPACE@239..240 " "
105 ENUM_VARIANT_LIST@[240; 300) 105 ENUM_VARIANT_LIST@240..300
106 L_CURLY@[240; 241) "{" 106 L_CURLY@240..241 "{"
107 WHITESPACE@[241; 250) "\n " 107 WHITESPACE@241..250 "\n "
108 ENUM_VARIANT@[250; 293) 108 ENUM_VARIANT@250..293
109 NAME@[250; 259) 109 NAME@250..259
110 IDENT@[250; 259) "StillFine" 110 IDENT@250..259 "StillFine"
111 WHITESPACE@[259; 260) " " 111 WHITESPACE@259..260 " "
112 RECORD_FIELD_DEF_LIST@[260; 293) 112 RECORD_FIELD_DEF_LIST@260..293
113 L_CURLY@[260; 261) "{" 113 L_CURLY@260..261 "{"
114 WHITESPACE@[261; 274) "\n " 114 WHITESPACE@261..274 "\n "
115 RECORD_FIELD_DEF@[274; 282) 115 RECORD_FIELD_DEF@274..282
116 NAME@[274; 277) 116 NAME@274..277
117 IDENT@[274; 277) "def" 117 IDENT@274..277 "def"
118 COLON@[277; 278) ":" 118 COLON@277..278 ":"
119 WHITESPACE@[278; 279) " " 119 WHITESPACE@278..279 " "
120 PATH_TYPE@[279; 282) 120 PATH_TYPE@279..282
121 PATH@[279; 282) 121 PATH@279..282
122 PATH_SEGMENT@[279; 282) 122 PATH_SEGMENT@279..282
123 NAME_REF@[279; 282) 123 NAME_REF@279..282
124 IDENT@[279; 282) "i32" 124 IDENT@279..282 "i32"
125 COMMA@[282; 283) "," 125 COMMA@282..283 ","
126 WHITESPACE@[283; 292) "\n " 126 WHITESPACE@283..292 "\n "
127 R_CURLY@[292; 293) "}" 127 R_CURLY@292..293 "}"
128 COMMA@[293; 294) "," 128 COMMA@293..294 ","
129 WHITESPACE@[294; 299) "\n " 129 WHITESPACE@294..299 "\n "
130 R_CURLY@[299; 300) "}" 130 R_CURLY@299..300 "}"
131 WHITESPACE@[300; 306) "\n\n " 131 WHITESPACE@300..306 "\n\n "
132 EXPR_STMT@[306; 459) 132 EXPR_STMT@306..459
133 BLOCK_EXPR@[306; 459) 133 BLOCK_EXPR@306..459
134 BLOCK@[306; 459) 134 BLOCK@306..459
135 L_CURLY@[306; 307) "{" 135 L_CURLY@306..307 "{"
136 WHITESPACE@[307; 316) "\n " 136 WHITESPACE@307..316 "\n "
137 ENUM_DEF@[316; 453) 137 ENUM_DEF@316..453
138 COMMENT@[316; 329) "// fail again" 138 COMMENT@316..329 "// fail again"
139 WHITESPACE@[329; 338) "\n " 139 WHITESPACE@329..338 "\n "
140 ENUM_KW@[338; 342) "enum" 140 ENUM_KW@338..342 "enum"
141 WHITESPACE@[342; 343) " " 141 WHITESPACE@342..343 " "
142 NAME@[343; 348) 142 NAME@343..348
143 IDENT@[343; 348) "Test4" 143 IDENT@343..348 "Test4"
144 WHITESPACE@[348; 349) " " 144 WHITESPACE@348..349 " "
145 ENUM_VARIANT_LIST@[349; 453) 145 ENUM_VARIANT_LIST@349..453
146 L_CURLY@[349; 350) "{" 146 L_CURLY@349..350 "{"
147 WHITESPACE@[350; 363) "\n " 147 WHITESPACE@350..363 "\n "
148 ENUM_VARIANT@[363; 372) 148 ENUM_VARIANT@363..372
149 NAME@[363; 367) 149 NAME@363..367
150 IDENT@[363; 367) "Nope" 150 IDENT@363..367 "Nope"
151 TUPLE_FIELD_DEF_LIST@[367; 372) 151 TUPLE_FIELD_DEF_LIST@367..372
152 L_PAREN@[367; 368) "(" 152 L_PAREN@367..368 "("
153 TUPLE_FIELD_DEF@[368; 371) 153 TUPLE_FIELD_DEF@368..371
154 PATH_TYPE@[368; 371) 154 PATH_TYPE@368..371
155 PATH@[368; 371) 155 PATH@368..371
156 PATH_SEGMENT@[368; 371) 156 PATH_SEGMENT@368..371
157 NAME_REF@[368; 371) 157 NAME_REF@368..371
158 IDENT@[368; 371) "i32" 158 IDENT@368..371 "i32"
159 WHITESPACE@[371; 372) " " 159 WHITESPACE@371..372 " "
160 ERROR@[372; 372) 160 ERROR@372..372
161 ERROR@[372; 374) 161 ERROR@372..374
162 L_CURLY@[372; 373) "{" 162 L_CURLY@372..373 "{"
163 R_CURLY@[373; 374) "}" 163 R_CURLY@373..374 "}"
164 ERROR@[374; 375) 164 ERROR@374..375
165 R_PAREN@[374; 375) ")" 165 R_PAREN@374..375 ")"
166 WHITESPACE@[375; 376) " " 166 WHITESPACE@375..376 " "
167 COMMENT@[376; 396) "//~ ERROR: found `{`" 167 COMMENT@376..396 "//~ ERROR: found `{`"
168 WHITESPACE@[396; 422) "\n ..." 168 WHITESPACE@396..422 "\n ..."
169 COMMENT@[422; 443) "//~^ ERROR: found `{`" 169 COMMENT@422..443 "//~^ ERROR: found `{`"
170 WHITESPACE@[443; 452) "\n " 170 WHITESPACE@443..452 "\n "
171 R_CURLY@[452; 453) "}" 171 R_CURLY@452..453 "}"
172 WHITESPACE@[453; 458) "\n " 172 WHITESPACE@453..458 "\n "
173 R_CURLY@[458; 459) "}" 173 R_CURLY@458..459 "}"
174 WHITESPACE@[459; 464) "\n " 174 WHITESPACE@459..464 "\n "
175 COMMENT@[464; 486) "// still recover later" 175 COMMENT@464..486 "// still recover later"
176 WHITESPACE@[486; 491) "\n " 176 WHITESPACE@486..491 "\n "
177 LET_STMT@[491; 510) 177 LET_STMT@491..510
178 LET_KW@[491; 494) "let" 178 LET_KW@491..494 "let"
179 WHITESPACE@[494; 495) " " 179 WHITESPACE@494..495 " "
180 BIND_PAT@[495; 505) 180 BIND_PAT@495..505
181 NAME@[495; 505) 181 NAME@495..505
182 IDENT@[495; 505) "bad_syntax" 182 IDENT@495..505 "bad_syntax"
183 WHITESPACE@[505; 506) " " 183 WHITESPACE@505..506 " "
184 EQ@[506; 507) "=" 184 EQ@506..507 "="
185 WHITESPACE@[507; 508) " " 185 WHITESPACE@507..508 " "
186 ERROR@[508; 509) 186 ERROR@508..509
187 UNDERSCORE@[508; 509) "_" 187 UNDERSCORE@508..509 "_"
188 SEMICOLON@[509; 510) ";" 188 SEMICOLON@509..510 ";"
189 WHITESPACE@[510; 511) " " 189 WHITESPACE@510..511 " "
190 COMMENT@[511; 572) "//~ ERROR: expected e ..." 190 COMMENT@511..572 "//~ ERROR: expected e ..."
191 WHITESPACE@[572; 573) "\n" 191 WHITESPACE@572..573 "\n"
192 R_CURLY@[573; 574) "}" 192 R_CURLY@573..574 "}"
193 WHITESPACE@[574; 575) "\n" 193 WHITESPACE@574..575 "\n"
194error [95; 95): expected type 194error 95..95: expected type
195error [95; 95): expected COMMA 195error 95..95: expected COMMA
196error [96; 96): expected field 196error 96..96: expected field
197error [98; 98): expected field declaration 197error 98..98: expected field declaration
198error [371; 371): expected COMMA 198error 371..371: expected COMMA
199error [372; 372): expected a type 199error 372..372: expected a type
200error [372; 372): expected R_PAREN 200error 372..372: expected R_PAREN
201error [372; 372): expected COMMA 201error 372..372: expected COMMA
202error [372; 372): expected enum variant 202error 372..372: expected enum variant
203error [374; 374): expected enum variant 203error 374..374: expected enum variant
204error [508; 508): expected expression 204error 508..508: expected expression
diff --git a/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast b/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
index f239b7b1e..bf07409fb 100644
--- a/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
+++ b/crates/ra_syntax/test_data/parser/err/0026_imp_recovery.rast
@@ -1,49 +1,49 @@
1SOURCE_FILE@[0; 38) 1SOURCE_FILE@0..38
2 IMPL_DEF@[0; 14) 2 IMPL_DEF@0..14
3 IMPL_KW@[0; 4) "impl" 3 IMPL_KW@0..4 "impl"
4 TYPE_PARAM_LIST@[4; 14) 4 TYPE_PARAM_LIST@4..14
5 L_ANGLE@[4; 5) "<" 5 L_ANGLE@4..5 "<"
6 TYPE_PARAM@[5; 13) 6 TYPE_PARAM@5..13
7 NAME@[5; 6) 7 NAME@5..6
8 IDENT@[5; 6) "T" 8 IDENT@5..6 "T"
9 COLON@[6; 7) ":" 9 COLON@6..7 ":"
10 WHITESPACE@[7; 8) " " 10 WHITESPACE@7..8 " "
11 TYPE_BOUND_LIST@[8; 13) 11 TYPE_BOUND_LIST@8..13
12 TYPE_BOUND@[8; 13) 12 TYPE_BOUND@8..13
13 PATH_TYPE@[8; 13) 13 PATH_TYPE@8..13
14 PATH@[8; 13) 14 PATH@8..13
15 PATH_SEGMENT@[8; 13) 15 PATH_SEGMENT@8..13
16 NAME_REF@[8; 13) 16 NAME_REF@8..13
17 IDENT@[8; 13) "Clone" 17 IDENT@8..13 "Clone"
18 R_ANGLE@[13; 14) ">" 18 R_ANGLE@13..14 ">"
19 WHITESPACE@[14; 15) "\n" 19 WHITESPACE@14..15 "\n"
20 IMPL_DEF@[15; 37) 20 IMPL_DEF@15..37
21 IMPL_KW@[15; 19) "impl" 21 IMPL_KW@15..19 "impl"
22 TYPE_PARAM_LIST@[19; 22) 22 TYPE_PARAM_LIST@19..22
23 L_ANGLE@[19; 20) "<" 23 L_ANGLE@19..20 "<"
24 TYPE_PARAM@[20; 21) 24 TYPE_PARAM@20..21
25 NAME@[20; 21) 25 NAME@20..21
26 IDENT@[20; 21) "T" 26 IDENT@20..21 "T"
27 R_ANGLE@[21; 22) ">" 27 R_ANGLE@21..22 ">"
28 WHITESPACE@[22; 23) " " 28 WHITESPACE@22..23 " "
29 PATH_TYPE@[23; 34) 29 PATH_TYPE@23..34
30 PATH@[23; 34) 30 PATH@23..34
31 PATH_SEGMENT@[23; 34) 31 PATH_SEGMENT@23..34
32 NAME_REF@[23; 31) 32 NAME_REF@23..31
33 IDENT@[23; 31) "OnceCell" 33 IDENT@23..31 "OnceCell"
34 TYPE_ARG_LIST@[31; 34) 34 TYPE_ARG_LIST@31..34
35 L_ANGLE@[31; 32) "<" 35 L_ANGLE@31..32 "<"
36 TYPE_ARG@[32; 33) 36 TYPE_ARG@32..33
37 PATH_TYPE@[32; 33) 37 PATH_TYPE@32..33
38 PATH@[32; 33) 38 PATH@32..33
39 PATH_SEGMENT@[32; 33) 39 PATH_SEGMENT@32..33
40 NAME_REF@[32; 33) 40 NAME_REF@32..33
41 IDENT@[32; 33) "T" 41 IDENT@32..33 "T"
42 R_ANGLE@[33; 34) ">" 42 R_ANGLE@33..34 ">"
43 WHITESPACE@[34; 35) " " 43 WHITESPACE@34..35 " "
44 ITEM_LIST@[35; 37) 44 ITEM_LIST@35..37
45 L_CURLY@[35; 36) "{" 45 L_CURLY@35..36 "{"
46 R_CURLY@[36; 37) "}" 46 R_CURLY@36..37 "}"
47 WHITESPACE@[37; 38) "\n" 47 WHITESPACE@37..38 "\n"
48error [14; 14): expected trait or type 48error 14..14: expected trait or type
49error [14; 14): expected `{` 49error 14..14: expected `{`
diff --git a/crates/ra_syntax/test_data/parser/err/0027_incomplere_where_for.rast b/crates/ra_syntax/test_data/parser/err/0027_incomplere_where_for.rast
index 4a28bcabf..f2fada510 100644
--- a/crates/ra_syntax/test_data/parser/err/0027_incomplere_where_for.rast
+++ b/crates/ra_syntax/test_data/parser/err/0027_incomplere_where_for.rast
@@ -1,29 +1,29 @@
1SOURCE_FILE@[0; 30) 1SOURCE_FILE@0..30
2 FN_DEF@[0; 29) 2 FN_DEF@0..29
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 13) "\n " 10 WHITESPACE@8..13 "\n "
11 WHERE_CLAUSE@[13; 26) 11 WHERE_CLAUSE@13..26
12 WHERE_KW@[13; 18) "where" 12 WHERE_KW@13..18 "where"
13 WHITESPACE@[18; 19) " " 13 WHITESPACE@18..19 " "
14 WHERE_PRED@[19; 26) 14 WHERE_PRED@19..26
15 FOR_TYPE@[19; 26) 15 FOR_TYPE@19..26
16 FOR_KW@[19; 22) "for" 16 FOR_KW@19..22 "for"
17 TYPE_PARAM_LIST@[22; 26) 17 TYPE_PARAM_LIST@22..26
18 L_ANGLE@[22; 23) "<" 18 L_ANGLE@22..23 "<"
19 LIFETIME_PARAM@[23; 25) 19 LIFETIME_PARAM@23..25
20 LIFETIME@[23; 25) "\'a" 20 LIFETIME@23..25 "\'a"
21 R_ANGLE@[25; 26) ">" 21 R_ANGLE@25..26 ">"
22 WHITESPACE@[26; 27) "\n" 22 WHITESPACE@26..27 "\n"
23 BLOCK_EXPR@[27; 29) 23 BLOCK_EXPR@27..29
24 BLOCK@[27; 29) 24 BLOCK@27..29
25 L_CURLY@[27; 28) "{" 25 L_CURLY@27..28 "{"
26 R_CURLY@[28; 29) "}" 26 R_CURLY@28..29 "}"
27 WHITESPACE@[29; 30) "\n" 27 WHITESPACE@29..30 "\n"
28error [26; 26): expected a path 28error 26..26: expected a path
29error [26; 26): expected colon 29error 26..26: expected colon
diff --git a/crates/ra_syntax/test_data/parser/err/0029_field_completion.rast b/crates/ra_syntax/test_data/parser/err/0029_field_completion.rast
index 177849476..56682f966 100644
--- a/crates/ra_syntax/test_data/parser/err/0029_field_completion.rast
+++ b/crates/ra_syntax/test_data/parser/err/0029_field_completion.rast
@@ -1,36 +1,36 @@
1SOURCE_FILE@[0; 24) 1SOURCE_FILE@0..24
2 FN_DEF@[0; 23) 2 FN_DEF@0..23
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 12) 7 PARAM_LIST@6..12
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 PARAM@[7; 11) 9 PARAM@7..11
10 BIND_PAT@[7; 8) 10 BIND_PAT@7..8
11 NAME@[7; 8) 11 NAME@7..8
12 IDENT@[7; 8) "a" 12 IDENT@7..8 "a"
13 COLON@[8; 9) ":" 13 COLON@8..9 ":"
14 WHITESPACE@[9; 10) " " 14 WHITESPACE@9..10 " "
15 PATH_TYPE@[10; 11) 15 PATH_TYPE@10..11
16 PATH@[10; 11) 16 PATH@10..11
17 PATH_SEGMENT@[10; 11) 17 PATH_SEGMENT@10..11
18 NAME_REF@[10; 11) 18 NAME_REF@10..11
19 IDENT@[10; 11) "A" 19 IDENT@10..11 "A"
20 R_PAREN@[11; 12) ")" 20 R_PAREN@11..12 ")"
21 WHITESPACE@[12; 13) " " 21 WHITESPACE@12..13 " "
22 BLOCK_EXPR@[13; 23) 22 BLOCK_EXPR@13..23
23 BLOCK@[13; 23) 23 BLOCK@13..23
24 L_CURLY@[13; 14) "{" 24 L_CURLY@13..14 "{"
25 WHITESPACE@[14; 19) "\n " 25 WHITESPACE@14..19 "\n "
26 FIELD_EXPR@[19; 21) 26 FIELD_EXPR@19..21
27 PATH_EXPR@[19; 20) 27 PATH_EXPR@19..20
28 PATH@[19; 20) 28 PATH@19..20
29 PATH_SEGMENT@[19; 20) 29 PATH_SEGMENT@19..20
30 NAME_REF@[19; 20) 30 NAME_REF@19..20
31 IDENT@[19; 20) "a" 31 IDENT@19..20 "a"
32 DOT@[20; 21) "." 32 DOT@20..21 "."
33 WHITESPACE@[21; 22) "\n" 33 WHITESPACE@21..22 "\n"
34 R_CURLY@[22; 23) "}" 34 R_CURLY@22..23 "}"
35 WHITESPACE@[23; 24) "\n" 35 WHITESPACE@23..24 "\n"
36error [21; 21): expected field name or number 36error 21..21: expected field name or number
diff --git a/crates/ra_syntax/test_data/parser/err/0031_block_inner_attrs.rast b/crates/ra_syntax/test_data/parser/err/0031_block_inner_attrs.rast
index 00d9fd511..aac476430 100644
--- a/crates/ra_syntax/test_data/parser/err/0031_block_inner_attrs.rast
+++ b/crates/ra_syntax/test_data/parser/err/0031_block_inner_attrs.rast
@@ -1,125 +1,125 @@
1SOURCE_FILE@[0; 350) 1SOURCE_FILE@0..350
2 FN_DEF@[0; 349) 2 FN_DEF@0..349
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 8) 5 NAME@3..8
6 IDENT@[3; 8) "block" 6 IDENT@3..8 "block"
7 PARAM_LIST@[8; 10) 7 PARAM_LIST@8..10
8 L_PAREN@[8; 9) "(" 8 L_PAREN@8..9 "("
9 R_PAREN@[9; 10) ")" 9 R_PAREN@9..10 ")"
10 WHITESPACE@[10; 11) " " 10 WHITESPACE@10..11 " "
11 BLOCK_EXPR@[11; 349) 11 BLOCK_EXPR@11..349
12 BLOCK@[11; 349) 12 BLOCK@11..349
13 L_CURLY@[11; 12) "{" 13 L_CURLY@11..12 "{"
14 WHITESPACE@[12; 17) "\n " 14 WHITESPACE@12..17 "\n "
15 LET_STMT@[17; 129) 15 LET_STMT@17..129
16 LET_KW@[17; 20) "let" 16 LET_KW@17..20 "let"
17 WHITESPACE@[20; 21) " " 17 WHITESPACE@20..21 " "
18 BIND_PAT@[21; 26) 18 BIND_PAT@21..26
19 NAME@[21; 26) 19 NAME@21..26
20 IDENT@[21; 26) "inner" 20 IDENT@21..26 "inner"
21 WHITESPACE@[26; 27) " " 21 WHITESPACE@26..27 " "
22 EQ@[27; 28) "=" 22 EQ@27..28 "="
23 WHITESPACE@[28; 29) " " 23 WHITESPACE@28..29 " "
24 BLOCK_EXPR@[29; 128) 24 BLOCK_EXPR@29..128
25 BLOCK@[29; 128) 25 BLOCK@29..128
26 L_CURLY@[29; 30) "{" 26 L_CURLY@29..30 "{"
27 WHITESPACE@[30; 39) "\n " 27 WHITESPACE@30..39 "\n "
28 ATTR@[39; 83) 28 ATTR@39..83
29 POUND@[39; 40) "#" 29 POUND@39..40 "#"
30 BANG@[40; 41) "!" 30 BANG@40..41 "!"
31 L_BRACK@[41; 42) "[" 31 L_BRACK@41..42 "["
32 PATH@[42; 45) 32 PATH@42..45
33 PATH_SEGMENT@[42; 45) 33 PATH_SEGMENT@42..45
34 NAME_REF@[42; 45) 34 NAME_REF@42..45
35 IDENT@[42; 45) "doc" 35 IDENT@42..45 "doc"
36 TOKEN_TREE@[45; 82) 36 TOKEN_TREE@45..82
37 L_PAREN@[45; 46) "(" 37 L_PAREN@45..46 "("
38 STRING@[46; 81) "\"Inner attributes not ..." 38 STRING@46..81 "\"Inner attributes not ..."
39 R_PAREN@[81; 82) ")" 39 R_PAREN@81..82 ")"
40 R_BRACK@[82; 83) "]" 40 R_BRACK@82..83 "]"
41 WHITESPACE@[83; 92) "\n " 41 WHITESPACE@83..92 "\n "
42 COMMENT@[92; 122) "//! Nor are ModuleDoc ..." 42 COMMENT@92..122 "//! Nor are ModuleDoc ..."
43 WHITESPACE@[122; 127) "\n " 43 WHITESPACE@122..127 "\n "
44 R_CURLY@[127; 128) "}" 44 R_CURLY@127..128 "}"
45 SEMICOLON@[128; 129) ";" 45 SEMICOLON@128..129 ";"
46 WHITESPACE@[129; 134) "\n " 46 WHITESPACE@129..134 "\n "
47 EXPR_STMT@[134; 257) 47 EXPR_STMT@134..257
48 IF_EXPR@[134; 257) 48 IF_EXPR@134..257
49 IF_KW@[134; 136) "if" 49 IF_KW@134..136 "if"
50 WHITESPACE@[136; 137) " " 50 WHITESPACE@136..137 " "
51 CONDITION@[137; 141) 51 CONDITION@137..141
52 LITERAL@[137; 141) 52 LITERAL@137..141
53 TRUE_KW@[137; 141) "true" 53 TRUE_KW@137..141 "true"
54 WHITESPACE@[141; 142) " " 54 WHITESPACE@141..142 " "
55 BLOCK_EXPR@[142; 257) 55 BLOCK_EXPR@142..257
56 BLOCK@[142; 257) 56 BLOCK@142..257
57 L_CURLY@[142; 143) "{" 57 L_CURLY@142..143 "{"
58 WHITESPACE@[143; 152) "\n " 58 WHITESPACE@143..152 "\n "
59 ATTR@[152; 171) 59 ATTR@152..171
60 POUND@[152; 153) "#" 60 POUND@152..153 "#"
61 BANG@[153; 154) "!" 61 BANG@153..154 "!"
62 L_BRACK@[154; 155) "[" 62 L_BRACK@154..155 "["
63 PATH@[155; 158) 63 PATH@155..158
64 PATH_SEGMENT@[155; 158) 64 PATH_SEGMENT@155..158
65 NAME_REF@[155; 158) 65 NAME_REF@155..158
66 IDENT@[155; 158) "doc" 66 IDENT@155..158 "doc"
67 TOKEN_TREE@[158; 170) 67 TOKEN_TREE@158..170
68 L_PAREN@[158; 159) "(" 68 L_PAREN@158..159 "("
69 STRING@[159; 169) "\"Nor here\"" 69 STRING@159..169 "\"Nor here\""
70 R_PAREN@[169; 170) ")" 70 R_PAREN@169..170 ")"
71 R_BRACK@[170; 171) "]" 71 R_BRACK@170..171 "]"
72 WHITESPACE@[171; 180) "\n " 72 WHITESPACE@171..180 "\n "
73 ATTR@[180; 212) 73 ATTR@180..212
74 POUND@[180; 181) "#" 74 POUND@180..181 "#"
75 BANG@[181; 182) "!" 75 BANG@181..182 "!"
76 L_BRACK@[182; 183) "[" 76 L_BRACK@182..183 "["
77 PATH@[183; 186) 77 PATH@183..186
78 PATH_SEGMENT@[183; 186) 78 PATH_SEGMENT@183..186
79 NAME_REF@[183; 186) 79 NAME_REF@183..186
80 IDENT@[183; 186) "doc" 80 IDENT@183..186 "doc"
81 TOKEN_TREE@[186; 211) 81 TOKEN_TREE@186..211
82 L_PAREN@[186; 187) "(" 82 L_PAREN@186..187 "("
83 STRING@[187; 210) "\"We error on each attr\"" 83 STRING@187..210 "\"We error on each attr\""
84 R_PAREN@[210; 211) ")" 84 R_PAREN@210..211 ")"
85 R_BRACK@[211; 212) "]" 85 R_BRACK@211..212 "]"
86 WHITESPACE@[212; 221) "\n " 86 WHITESPACE@212..221 "\n "
87 COMMENT@[221; 251) "//! Nor are ModuleDoc ..." 87 COMMENT@221..251 "//! Nor are ModuleDoc ..."
88 WHITESPACE@[251; 256) "\n " 88 WHITESPACE@251..256 "\n "
89 R_CURLY@[256; 257) "}" 89 R_CURLY@256..257 "}"
90 WHITESPACE@[257; 262) "\n " 90 WHITESPACE@257..262 "\n "
91 WHILE_EXPR@[262; 347) 91 WHILE_EXPR@262..347
92 WHILE_KW@[262; 267) "while" 92 WHILE_KW@262..267 "while"
93 WHITESPACE@[267; 268) " " 93 WHITESPACE@267..268 " "
94 CONDITION@[268; 272) 94 CONDITION@268..272
95 LITERAL@[268; 272) 95 LITERAL@268..272
96 TRUE_KW@[268; 272) "true" 96 TRUE_KW@268..272 "true"
97 WHITESPACE@[272; 273) " " 97 WHITESPACE@272..273 " "
98 BLOCK_EXPR@[273; 347) 98 BLOCK_EXPR@273..347
99 BLOCK@[273; 347) 99 BLOCK@273..347
100 L_CURLY@[273; 274) "{" 100 L_CURLY@273..274 "{"
101 WHITESPACE@[274; 283) "\n " 101 WHITESPACE@274..283 "\n "
102 ATTR@[283; 302) 102 ATTR@283..302
103 POUND@[283; 284) "#" 103 POUND@283..284 "#"
104 BANG@[284; 285) "!" 104 BANG@284..285 "!"
105 L_BRACK@[285; 286) "[" 105 L_BRACK@285..286 "["
106 PATH@[286; 289) 106 PATH@286..289
107 PATH_SEGMENT@[286; 289) 107 PATH_SEGMENT@286..289
108 NAME_REF@[286; 289) 108 NAME_REF@286..289
109 IDENT@[286; 289) "doc" 109 IDENT@286..289 "doc"
110 TOKEN_TREE@[289; 301) 110 TOKEN_TREE@289..301
111 L_PAREN@[289; 290) "(" 111 L_PAREN@289..290 "("
112 STRING@[290; 300) "\"Nor here\"" 112 STRING@290..300 "\"Nor here\""
113 R_PAREN@[300; 301) ")" 113 R_PAREN@300..301 ")"
114 R_BRACK@[301; 302) "]" 114 R_BRACK@301..302 "]"
115 WHITESPACE@[302; 311) "\n " 115 WHITESPACE@302..311 "\n "
116 COMMENT@[311; 341) "//! Nor are ModuleDoc ..." 116 COMMENT@311..341 "//! Nor are ModuleDoc ..."
117 WHITESPACE@[341; 346) "\n " 117 WHITESPACE@341..346 "\n "
118 R_CURLY@[346; 347) "}" 118 R_CURLY@346..347 "}"
119 WHITESPACE@[347; 348) "\n" 119 WHITESPACE@347..348 "\n"
120 R_CURLY@[348; 349) "}" 120 R_CURLY@348..349 "}"
121 WHITESPACE@[349; 350) "\n" 121 WHITESPACE@349..350 "\n"
122error [39; 83): A block in this position cannot accept inner attributes 122error 39..83: A block in this position cannot accept inner attributes
123error [152; 171): A block in this position cannot accept inner attributes 123error 152..171: A block in this position cannot accept inner attributes
124error [180; 212): A block in this position cannot accept inner attributes 124error 180..212: A block in this position cannot accept inner attributes
125error [283; 302): A block in this position cannot accept inner attributes 125error 283..302: A block in this position cannot accept inner attributes
diff --git a/crates/ra_syntax/test_data/parser/err/0032_match_arms_inner_attrs.rast b/crates/ra_syntax/test_data/parser/err/0032_match_arms_inner_attrs.rast
index b80101e60..f98de7f15 100644
--- a/crates/ra_syntax/test_data/parser/err/0032_match_arms_inner_attrs.rast
+++ b/crates/ra_syntax/test_data/parser/err/0032_match_arms_inner_attrs.rast
@@ -1,204 +1,204 @@
1SOURCE_FILE@[0; 293) 1SOURCE_FILE@0..293
2 FN_DEF@[0; 292) 2 FN_DEF@0..292
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 BLOCK_EXPR@[9; 292) 11 BLOCK_EXPR@9..292
12 BLOCK@[9; 292) 12 BLOCK@9..292
13 L_CURLY@[9; 10) "{" 13 L_CURLY@9..10 "{"
14 WHITESPACE@[10; 15) "\n " 14 WHITESPACE@10..15 "\n "
15 EXPR_STMT@[15; 101) 15 EXPR_STMT@15..101
16 MATCH_EXPR@[15; 101) 16 MATCH_EXPR@15..101
17 MATCH_KW@[15; 20) "match" 17 MATCH_KW@15..20 "match"
18 WHITESPACE@[20; 21) " " 18 WHITESPACE@20..21 " "
19 TUPLE_EXPR@[21; 23) 19 TUPLE_EXPR@21..23
20 L_PAREN@[21; 22) "(" 20 L_PAREN@21..22 "("
21 R_PAREN@[22; 23) ")" 21 R_PAREN@22..23 ")"
22 WHITESPACE@[23; 24) " " 22 WHITESPACE@23..24 " "
23 MATCH_ARM_LIST@[24; 101) 23 MATCH_ARM_LIST@24..101
24 L_CURLY@[24; 25) "{" 24 L_CURLY@24..25 "{"
25 WHITESPACE@[25; 34) "\n " 25 WHITESPACE@25..34 "\n "
26 MATCH_ARM@[34; 41) 26 MATCH_ARM@34..41
27 PLACEHOLDER_PAT@[34; 35) 27 PLACEHOLDER_PAT@34..35
28 UNDERSCORE@[34; 35) "_" 28 UNDERSCORE@34..35 "_"
29 WHITESPACE@[35; 36) " " 29 WHITESPACE@35..36 " "
30 FAT_ARROW@[36; 38) "=>" 30 FAT_ARROW@36..38 "=>"
31 WHITESPACE@[38; 39) " " 31 WHITESPACE@38..39 " "
32 TUPLE_EXPR@[39; 41) 32 TUPLE_EXPR@39..41
33 L_PAREN@[39; 40) "(" 33 L_PAREN@39..40 "("
34 R_PAREN@[40; 41) ")" 34 R_PAREN@40..41 ")"
35 COMMA@[41; 42) "," 35 COMMA@41..42 ","
36 WHITESPACE@[42; 51) "\n " 36 WHITESPACE@42..51 "\n "
37 MATCH_ARM@[51; 78) 37 MATCH_ARM@51..78
38 ATTR@[51; 52) 38 ATTR@51..52
39 POUND@[51; 52) "#" 39 POUND@51..52 "#"
40 ERROR@[52; 53) 40 ERROR@52..53
41 BANG@[52; 53) "!" 41 BANG@52..53 "!"
42 ARRAY_EXPR@[53; 78) 42 ARRAY_EXPR@53..78
43 L_BRACK@[53; 54) "[" 43 L_BRACK@53..54 "["
44 CALL_EXPR@[54; 77) 44 CALL_EXPR@54..77
45 PATH_EXPR@[54; 57) 45 PATH_EXPR@54..57
46 PATH@[54; 57) 46 PATH@54..57
47 PATH_SEGMENT@[54; 57) 47 PATH_SEGMENT@54..57
48 NAME_REF@[54; 57) 48 NAME_REF@54..57
49 IDENT@[54; 57) "doc" 49 IDENT@54..57 "doc"
50 ARG_LIST@[57; 77) 50 ARG_LIST@57..77
51 L_PAREN@[57; 58) "(" 51 L_PAREN@57..58 "("
52 LITERAL@[58; 76) 52 LITERAL@58..76
53 STRING@[58; 76) "\"Not allowed here\"" 53 STRING@58..76 "\"Not allowed here\""
54 R_PAREN@[76; 77) ")" 54 R_PAREN@76..77 ")"
55 R_BRACK@[77; 78) "]" 55 R_BRACK@77..78 "]"
56 WHITESPACE@[78; 87) "\n " 56 WHITESPACE@78..87 "\n "
57 MATCH_ARM@[87; 94) 57 MATCH_ARM@87..94
58 PLACEHOLDER_PAT@[87; 88) 58 PLACEHOLDER_PAT@87..88
59 UNDERSCORE@[87; 88) "_" 59 UNDERSCORE@87..88 "_"
60 WHITESPACE@[88; 89) " " 60 WHITESPACE@88..89 " "
61 FAT_ARROW@[89; 91) "=>" 61 FAT_ARROW@89..91 "=>"
62 WHITESPACE@[91; 92) " " 62 WHITESPACE@91..92 " "
63 TUPLE_EXPR@[92; 94) 63 TUPLE_EXPR@92..94
64 L_PAREN@[92; 93) "(" 64 L_PAREN@92..93 "("
65 R_PAREN@[93; 94) ")" 65 R_PAREN@93..94 ")"
66 COMMA@[94; 95) "," 66 COMMA@94..95 ","
67 WHITESPACE@[95; 100) "\n " 67 WHITESPACE@95..100 "\n "
68 R_CURLY@[100; 101) "}" 68 R_CURLY@100..101 "}"
69 WHITESPACE@[101; 107) "\n\n " 69 WHITESPACE@101..107 "\n\n "
70 EXPR_STMT@[107; 185) 70 EXPR_STMT@107..185
71 MATCH_EXPR@[107; 185) 71 MATCH_EXPR@107..185
72 MATCH_KW@[107; 112) "match" 72 MATCH_KW@107..112 "match"
73 WHITESPACE@[112; 113) " " 73 WHITESPACE@112..113 " "
74 TUPLE_EXPR@[113; 115) 74 TUPLE_EXPR@113..115
75 L_PAREN@[113; 114) "(" 75 L_PAREN@113..114 "("
76 R_PAREN@[114; 115) ")" 76 R_PAREN@114..115 ")"
77 WHITESPACE@[115; 116) " " 77 WHITESPACE@115..116 " "
78 MATCH_ARM_LIST@[116; 185) 78 MATCH_ARM_LIST@116..185
79 L_CURLY@[116; 117) "{" 79 L_CURLY@116..117 "{"
80 WHITESPACE@[117; 126) "\n " 80 WHITESPACE@117..126 "\n "
81 MATCH_ARM@[126; 133) 81 MATCH_ARM@126..133
82 PLACEHOLDER_PAT@[126; 127) 82 PLACEHOLDER_PAT@126..127
83 UNDERSCORE@[126; 127) "_" 83 UNDERSCORE@126..127 "_"
84 WHITESPACE@[127; 128) " " 84 WHITESPACE@127..128 " "
85 FAT_ARROW@[128; 130) "=>" 85 FAT_ARROW@128..130 "=>"
86 WHITESPACE@[130; 131) " " 86 WHITESPACE@130..131 " "
87 TUPLE_EXPR@[131; 133) 87 TUPLE_EXPR@131..133
88 L_PAREN@[131; 132) "(" 88 L_PAREN@131..132 "("
89 R_PAREN@[132; 133) ")" 89 R_PAREN@132..133 ")"
90 COMMA@[133; 134) "," 90 COMMA@133..134 ","
91 WHITESPACE@[134; 143) "\n " 91 WHITESPACE@134..143 "\n "
92 MATCH_ARM@[143; 150) 92 MATCH_ARM@143..150
93 PLACEHOLDER_PAT@[143; 144) 93 PLACEHOLDER_PAT@143..144
94 UNDERSCORE@[143; 144) "_" 94 UNDERSCORE@143..144 "_"
95 WHITESPACE@[144; 145) " " 95 WHITESPACE@144..145 " "
96 FAT_ARROW@[145; 147) "=>" 96 FAT_ARROW@145..147 "=>"
97 WHITESPACE@[147; 148) " " 97 WHITESPACE@147..148 " "
98 TUPLE_EXPR@[148; 150) 98 TUPLE_EXPR@148..150
99 L_PAREN@[148; 149) "(" 99 L_PAREN@148..149 "("
100 R_PAREN@[149; 150) ")" 100 R_PAREN@149..150 ")"
101 COMMA@[150; 151) "," 101 COMMA@150..151 ","
102 WHITESPACE@[151; 160) "\n " 102 WHITESPACE@151..160 "\n "
103 MATCH_ARM@[160; 179) 103 MATCH_ARM@160..179
104 ATTR@[160; 161) 104 ATTR@160..161
105 POUND@[160; 161) "#" 105 POUND@160..161 "#"
106 ERROR@[161; 162) 106 ERROR@161..162
107 BANG@[161; 162) "!" 107 BANG@161..162 "!"
108 ARRAY_EXPR@[162; 179) 108 ARRAY_EXPR@162..179
109 L_BRACK@[162; 163) "[" 109 L_BRACK@162..163 "["
110 CALL_EXPR@[163; 178) 110 CALL_EXPR@163..178
111 PATH_EXPR@[163; 166) 111 PATH_EXPR@163..166
112 PATH@[163; 166) 112 PATH@163..166
113 PATH_SEGMENT@[163; 166) 113 PATH_SEGMENT@163..166
114 NAME_REF@[163; 166) 114 NAME_REF@163..166
115 IDENT@[163; 166) "doc" 115 IDENT@163..166 "doc"
116 ARG_LIST@[166; 178) 116 ARG_LIST@166..178
117 L_PAREN@[166; 167) "(" 117 L_PAREN@166..167 "("
118 LITERAL@[167; 177) 118 LITERAL@167..177
119 STRING@[167; 177) "\"Nor here\"" 119 STRING@167..177 "\"Nor here\""
120 R_PAREN@[177; 178) ")" 120 R_PAREN@177..178 ")"
121 R_BRACK@[178; 179) "]" 121 R_BRACK@178..179 "]"
122 WHITESPACE@[179; 184) "\n " 122 WHITESPACE@179..184 "\n "
123 R_CURLY@[184; 185) "}" 123 R_CURLY@184..185 "}"
124 WHITESPACE@[185; 191) "\n\n " 124 WHITESPACE@185..191 "\n\n "
125 MATCH_EXPR@[191; 290) 125 MATCH_EXPR@191..290
126 MATCH_KW@[191; 196) "match" 126 MATCH_KW@191..196 "match"
127 WHITESPACE@[196; 197) " " 127 WHITESPACE@196..197 " "
128 TUPLE_EXPR@[197; 199) 128 TUPLE_EXPR@197..199
129 L_PAREN@[197; 198) "(" 129 L_PAREN@197..198 "("
130 R_PAREN@[198; 199) ")" 130 R_PAREN@198..199 ")"
131 WHITESPACE@[199; 200) " " 131 WHITESPACE@199..200 " "
132 MATCH_ARM_LIST@[200; 290) 132 MATCH_ARM_LIST@200..290
133 L_CURLY@[200; 201) "{" 133 L_CURLY@200..201 "{"
134 WHITESPACE@[201; 210) "\n " 134 WHITESPACE@201..210 "\n "
135 MATCH_ARM@[210; 250) 135 MATCH_ARM@210..250
136 ATTR@[210; 222) 136 ATTR@210..222
137 POUND@[210; 211) "#" 137 POUND@210..211 "#"
138 L_BRACK@[211; 212) "[" 138 L_BRACK@211..212 "["
139 PATH@[212; 215) 139 PATH@212..215
140 PATH_SEGMENT@[212; 215) 140 PATH_SEGMENT@212..215
141 NAME_REF@[212; 215) 141 NAME_REF@212..215
142 IDENT@[212; 215) "cfg" 142 IDENT@212..215 "cfg"
143 TOKEN_TREE@[215; 221) 143 TOKEN_TREE@215..221
144 L_PAREN@[215; 216) "(" 144 L_PAREN@215..216 "("
145 IDENT@[216; 220) "test" 145 IDENT@216..220 "test"
146 R_PAREN@[220; 221) ")" 146 R_PAREN@220..221 ")"
147 R_BRACK@[221; 222) "]" 147 R_BRACK@221..222 "]"
148 WHITESPACE@[222; 231) "\n " 148 WHITESPACE@222..231 "\n "
149 ATTR@[231; 232) 149 ATTR@231..232
150 POUND@[231; 232) "#" 150 POUND@231..232 "#"
151 ERROR@[232; 233) 151 ERROR@232..233
152 BANG@[232; 233) "!" 152 BANG@232..233 "!"
153 ARRAY_EXPR@[233; 250) 153 ARRAY_EXPR@233..250
154 L_BRACK@[233; 234) "[" 154 L_BRACK@233..234 "["
155 CALL_EXPR@[234; 249) 155 CALL_EXPR@234..249
156 PATH_EXPR@[234; 237) 156 PATH_EXPR@234..237
157 PATH@[234; 237) 157 PATH@234..237
158 PATH_SEGMENT@[234; 237) 158 PATH_SEGMENT@234..237
159 NAME_REF@[234; 237) 159 NAME_REF@234..237
160 IDENT@[234; 237) "doc" 160 IDENT@234..237 "doc"
161 ARG_LIST@[237; 249) 161 ARG_LIST@237..249
162 L_PAREN@[237; 238) "(" 162 L_PAREN@237..238 "("
163 LITERAL@[238; 248) 163 LITERAL@238..248
164 STRING@[238; 248) "\"Nor here\"" 164 STRING@238..248 "\"Nor here\""
165 R_PAREN@[248; 249) ")" 165 R_PAREN@248..249 ")"
166 R_BRACK@[249; 250) "]" 166 R_BRACK@249..250 "]"
167 WHITESPACE@[250; 259) "\n " 167 WHITESPACE@250..259 "\n "
168 MATCH_ARM@[259; 266) 168 MATCH_ARM@259..266
169 PLACEHOLDER_PAT@[259; 260) 169 PLACEHOLDER_PAT@259..260
170 UNDERSCORE@[259; 260) "_" 170 UNDERSCORE@259..260 "_"
171 WHITESPACE@[260; 261) " " 171 WHITESPACE@260..261 " "
172 FAT_ARROW@[261; 263) "=>" 172 FAT_ARROW@261..263 "=>"
173 WHITESPACE@[263; 264) " " 173 WHITESPACE@263..264 " "
174 TUPLE_EXPR@[264; 266) 174 TUPLE_EXPR@264..266
175 L_PAREN@[264; 265) "(" 175 L_PAREN@264..265 "("
176 R_PAREN@[265; 266) ")" 176 R_PAREN@265..266 ")"
177 COMMA@[266; 267) "," 177 COMMA@266..267 ","
178 WHITESPACE@[267; 276) "\n " 178 WHITESPACE@267..276 "\n "
179 MATCH_ARM@[276; 283) 179 MATCH_ARM@276..283
180 PLACEHOLDER_PAT@[276; 277) 180 PLACEHOLDER_PAT@276..277
181 UNDERSCORE@[276; 277) "_" 181 UNDERSCORE@276..277 "_"
182 WHITESPACE@[277; 278) " " 182 WHITESPACE@277..278 " "
183 FAT_ARROW@[278; 280) "=>" 183 FAT_ARROW@278..280 "=>"
184 WHITESPACE@[280; 281) " " 184 WHITESPACE@280..281 " "
185 TUPLE_EXPR@[281; 283) 185 TUPLE_EXPR@281..283
186 L_PAREN@[281; 282) "(" 186 L_PAREN@281..282 "("
187 R_PAREN@[282; 283) ")" 187 R_PAREN@282..283 ")"
188 COMMA@[283; 284) "," 188 COMMA@283..284 ","
189 WHITESPACE@[284; 289) "\n " 189 WHITESPACE@284..289 "\n "
190 R_CURLY@[289; 290) "}" 190 R_CURLY@289..290 "}"
191 WHITESPACE@[290; 291) "\n" 191 WHITESPACE@290..291 "\n"
192 R_CURLY@[291; 292) "}" 192 R_CURLY@291..292 "}"
193 WHITESPACE@[292; 293) "\n" 193 WHITESPACE@292..293 "\n"
194error [52; 52): expected `[` 194error 52..52: expected `[`
195error [52; 52): expected pattern 195error 52..52: expected pattern
196error [53; 53): expected FAT_ARROW 196error 53..53: expected FAT_ARROW
197error [78; 78): expected COMMA 197error 78..78: expected COMMA
198error [161; 161): expected `[` 198error 161..161: expected `[`
199error [161; 161): expected pattern 199error 161..161: expected pattern
200error [162; 162): expected FAT_ARROW 200error 162..162: expected FAT_ARROW
201error [232; 232): expected `[` 201error 232..232: expected `[`
202error [232; 232): expected pattern 202error 232..232: expected pattern
203error [233; 233): expected FAT_ARROW 203error 233..233: expected FAT_ARROW
204error [250; 250): expected COMMA 204error 250..250: expected COMMA
diff --git a/crates/ra_syntax/test_data/parser/err/0033_match_arms_outer_attrs.rast b/crates/ra_syntax/test_data/parser/err/0033_match_arms_outer_attrs.rast
index e914e688b..d0017c883 100644
--- a/crates/ra_syntax/test_data/parser/err/0033_match_arms_outer_attrs.rast
+++ b/crates/ra_syntax/test_data/parser/err/0033_match_arms_outer_attrs.rast
@@ -1,67 +1,67 @@
1SOURCE_FILE@[0; 89) 1SOURCE_FILE@0..89
2 FN_DEF@[0; 88) 2 FN_DEF@0..88
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 BLOCK_EXPR@[9; 88) 11 BLOCK_EXPR@9..88
12 BLOCK@[9; 88) 12 BLOCK@9..88
13 L_CURLY@[9; 10) "{" 13 L_CURLY@9..10 "{"
14 WHITESPACE@[10; 15) "\n " 14 WHITESPACE@10..15 "\n "
15 MATCH_EXPR@[15; 86) 15 MATCH_EXPR@15..86
16 MATCH_KW@[15; 20) "match" 16 MATCH_KW@15..20 "match"
17 WHITESPACE@[20; 21) " " 17 WHITESPACE@20..21 " "
18 TUPLE_EXPR@[21; 23) 18 TUPLE_EXPR@21..23
19 L_PAREN@[21; 22) "(" 19 L_PAREN@21..22 "("
20 R_PAREN@[22; 23) ")" 20 R_PAREN@22..23 ")"
21 WHITESPACE@[23; 24) " " 21 WHITESPACE@23..24 " "
22 MATCH_ARM_LIST@[24; 86) 22 MATCH_ARM_LIST@24..86
23 L_CURLY@[24; 25) "{" 23 L_CURLY@24..25 "{"
24 WHITESPACE@[25; 34) "\n " 24 WHITESPACE@25..34 "\n "
25 MATCH_ARM@[34; 41) 25 MATCH_ARM@34..41
26 PLACEHOLDER_PAT@[34; 35) 26 PLACEHOLDER_PAT@34..35
27 UNDERSCORE@[34; 35) "_" 27 UNDERSCORE@34..35 "_"
28 WHITESPACE@[35; 36) " " 28 WHITESPACE@35..36 " "
29 FAT_ARROW@[36; 38) "=>" 29 FAT_ARROW@36..38 "=>"
30 WHITESPACE@[38; 39) " " 30 WHITESPACE@38..39 " "
31 TUPLE_EXPR@[39; 41) 31 TUPLE_EXPR@39..41
32 L_PAREN@[39; 40) "(" 32 L_PAREN@39..40 "("
33 R_PAREN@[40; 41) ")" 33 R_PAREN@40..41 ")"
34 COMMA@[41; 42) "," 34 COMMA@41..42 ","
35 WHITESPACE@[42; 51) "\n " 35 WHITESPACE@42..51 "\n "
36 MATCH_ARM@[51; 58) 36 MATCH_ARM@51..58
37 PLACEHOLDER_PAT@[51; 52) 37 PLACEHOLDER_PAT@51..52
38 UNDERSCORE@[51; 52) "_" 38 UNDERSCORE@51..52 "_"
39 WHITESPACE@[52; 53) " " 39 WHITESPACE@52..53 " "
40 FAT_ARROW@[53; 55) "=>" 40 FAT_ARROW@53..55 "=>"
41 WHITESPACE@[55; 56) " " 41 WHITESPACE@55..56 " "
42 TUPLE_EXPR@[56; 58) 42 TUPLE_EXPR@56..58
43 L_PAREN@[56; 57) "(" 43 L_PAREN@56..57 "("
44 R_PAREN@[57; 58) ")" 44 R_PAREN@57..58 ")"
45 COMMA@[58; 59) "," 45 COMMA@58..59 ","
46 WHITESPACE@[59; 68) "\n " 46 WHITESPACE@59..68 "\n "
47 MATCH_ARM@[68; 80) 47 MATCH_ARM@68..80
48 ATTR@[68; 80) 48 ATTR@68..80
49 POUND@[68; 69) "#" 49 POUND@68..69 "#"
50 L_BRACK@[69; 70) "[" 50 L_BRACK@69..70 "["
51 PATH@[70; 73) 51 PATH@70..73
52 PATH_SEGMENT@[70; 73) 52 PATH_SEGMENT@70..73
53 NAME_REF@[70; 73) 53 NAME_REF@70..73
54 IDENT@[70; 73) "cfg" 54 IDENT@70..73 "cfg"
55 TOKEN_TREE@[73; 79) 55 TOKEN_TREE@73..79
56 L_PAREN@[73; 74) "(" 56 L_PAREN@73..74 "("
57 IDENT@[74; 78) "test" 57 IDENT@74..78 "test"
58 R_PAREN@[78; 79) ")" 58 R_PAREN@78..79 ")"
59 R_BRACK@[79; 80) "]" 59 R_BRACK@79..80 "]"
60 WHITESPACE@[80; 85) "\n " 60 WHITESPACE@80..85 "\n "
61 R_CURLY@[85; 86) "}" 61 R_CURLY@85..86 "}"
62 WHITESPACE@[86; 87) "\n" 62 WHITESPACE@86..87 "\n"
63 R_CURLY@[87; 88) "}" 63 R_CURLY@87..88 "}"
64 WHITESPACE@[88; 89) "\n" 64 WHITESPACE@88..89 "\n"
65error [80; 80): expected pattern 65error 80..80: expected pattern
66error [80; 80): expected FAT_ARROW 66error 80..80: expected FAT_ARROW
67error [80; 80): expected expression 67error 80..80: expected expression
diff --git a/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rast b/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rast
index 2ab9ee56f..2c0bddec8 100644
--- a/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rast
+++ b/crates/ra_syntax/test_data/parser/err/0034_bad_box_pattern.rast
@@ -1,96 +1,96 @@
1SOURCE_FILE@[0; 91) 1SOURCE_FILE@0..91
2 FN_DEF@[0; 89) 2 FN_DEF@0..89
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 7) 5 NAME@3..7
6 IDENT@[3; 7) "main" 6 IDENT@3..7 "main"
7 PARAM_LIST@[7; 9) 7 PARAM_LIST@7..9
8 L_PAREN@[7; 8) "(" 8 L_PAREN@7..8 "("
9 R_PAREN@[8; 9) ")" 9 R_PAREN@8..9 ")"
10 WHITESPACE@[9; 10) " " 10 WHITESPACE@9..10 " "
11 BLOCK_EXPR@[10; 89) 11 BLOCK_EXPR@10..89
12 BLOCK@[10; 89) 12 BLOCK@10..89
13 L_CURLY@[10; 11) "{" 13 L_CURLY@10..11 "{"
14 WHITESPACE@[11; 16) "\n " 14 WHITESPACE@11..16 "\n "
15 LET_STMT@[16; 27) 15 LET_STMT@16..27
16 LET_KW@[16; 19) "let" 16 LET_KW@16..19 "let"
17 WHITESPACE@[19; 20) " " 17 WHITESPACE@19..20 " "
18 BIND_PAT@[20; 27) 18 BIND_PAT@20..27
19 REF_KW@[20; 23) "ref" 19 REF_KW@20..23 "ref"
20 WHITESPACE@[23; 24) " " 20 WHITESPACE@23..24 " "
21 ERROR@[24; 27) 21 ERROR@24..27
22 BOX_KW@[24; 27) "box" 22 BOX_KW@24..27 "box"
23 WHITESPACE@[27; 28) " " 23 WHITESPACE@27..28 " "
24 EXPR_STMT@[28; 35) 24 EXPR_STMT@28..35
25 BIN_EXPR@[28; 34) 25 BIN_EXPR@28..34
26 PATH_EXPR@[28; 29) 26 PATH_EXPR@28..29
27 PATH@[28; 29) 27 PATH@28..29
28 PATH_SEGMENT@[28; 29) 28 PATH_SEGMENT@28..29
29 NAME_REF@[28; 29) 29 NAME_REF@28..29
30 IDENT@[28; 29) "i" 30 IDENT@28..29 "i"
31 WHITESPACE@[29; 30) " " 31 WHITESPACE@29..30 " "
32 EQ@[30; 31) "=" 32 EQ@30..31 "="
33 WHITESPACE@[31; 32) " " 33 WHITESPACE@31..32 " "
34 TUPLE_EXPR@[32; 34) 34 TUPLE_EXPR@32..34
35 L_PAREN@[32; 33) "(" 35 L_PAREN@32..33 "("
36 R_PAREN@[33; 34) ")" 36 R_PAREN@33..34 ")"
37 SEMICOLON@[34; 35) ";" 37 SEMICOLON@34..35 ";"
38 WHITESPACE@[35; 40) "\n " 38 WHITESPACE@35..40 "\n "
39 LET_STMT@[40; 51) 39 LET_STMT@40..51
40 LET_KW@[40; 43) "let" 40 LET_KW@40..43 "let"
41 WHITESPACE@[43; 44) " " 41 WHITESPACE@43..44 " "
42 BIND_PAT@[44; 51) 42 BIND_PAT@44..51
43 MUT_KW@[44; 47) "mut" 43 MUT_KW@44..47 "mut"
44 WHITESPACE@[47; 48) " " 44 WHITESPACE@47..48 " "
45 ERROR@[48; 51) 45 ERROR@48..51
46 BOX_KW@[48; 51) "box" 46 BOX_KW@48..51 "box"
47 WHITESPACE@[51; 52) " " 47 WHITESPACE@51..52 " "
48 EXPR_STMT@[52; 59) 48 EXPR_STMT@52..59
49 BIN_EXPR@[52; 58) 49 BIN_EXPR@52..58
50 PATH_EXPR@[52; 53) 50 PATH_EXPR@52..53
51 PATH@[52; 53) 51 PATH@52..53
52 PATH_SEGMENT@[52; 53) 52 PATH_SEGMENT@52..53
53 NAME_REF@[52; 53) 53 NAME_REF@52..53
54 IDENT@[52; 53) "i" 54 IDENT@52..53 "i"
55 WHITESPACE@[53; 54) " " 55 WHITESPACE@53..54 " "
56 EQ@[54; 55) "=" 56 EQ@54..55 "="
57 WHITESPACE@[55; 56) " " 57 WHITESPACE@55..56 " "
58 TUPLE_EXPR@[56; 58) 58 TUPLE_EXPR@56..58
59 L_PAREN@[56; 57) "(" 59 L_PAREN@56..57 "("
60 R_PAREN@[57; 58) ")" 60 R_PAREN@57..58 ")"
61 SEMICOLON@[58; 59) ";" 61 SEMICOLON@58..59 ";"
62 WHITESPACE@[59; 64) "\n " 62 WHITESPACE@59..64 "\n "
63 LET_STMT@[64; 79) 63 LET_STMT@64..79
64 LET_KW@[64; 67) "let" 64 LET_KW@64..67 "let"
65 WHITESPACE@[67; 68) " " 65 WHITESPACE@67..68 " "
66 BIND_PAT@[68; 79) 66 BIND_PAT@68..79
67 REF_KW@[68; 71) "ref" 67 REF_KW@68..71 "ref"
68 WHITESPACE@[71; 72) " " 68 WHITESPACE@71..72 " "
69 MUT_KW@[72; 75) "mut" 69 MUT_KW@72..75 "mut"
70 WHITESPACE@[75; 76) " " 70 WHITESPACE@75..76 " "
71 ERROR@[76; 79) 71 ERROR@76..79
72 BOX_KW@[76; 79) "box" 72 BOX_KW@76..79 "box"
73 WHITESPACE@[79; 80) " " 73 WHITESPACE@79..80 " "
74 EXPR_STMT@[80; 87) 74 EXPR_STMT@80..87
75 BIN_EXPR@[80; 86) 75 BIN_EXPR@80..86
76 PATH_EXPR@[80; 81) 76 PATH_EXPR@80..81
77 PATH@[80; 81) 77 PATH@80..81
78 PATH_SEGMENT@[80; 81) 78 PATH_SEGMENT@80..81
79 NAME_REF@[80; 81) 79 NAME_REF@80..81
80 IDENT@[80; 81) "i" 80 IDENT@80..81 "i"
81 WHITESPACE@[81; 82) " " 81 WHITESPACE@81..82 " "
82 EQ@[82; 83) "=" 82 EQ@82..83 "="
83 WHITESPACE@[83; 84) " " 83 WHITESPACE@83..84 " "
84 TUPLE_EXPR@[84; 86) 84 TUPLE_EXPR@84..86
85 L_PAREN@[84; 85) "(" 85 L_PAREN@84..85 "("
86 R_PAREN@[85; 86) ")" 86 R_PAREN@85..86 ")"
87 SEMICOLON@[86; 87) ";" 87 SEMICOLON@86..87 ";"
88 WHITESPACE@[87; 88) "\n" 88 WHITESPACE@87..88 "\n"
89 R_CURLY@[88; 89) "}" 89 R_CURLY@88..89 "}"
90 WHITESPACE@[89; 91) "\n\n" 90 WHITESPACE@89..91 "\n\n"
91error [24; 24): expected a name 91error 24..24: expected a name
92error [27; 27): expected SEMICOLON 92error 27..27: expected SEMICOLON
93error [48; 48): expected a name 93error 48..48: expected a name
94error [51; 51): expected SEMICOLON 94error 51..51: expected SEMICOLON
95error [76; 76): expected a name 95error 76..76: expected a name
96error [79; 79): expected SEMICOLON 96error 79..79: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0035_use_recover.rast b/crates/ra_syntax/test_data/parser/err/0035_use_recover.rast
index f255b0a6b..83851f5d2 100644
--- a/crates/ra_syntax/test_data/parser/err/0035_use_recover.rast
+++ b/crates/ra_syntax/test_data/parser/err/0035_use_recover.rast
@@ -1,54 +1,54 @@
1SOURCE_FILE@[0; 48) 1SOURCE_FILE@0..48
2 USE_ITEM@[0; 13) 2 USE_ITEM@0..13
3 USE_KW@[0; 3) "use" 3 USE_KW@0..3 "use"
4 WHITESPACE@[3; 4) " " 4 WHITESPACE@3..4 " "
5 USE_TREE@[4; 12) 5 USE_TREE@4..12
6 PATH@[4; 12) 6 PATH@4..12
7 PATH@[4; 7) 7 PATH@4..7
8 PATH_SEGMENT@[4; 7) 8 PATH_SEGMENT@4..7
9 NAME_REF@[4; 7) 9 NAME_REF@4..7
10 IDENT@[4; 7) "foo" 10 IDENT@4..7 "foo"
11 COLON2@[7; 9) "::" 11 COLON2@7..9 "::"
12 PATH_SEGMENT@[9; 12) 12 PATH_SEGMENT@9..12
13 NAME_REF@[9; 12) 13 NAME_REF@9..12
14 IDENT@[9; 12) "bar" 14 IDENT@9..12 "bar"
15 SEMICOLON@[12; 13) ";" 15 SEMICOLON@12..13 ";"
16 WHITESPACE@[13; 14) "\n" 16 WHITESPACE@13..14 "\n"
17 USE_ITEM@[14; 17) 17 USE_ITEM@14..17
18 USE_KW@[14; 17) "use" 18 USE_KW@14..17 "use"
19 WHITESPACE@[17; 18) "\n" 19 WHITESPACE@17..18 "\n"
20 USE_ITEM@[18; 33) 20 USE_ITEM@18..33
21 USE_KW@[18; 21) "use" 21 USE_KW@18..21 "use"
22 WHITESPACE@[21; 22) " " 22 WHITESPACE@21..22 " "
23 USE_TREE@[22; 32) 23 USE_TREE@22..32
24 PATH@[22; 32) 24 PATH@22..32
25 PATH@[22; 27) 25 PATH@22..27
26 PATH_SEGMENT@[22; 27) 26 PATH_SEGMENT@22..27
27 CRATE_KW@[22; 27) "crate" 27 CRATE_KW@22..27 "crate"
28 COLON2@[27; 29) "::" 28 COLON2@27..29 "::"
29 PATH_SEGMENT@[29; 32) 29 PATH_SEGMENT@29..32
30 NAME_REF@[29; 32) 30 NAME_REF@29..32
31 IDENT@[29; 32) "baz" 31 IDENT@29..32 "baz"
32 SEMICOLON@[32; 33) ";" 32 SEMICOLON@32..33 ";"
33 WHITESPACE@[33; 34) "\n" 33 WHITESPACE@33..34 "\n"
34 USE_ITEM@[34; 37) 34 USE_ITEM@34..37
35 USE_KW@[34; 37) "use" 35 USE_KW@34..37 "use"
36 WHITESPACE@[37; 38) "\n" 36 WHITESPACE@37..38 "\n"
37 FN_DEF@[38; 47) 37 FN_DEF@38..47
38 FN_KW@[38; 40) "fn" 38 FN_KW@38..40 "fn"
39 WHITESPACE@[40; 41) " " 39 WHITESPACE@40..41 " "
40 NAME@[41; 42) 40 NAME@41..42
41 IDENT@[41; 42) "f" 41 IDENT@41..42 "f"
42 PARAM_LIST@[42; 44) 42 PARAM_LIST@42..44
43 L_PAREN@[42; 43) "(" 43 L_PAREN@42..43 "("
44 R_PAREN@[43; 44) ")" 44 R_PAREN@43..44 ")"
45 WHITESPACE@[44; 45) " " 45 WHITESPACE@44..45 " "
46 BLOCK_EXPR@[45; 47) 46 BLOCK_EXPR@45..47
47 BLOCK@[45; 47) 47 BLOCK@45..47
48 L_CURLY@[45; 46) "{" 48 L_CURLY@45..46 "{"
49 R_CURLY@[46; 47) "}" 49 R_CURLY@46..47 "}"
50 WHITESPACE@[47; 48) "\n" 50 WHITESPACE@47..48 "\n"
51error [17; 17): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 51error 17..17: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
52error [17; 17): expected SEMICOLON 52error 17..17: expected SEMICOLON
53error [37; 37): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 53error 37..37: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
54error [37; 37): expected SEMICOLON 54error 37..37: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0036_partial_use.rast b/crates/ra_syntax/test_data/parser/err/0036_partial_use.rast
index 1f2b4f6d9..f926b67d2 100644
--- a/crates/ra_syntax/test_data/parser/err/0036_partial_use.rast
+++ b/crates/ra_syntax/test_data/parser/err/0036_partial_use.rast
@@ -1,51 +1,51 @@
1SOURCE_FILE@[0; 37) 1SOURCE_FILE@0..37
2 USE_ITEM@[0; 36) 2 USE_ITEM@0..36
3 USE_KW@[0; 3) "use" 3 USE_KW@0..3 "use"
4 WHITESPACE@[3; 4) " " 4 WHITESPACE@3..4 " "
5 USE_TREE@[4; 36) 5 USE_TREE@4..36
6 PATH@[4; 7) 6 PATH@4..7
7 PATH_SEGMENT@[4; 7) 7 PATH_SEGMENT@4..7
8 NAME_REF@[4; 7) 8 NAME_REF@4..7
9 IDENT@[4; 7) "std" 9 IDENT@4..7 "std"
10 COLON2@[7; 9) "::" 10 COLON2@7..9 "::"
11 USE_TREE_LIST@[9; 36) 11 USE_TREE_LIST@9..36
12 L_CURLY@[9; 10) "{" 12 L_CURLY@9..10 "{"
13 USE_TREE@[10; 22) 13 USE_TREE@10..22
14 PATH@[10; 22) 14 PATH@10..22
15 PATH@[10; 15) 15 PATH@10..15
16 PATH_SEGMENT@[10; 15) 16 PATH_SEGMENT@10..15
17 NAME_REF@[10; 15) 17 NAME_REF@10..15
18 IDENT@[10; 15) "error" 18 IDENT@10..15 "error"
19 COLON2@[15; 17) "::" 19 COLON2@15..17 "::"
20 PATH_SEGMENT@[17; 22) 20 PATH_SEGMENT@17..22
21 NAME_REF@[17; 22) 21 NAME_REF@17..22
22 IDENT@[17; 22) "Error" 22 IDENT@17..22 "Error"
23 ERROR@[22; 23) 23 ERROR@22..23
24 SEMICOLON@[22; 23) ";" 24 SEMICOLON@22..23 ";"
25 WHITESPACE@[23; 24) "\n" 25 WHITESPACE@23..24 "\n"
26 ERROR@[24; 27) 26 ERROR@24..27
27 USE_KW@[24; 27) "use" 27 USE_KW@24..27 "use"
28 WHITESPACE@[27; 28) " " 28 WHITESPACE@27..28 " "
29 USE_TREE@[28; 35) 29 USE_TREE@28..35
30 PATH@[28; 35) 30 PATH@28..35
31 PATH@[28; 31) 31 PATH@28..31
32 PATH_SEGMENT@[28; 31) 32 PATH_SEGMENT@28..31
33 NAME_REF@[28; 31) 33 NAME_REF@28..31
34 IDENT@[28; 31) "std" 34 IDENT@28..31 "std"
35 COLON2@[31; 33) "::" 35 COLON2@31..33 "::"
36 PATH_SEGMENT@[33; 35) 36 PATH_SEGMENT@33..35
37 NAME_REF@[33; 35) 37 NAME_REF@33..35
38 IDENT@[33; 35) "io" 38 IDENT@33..35 "io"
39 ERROR@[35; 36) 39 ERROR@35..36
40 SEMICOLON@[35; 36) ";" 40 SEMICOLON@35..36 ";"
41 WHITESPACE@[36; 37) "\n" 41 WHITESPACE@36..37 "\n"
42error [22; 22): expected COMMA 42error 22..22: expected COMMA
43error [22; 22): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 43error 22..22: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
44error [23; 23): expected COMMA 44error 23..23: expected COMMA
45error [24; 24): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 45error 24..24: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
46error [27; 27): expected COMMA 46error 27..27: expected COMMA
47error [35; 35): expected COMMA 47error 35..35: expected COMMA
48error [35; 35): expected one of `*`, `::`, `{`, `self`, `super` or an identifier 48error 35..35: expected one of `*`, `::`, `{`, `self`, `super` or an identifier
49error [36; 36): expected COMMA 49error 36..36: expected COMMA
50error [36; 36): expected R_CURLY 50error 36..36: expected R_CURLY
51error [36; 36): expected SEMICOLON 51error 36..36: expected SEMICOLON
diff --git a/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast b/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
index 5319bf936..a328222aa 100644
--- a/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
+++ b/crates/ra_syntax/test_data/parser/err/0037_visibility_in_traits.rast
@@ -1,99 +1,99 @@
1SOURCE_FILE@[0; 118) 1SOURCE_FILE@0..118
2 IMPL_DEF@[0; 117) 2 IMPL_DEF@0..117
3 IMPL_KW@[0; 4) "impl" 3 IMPL_KW@0..4 "impl"
4 WHITESPACE@[4; 5) " " 4 WHITESPACE@4..5 " "
5 PATH_TYPE@[5; 6) 5 PATH_TYPE@5..6
6 PATH@[5; 6) 6 PATH@5..6
7 PATH_SEGMENT@[5; 6) 7 PATH_SEGMENT@5..6
8 NAME_REF@[5; 6) 8 NAME_REF@5..6
9 IDENT@[5; 6) "T" 9 IDENT@5..6 "T"
10 WHITESPACE@[6; 7) " " 10 WHITESPACE@6..7 " "
11 FOR_KW@[7; 10) "for" 11 FOR_KW@7..10 "for"
12 WHITESPACE@[10; 11) " " 12 WHITESPACE@10..11 " "
13 TUPLE_TYPE@[11; 13) 13 TUPLE_TYPE@11..13
14 L_PAREN@[11; 12) "(" 14 L_PAREN@11..12 "("
15 R_PAREN@[12; 13) ")" 15 R_PAREN@12..13 ")"
16 WHITESPACE@[13; 14) " " 16 WHITESPACE@13..14 " "
17 ITEM_LIST@[14; 117) 17 ITEM_LIST@14..117
18 L_CURLY@[14; 15) "{" 18 L_CURLY@14..15 "{"
19 WHITESPACE@[15; 20) "\n " 19 WHITESPACE@15..20 "\n "
20 FN_DEF@[20; 31) 20 FN_DEF@20..31
21 FN_KW@[20; 22) "fn" 21 FN_KW@20..22 "fn"
22 WHITESPACE@[22; 23) " " 22 WHITESPACE@22..23 " "
23 NAME@[23; 26) 23 NAME@23..26
24 IDENT@[23; 26) "foo" 24 IDENT@23..26 "foo"
25 PARAM_LIST@[26; 28) 25 PARAM_LIST@26..28
26 L_PAREN@[26; 27) "(" 26 L_PAREN@26..27 "("
27 R_PAREN@[27; 28) ")" 27 R_PAREN@27..28 ")"
28 WHITESPACE@[28; 29) " " 28 WHITESPACE@28..29 " "
29 BLOCK_EXPR@[29; 31) 29 BLOCK_EXPR@29..31
30 BLOCK@[29; 31) 30 BLOCK@29..31
31 L_CURLY@[29; 30) "{" 31 L_CURLY@29..30 "{"
32 R_CURLY@[30; 31) "}" 32 R_CURLY@30..31 "}"
33 WHITESPACE@[31; 36) "\n " 33 WHITESPACE@31..36 "\n "
34 FN_DEF@[36; 51) 34 FN_DEF@36..51
35 VISIBILITY@[36; 39) 35 VISIBILITY@36..39
36 PUB_KW@[36; 39) "pub" 36 PUB_KW@36..39 "pub"
37 WHITESPACE@[39; 40) " " 37 WHITESPACE@39..40 " "
38 FN_KW@[40; 42) "fn" 38 FN_KW@40..42 "fn"
39 WHITESPACE@[42; 43) " " 39 WHITESPACE@42..43 " "
40 NAME@[43; 46) 40 NAME@43..46
41 IDENT@[43; 46) "bar" 41 IDENT@43..46 "bar"
42 PARAM_LIST@[46; 48) 42 PARAM_LIST@46..48
43 L_PAREN@[46; 47) "(" 43 L_PAREN@46..47 "("
44 R_PAREN@[47; 48) ")" 44 R_PAREN@47..48 ")"
45 WHITESPACE@[48; 49) " " 45 WHITESPACE@48..49 " "
46 BLOCK_EXPR@[49; 51) 46 BLOCK_EXPR@49..51
47 BLOCK@[49; 51) 47 BLOCK@49..51
48 L_CURLY@[49; 50) "{" 48 L_CURLY@49..50 "{"
49 R_CURLY@[50; 51) "}" 49 R_CURLY@50..51 "}"
50 WHITESPACE@[51; 56) "\n " 50 WHITESPACE@51..56 "\n "
51 TYPE_ALIAS_DEF@[56; 81) 51 TYPE_ALIAS_DEF@56..81
52 VISIBILITY@[56; 66) 52 VISIBILITY@56..66
53 PUB_KW@[56; 59) "pub" 53 PUB_KW@56..59 "pub"
54 L_PAREN@[59; 60) "(" 54 L_PAREN@59..60 "("
55 CRATE_KW@[60; 65) "crate" 55 CRATE_KW@60..65 "crate"
56 R_PAREN@[65; 66) ")" 56 R_PAREN@65..66 ")"
57 WHITESPACE@[66; 67) " " 57 WHITESPACE@66..67 " "
58 TYPE_KW@[67; 71) "type" 58 TYPE_KW@67..71 "type"
59 WHITESPACE@[71; 72) " " 59 WHITESPACE@71..72 " "
60 NAME@[72; 75) 60 NAME@72..75
61 IDENT@[72; 75) "Baz" 61 IDENT@72..75 "Baz"
62 WHITESPACE@[75; 76) " " 62 WHITESPACE@75..76 " "
63 EQ@[76; 77) "=" 63 EQ@76..77 "="
64 WHITESPACE@[77; 78) " " 64 WHITESPACE@77..78 " "
65 TUPLE_TYPE@[78; 80) 65 TUPLE_TYPE@78..80
66 L_PAREN@[78; 79) "(" 66 L_PAREN@78..79 "("
67 R_PAREN@[79; 80) ")" 67 R_PAREN@79..80 ")"
68 SEMICOLON@[80; 81) ";" 68 SEMICOLON@80..81 ";"
69 WHITESPACE@[81; 86) "\n " 69 WHITESPACE@81..86 "\n "
70 CONST_DEF@[86; 115) 70 CONST_DEF@86..115
71 VISIBILITY@[86; 96) 71 VISIBILITY@86..96
72 PUB_KW@[86; 89) "pub" 72 PUB_KW@86..89 "pub"
73 L_PAREN@[89; 90) "(" 73 L_PAREN@89..90 "("
74 CRATE_KW@[90; 95) "crate" 74 CRATE_KW@90..95 "crate"
75 R_PAREN@[95; 96) ")" 75 R_PAREN@95..96 ")"
76 WHITESPACE@[96; 97) " " 76 WHITESPACE@96..97 " "
77 CONST_KW@[97; 102) "const" 77 CONST_KW@97..102 "const"
78 WHITESPACE@[102; 103) " " 78 WHITESPACE@102..103 " "
79 NAME@[103; 104) 79 NAME@103..104
80 IDENT@[103; 104) "C" 80 IDENT@103..104 "C"
81 COLON@[104; 105) ":" 81 COLON@104..105 ":"
82 WHITESPACE@[105; 106) " " 82 WHITESPACE@105..106 " "
83 PATH_TYPE@[106; 109) 83 PATH_TYPE@106..109
84 PATH@[106; 109) 84 PATH@106..109
85 PATH_SEGMENT@[106; 109) 85 PATH_SEGMENT@106..109
86 NAME_REF@[106; 109) 86 NAME_REF@106..109
87 IDENT@[106; 109) "i32" 87 IDENT@106..109 "i32"
88 WHITESPACE@[109; 110) " " 88 WHITESPACE@109..110 " "
89 EQ@[110; 111) "=" 89 EQ@110..111 "="
90 WHITESPACE@[111; 112) " " 90 WHITESPACE@111..112 " "
91 LITERAL@[112; 114) 91 LITERAL@112..114
92 INT_NUMBER@[112; 114) "92" 92 INT_NUMBER@112..114 "92"
93 SEMICOLON@[114; 115) ";" 93 SEMICOLON@114..115 ";"
94 WHITESPACE@[115; 116) "\n" 94 WHITESPACE@115..116 "\n"
95 R_CURLY@[116; 117) "}" 95 R_CURLY@116..117 "}"
96 WHITESPACE@[117; 118) "\n" 96 WHITESPACE@117..118 "\n"
97error [36; 39): Unnecessary visibility qualifier 97error 36..39: Unnecessary visibility qualifier
98error [56; 66): Unnecessary visibility qualifier 98error 56..66: Unnecessary visibility qualifier
99error [86; 96): Unnecessary visibility qualifier 99error 86..96: Unnecessary visibility qualifier
diff --git a/crates/ra_syntax/test_data/parser/err/0038_endless_inclusive_range.rast b/crates/ra_syntax/test_data/parser/err/0038_endless_inclusive_range.rast
index 9efdf7ef4..bcd1fad69 100644
--- a/crates/ra_syntax/test_data/parser/err/0038_endless_inclusive_range.rast
+++ b/crates/ra_syntax/test_data/parser/err/0038_endless_inclusive_range.rast
@@ -1,30 +1,30 @@
1SOURCE_FILE@[0; 33) 1SOURCE_FILE@0..33
2 FN_DEF@[0; 32) 2 FN_DEF@0..32
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 7) 5 NAME@3..7
6 IDENT@[3; 7) "main" 6 IDENT@3..7 "main"
7 PARAM_LIST@[7; 9) 7 PARAM_LIST@7..9
8 L_PAREN@[7; 8) "(" 8 L_PAREN@7..8 "("
9 R_PAREN@[8; 9) ")" 9 R_PAREN@8..9 ")"
10 WHITESPACE@[9; 10) " " 10 WHITESPACE@9..10 " "
11 BLOCK_EXPR@[10; 32) 11 BLOCK_EXPR@10..32
12 BLOCK@[10; 32) 12 BLOCK@10..32
13 L_CURLY@[10; 11) "{" 13 L_CURLY@10..11 "{"
14 WHITESPACE@[11; 16) "\n " 14 WHITESPACE@11..16 "\n "
15 EXPR_STMT@[16; 21) 15 EXPR_STMT@16..21
16 RANGE_EXPR@[16; 20) 16 RANGE_EXPR@16..20
17 LITERAL@[16; 17) 17 LITERAL@16..17
18 INT_NUMBER@[16; 17) "0" 18 INT_NUMBER@16..17 "0"
19 DOT2EQ@[17; 20) "..=" 19 DOT2EQ@17..20 "..="
20 SEMICOLON@[20; 21) ";" 20 SEMICOLON@20..21 ";"
21 WHITESPACE@[21; 26) "\n " 21 WHITESPACE@21..26 "\n "
22 EXPR_STMT@[26; 30) 22 EXPR_STMT@26..30
23 RANGE_EXPR@[26; 29) 23 RANGE_EXPR@26..29
24 DOT2EQ@[26; 29) "..=" 24 DOT2EQ@26..29 "..="
25 SEMICOLON@[29; 30) ";" 25 SEMICOLON@29..30 ";"
26 WHITESPACE@[30; 31) "\n" 26 WHITESPACE@30..31 "\n"
27 R_CURLY@[31; 32) "}" 27 R_CURLY@31..32 "}"
28 WHITESPACE@[32; 33) "\n" 28 WHITESPACE@32..33 "\n"
29error [16; 20): An inclusive range must have an end expression 29error 16..20: An inclusive range must have an end expression
30error [26; 29): An inclusive range must have an end expression 30error 26..29: An inclusive range must have an end expression
diff --git a/crates/ra_syntax/test_data/parser/err/0039_lambda_recovery.rast b/crates/ra_syntax/test_data/parser/err/0039_lambda_recovery.rast
index edf9c3247..433ea7bad 100644
--- a/crates/ra_syntax/test_data/parser/err/0039_lambda_recovery.rast
+++ b/crates/ra_syntax/test_data/parser/err/0039_lambda_recovery.rast
@@ -1,83 +1,83 @@
1SOURCE_FILE@[0; 83) 1SOURCE_FILE@0..83
2 FN_DEF@[0; 82) 2 FN_DEF@0..82
3 FN_KW@[0; 2) "fn" 3 FN_KW@0..2 "fn"
4 WHITESPACE@[2; 3) " " 4 WHITESPACE@2..3 " "
5 NAME@[3; 6) 5 NAME@3..6
6 IDENT@[3; 6) "foo" 6 IDENT@3..6 "foo"
7 PARAM_LIST@[6; 8) 7 PARAM_LIST@6..8
8 L_PAREN@[6; 7) "(" 8 L_PAREN@6..7 "("
9 R_PAREN@[7; 8) ")" 9 R_PAREN@7..8 ")"
10 WHITESPACE@[8; 9) " " 10 WHITESPACE@8..9 " "
11 RET_TYPE@[9; 15) 11 RET_TYPE@9..15
12 THIN_ARROW@[9; 11) "->" 12 THIN_ARROW@9..11 "->"
13 WHITESPACE@[11; 12) " " 13 WHITESPACE@11..12 " "
14 PATH_TYPE@[12; 15) 14 PATH_TYPE@12..15
15 PATH@[12; 15) 15 PATH@12..15
16 PATH_SEGMENT@[12; 15) 16 PATH_SEGMENT@12..15
17 NAME_REF@[12; 15) 17 NAME_REF@12..15
18 IDENT@[12; 15) "i32" 18 IDENT@12..15 "i32"
19 WHITESPACE@[15; 16) " " 19 WHITESPACE@15..16 " "
20 BLOCK_EXPR@[16; 82) 20 BLOCK_EXPR@16..82
21 BLOCK@[16; 82) 21 BLOCK@16..82
22 L_CURLY@[16; 17) "{" 22 L_CURLY@16..17 "{"
23 WHITESPACE@[17; 22) "\n " 23 WHITESPACE@17..22 "\n "
24 EXPR_STMT@[22; 80) 24 EXPR_STMT@22..80
25 METHOD_CALL_EXPR@[22; 79) 25 METHOD_CALL_EXPR@22..79
26 METHOD_CALL_EXPR@[22; 57) 26 METHOD_CALL_EXPR@22..57
27 METHOD_CALL_EXPR@[22; 38) 27 METHOD_CALL_EXPR@22..38
28 ARRAY_EXPR@[22; 31) 28 ARRAY_EXPR@22..31
29 L_BRACK@[22; 23) "[" 29 L_BRACK@22..23 "["
30 LITERAL@[23; 24) 30 LITERAL@23..24
31 INT_NUMBER@[23; 24) "1" 31 INT_NUMBER@23..24 "1"
32 COMMA@[24; 25) "," 32 COMMA@24..25 ","
33 WHITESPACE@[25; 26) " " 33 WHITESPACE@25..26 " "
34 LITERAL@[26; 27) 34 LITERAL@26..27
35 INT_NUMBER@[26; 27) "2" 35 INT_NUMBER@26..27 "2"
36 COMMA@[27; 28) "," 36 COMMA@27..28 ","
37 WHITESPACE@[28; 29) " " 37 WHITESPACE@28..29 " "
38 LITERAL@[29; 30) 38 LITERAL@29..30
39 INT_NUMBER@[29; 30) "3" 39 INT_NUMBER@29..30 "3"
40 R_BRACK@[30; 31) "]" 40 R_BRACK@30..31 "]"
41 DOT@[31; 32) "." 41 DOT@31..32 "."
42 NAME_REF@[32; 36) 42 NAME_REF@32..36
43 IDENT@[32; 36) "iter" 43 IDENT@32..36 "iter"
44 ARG_LIST@[36; 38) 44 ARG_LIST@36..38
45 L_PAREN@[36; 37) "(" 45 L_PAREN@36..37 "("
46 R_PAREN@[37; 38) ")" 46 R_PAREN@37..38 ")"
47 WHITESPACE@[38; 47) "\n " 47 WHITESPACE@38..47 "\n "
48 DOT@[47; 48) "." 48 DOT@47..48 "."
49 NAME_REF@[48; 51) 49 NAME_REF@48..51
50 IDENT@[48; 51) "map" 50 IDENT@48..51 "map"
51 ARG_LIST@[51; 57) 51 ARG_LIST@51..57
52 L_PAREN@[51; 52) "(" 52 L_PAREN@51..52 "("
53 LAMBDA_EXPR@[52; 56) 53 LAMBDA_EXPR@52..56
54 PARAM_LIST@[52; 56) 54 PARAM_LIST@52..56
55 PIPE@[52; 53) "|" 55 PIPE@52..53 "|"
56 PARAM@[53; 55) 56 PARAM@53..55
57 BIND_PAT@[53; 55) 57 BIND_PAT@53..55
58 NAME@[53; 55) 58 NAME@53..55
59 IDENT@[53; 55) "it" 59 IDENT@53..55 "it"
60 PIPE@[55; 56) "|" 60 PIPE@55..56 "|"
61 R_PAREN@[56; 57) ")" 61 R_PAREN@56..57 ")"
62 WHITESPACE@[57; 66) "\n " 62 WHITESPACE@57..66 "\n "
63 DOT@[66; 67) "." 63 DOT@66..67 "."
64 NAME_REF@[67; 70) 64 NAME_REF@67..70
65 IDENT@[67; 70) "max" 65 IDENT@67..70 "max"
66 TYPE_ARG_LIST@[70; 77) 66 TYPE_ARG_LIST@70..77
67 COLON2@[70; 72) "::" 67 COLON2@70..72 "::"
68 L_ANGLE@[72; 73) "<" 68 L_ANGLE@72..73 "<"
69 TYPE_ARG@[73; 76) 69 TYPE_ARG@73..76
70 PATH_TYPE@[73; 76) 70 PATH_TYPE@73..76
71 PATH@[73; 76) 71 PATH@73..76
72 PATH_SEGMENT@[73; 76) 72 PATH_SEGMENT@73..76
73 NAME_REF@[73; 76) 73 NAME_REF@73..76
74 IDENT@[73; 76) "i32" 74 IDENT@73..76 "i32"
75 R_ANGLE@[76; 77) ">" 75 R_ANGLE@76..77 ">"
76 ARG_LIST@[77; 79) 76 ARG_LIST@77..79
77 L_PAREN@[77; 78) "(" 77 L_PAREN@77..78 "("
78 R_PAREN@[78; 79) ")" 78 R_PAREN@78..79 ")"
79 SEMICOLON@[79; 80) ";" 79 SEMICOLON@79..80 ";"
80 WHITESPACE@[80; 81) "\n" 80 WHITESPACE@80..81 "\n"
81 R_CURLY@[81; 82) "}" 81 R_CURLY@81..82 "}"
82 WHITESPACE@[82; 83) "\n" 82 WHITESPACE@82..83 "\n"
83error [56; 56): expected expression 83error 56..56: expected expression