diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-09-02 20:20:24 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2019-09-02 20:20:24 +0100 |
commit | 7faec1c30046769d4ae490e15cf5405bcfbdeef8 (patch) | |
tree | 6d268b721027a5350928a6c5a0ec227b5fde8ebc /crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt | |
parent | a8397deab914240aca8f015fb3736689919c0a5b (diff) | |
parent | e94587e3153b52684fd3f6b82c8e7efc09ff5c8d (diff) |
Merge #1752
1752: Always wrap blocks into block expressions r=flodiebold a=matklad
This way, things like function bodies are expressions, and we don't have to single them out
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt')
-rw-r--r-- | crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt | 167 |
1 files changed, 84 insertions, 83 deletions
diff --git a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt index 52eb7d5e2..d12f4c99b 100644 --- a/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt +++ b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt | |||
@@ -32,89 +32,90 @@ SOURCE_FILE@[0; 183) | |||
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@[47; 161) | 35 | BLOCK_EXPR@[47; 161) |
36 | L_CURLY@[47; 48) "{" | 36 | BLOCK@[47; 161) |
37 | WHITESPACE@[48; 57) "\n " | 37 | L_CURLY@[47; 48) "{" |
38 | LET_STMT@[57; 85) | 38 | WHITESPACE@[48; 57) "\n " |
39 | LET_KW@[57; 60) "let" | 39 | LET_STMT@[57; 85) |
40 | WHITESPACE@[60; 61) " " | 40 | LET_KW@[57; 60) "let" |
41 | BIND_PAT@[61; 64) | 41 | WHITESPACE@[60; 61) " " |
42 | NAME@[61; 64) | 42 | BIND_PAT@[61; 64) |
43 | IDENT@[61; 64) "res" | 43 | NAME@[61; 64) |
44 | WHITESPACE@[64; 65) " " | 44 | IDENT@[61; 64) "res" |
45 | EQ@[65; 66) "=" | 45 | WHITESPACE@[64; 65) " " |
46 | WHITESPACE@[66; 67) " " | 46 | EQ@[65; 66) "=" |
47 | METHOD_CALL_EXPR@[67; 84) | 47 | WHITESPACE@[66; 67) " " |
48 | FIELD_EXPR@[67; 78) | 48 | METHOD_CALL_EXPR@[67; 84) |
49 | PATH_EXPR@[67; 71) | 49 | FIELD_EXPR@[67; 78) |
50 | PATH@[67; 71) | 50 | PATH_EXPR@[67; 71) |
51 | PATH_SEGMENT@[67; 71) | 51 | PATH@[67; 71) |
52 | SELF_KW@[67; 71) "self" | 52 | PATH_SEGMENT@[67; 71) |
53 | DOT@[71; 72) "." | 53 | SELF_KW@[67; 71) "self" |
54 | NAME_REF@[72; 78) | 54 | DOT@[71; 72) "." |
55 | IDENT@[72; 78) "scopes" | 55 | NAME_REF@[72; 78) |
56 | DOT@[78; 79) "." | 56 | IDENT@[72; 78) "scopes" |
57 | NAME_REF@[79; 82) | 57 | DOT@[78; 79) "." |
58 | IDENT@[79; 82) "len" | 58 | NAME_REF@[79; 82) |
59 | ARG_LIST@[82; 84) | 59 | IDENT@[79; 82) "len" |
60 | L_PAREN@[82; 83) "(" | 60 | ARG_LIST@[82; 84) |
61 | R_PAREN@[83; 84) ")" | 61 | L_PAREN@[82; 83) "(" |
62 | SEMI@[84; 85) ";" | 62 | R_PAREN@[83; 84) ")" |
63 | WHITESPACE@[85; 94) "\n " | 63 | SEMI@[84; 85) ";" |
64 | METHOD_CALL_EXPR@[94; 155) | 64 | WHITESPACE@[85; 94) "\n " |
65 | FIELD_EXPR@[94; 105) | 65 | METHOD_CALL_EXPR@[94; 155) |
66 | PATH_EXPR@[94; 98) | 66 | FIELD_EXPR@[94; 105) |
67 | PATH@[94; 98) | 67 | PATH_EXPR@[94; 98) |
68 | PATH_SEGMENT@[94; 98) | 68 | PATH@[94; 98) |
69 | SELF_KW@[94; 98) "self" | 69 | PATH_SEGMENT@[94; 98) |
70 | DOT@[98; 99) "." | 70 | SELF_KW@[94; 98) "self" |
71 | NAME_REF@[99; 105) | 71 | DOT@[98; 99) "." |
72 | IDENT@[99; 105) "scopes" | 72 | NAME_REF@[99; 105) |
73 | DOT@[105; 106) "." | 73 | IDENT@[99; 105) "scopes" |
74 | NAME_REF@[106; 110) | 74 | DOT@[105; 106) "." |
75 | IDENT@[106; 110) "push" | 75 | NAME_REF@[106; 110) |
76 | ARG_LIST@[110; 155) | 76 | IDENT@[106; 110) "push" |
77 | L_PAREN@[110; 111) "(" | 77 | ARG_LIST@[110; 155) |
78 | RECORD_LIT@[111; 154) | 78 | L_PAREN@[110; 111) "(" |
79 | PATH@[111; 120) | 79 | RECORD_LIT@[111; 154) |
80 | PATH_SEGMENT@[111; 120) | 80 | PATH@[111; 120) |
81 | NAME_REF@[111; 120) | 81 | PATH_SEGMENT@[111; 120) |
82 | IDENT@[111; 120) "ScopeData" | 82 | NAME_REF@[111; 120) |
83 | WHITESPACE@[120; 121) " " | 83 | IDENT@[111; 120) "ScopeData" |
84 | RECORD_FIELD_LIST@[121; 154) | 84 | WHITESPACE@[120; 121) " " |
85 | L_CURLY@[121; 122) "{" | 85 | RECORD_FIELD_LIST@[121; 154) |
86 | WHITESPACE@[122; 123) " " | 86 | L_CURLY@[121; 122) "{" |
87 | RECORD_FIELD@[123; 135) | 87 | WHITESPACE@[122; 123) " " |
88 | NAME_REF@[123; 129) | 88 | RECORD_FIELD@[123; 135) |
89 | IDENT@[123; 129) "parent" | 89 | NAME_REF@[123; 129) |
90 | COLON@[129; 130) ":" | 90 | IDENT@[123; 129) "parent" |
91 | WHITESPACE@[130; 131) " " | 91 | COLON@[129; 130) ":" |
92 | PATH_EXPR@[131; 135) | 92 | WHITESPACE@[130; 131) " " |
93 | PATH@[131; 135) | 93 | PATH_EXPR@[131; 135) |
94 | PATH_SEGMENT@[131; 135) | 94 | PATH@[131; 135) |
95 | NAME_REF@[131; 135) | 95 | PATH_SEGMENT@[131; 135) |
96 | IDENT@[131; 135) "None" | 96 | NAME_REF@[131; 135) |
97 | COMMA@[135; 136) "," | 97 | IDENT@[131; 135) "None" |
98 | WHITESPACE@[136; 137) " " | 98 | COMMA@[135; 136) "," |
99 | RECORD_FIELD@[137; 152) | 99 | WHITESPACE@[136; 137) " " |
100 | NAME_REF@[137; 144) | 100 | RECORD_FIELD@[137; 152) |
101 | IDENT@[137; 144) "entries" | 101 | NAME_REF@[137; 144) |
102 | COLON@[144; 145) ":" | 102 | IDENT@[137; 144) "entries" |
103 | WHITESPACE@[145; 146) " " | 103 | COLON@[144; 145) ":" |
104 | MACRO_CALL@[146; 152) | 104 | WHITESPACE@[145; 146) " " |
105 | PATH@[146; 149) | 105 | MACRO_CALL@[146; 152) |
106 | PATH_SEGMENT@[146; 149) | 106 | PATH@[146; 149) |
107 | NAME_REF@[146; 149) | 107 | PATH_SEGMENT@[146; 149) |
108 | IDENT@[146; 149) "vec" | 108 | NAME_REF@[146; 149) |
109 | EXCL@[149; 150) "!" | 109 | IDENT@[146; 149) "vec" |
110 | TOKEN_TREE@[150; 152) | 110 | EXCL@[149; 150) "!" |
111 | L_BRACK@[150; 151) "[" | 111 | TOKEN_TREE@[150; 152) |
112 | R_BRACK@[151; 152) "]" | 112 | L_BRACK@[150; 151) "[" |
113 | WHITESPACE@[152; 153) " " | 113 | R_BRACK@[151; 152) "]" |
114 | R_CURLY@[153; 154) "}" | 114 | WHITESPACE@[152; 153) " " |
115 | R_PAREN@[154; 155) ")" | 115 | R_CURLY@[153; 154) "}" |
116 | WHITESPACE@[155; 160) "\n " | 116 | R_PAREN@[154; 155) ")" |
117 | R_CURLY@[160; 161) "}" | 117 | WHITESPACE@[155; 160) "\n " |
118 | R_CURLY@[160; 161) "}" | ||
118 | WHITESPACE@[161; 167) "\n\n " | 119 | WHITESPACE@[161; 167) "\n\n " |
119 | FN_DEF@[167; 180) | 120 | FN_DEF@[167; 180) |
120 | FN_KW@[167; 169) "fn" | 121 | FN_KW@[167; 169) "fn" |