diff options
author | Aleksey Kladov <[email protected]> | 2019-07-24 10:38:21 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-07-24 10:49:19 +0100 |
commit | 459241f272748ff2e57b2c7e84f5a04f78d67edb (patch) | |
tree | 2353f8f068962313d0b2748aab58b71c4ca456d2 /crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt | |
parent | 4d544fbf9b664b6a29d358d3cb41cdd7cd15e4d6 (diff) |
move syntax tests to unit tests
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 | 131 |
1 files changed, 131 insertions, 0 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 new file mode 100644 index 000000000..51def2d8f --- /dev/null +++ b/crates/ra_syntax/test_data/parser/err/0018_incomplete_fn.txt | |||
@@ -0,0 +1,131 @@ | |||
1 | SOURCE_FILE@[0; 183) | ||
2 | IMPL_BLOCK@[0; 182) | ||
3 | IMPL_KW@[0; 4) "impl" | ||
4 | WHITESPACE@[4; 5) " " | ||
5 | PATH_TYPE@[5; 13) | ||
6 | PATH@[5; 13) | ||
7 | PATH_SEGMENT@[5; 13) | ||
8 | NAME_REF@[5; 13) | ||
9 | IDENT@[5; 13) "FnScopes" | ||
10 | WHITESPACE@[13; 14) " " | ||
11 | ITEM_LIST@[14; 182) | ||
12 | L_CURLY@[14; 15) "{" | ||
13 | WHITESPACE@[15; 20) "\n " | ||
14 | FN_DEF@[20; 161) | ||
15 | FN_KW@[20; 22) "fn" | ||
16 | WHITESPACE@[22; 23) " " | ||
17 | NAME@[23; 32) | ||
18 | IDENT@[23; 32) "new_scope" | ||
19 | PARAM_LIST@[32; 35) | ||
20 | L_PAREN@[32; 33) "(" | ||
21 | PARAM@[33; 34) | ||
22 | REF_PAT@[33; 34) | ||
23 | AMP@[33; 34) "&" | ||
24 | R_PAREN@[34; 35) ")" | ||
25 | WHITESPACE@[35; 36) " " | ||
26 | RET_TYPE@[36; 46) | ||
27 | THIN_ARROW@[36; 38) "->" | ||
28 | WHITESPACE@[38; 39) " " | ||
29 | PATH_TYPE@[39; 46) | ||
30 | PATH@[39; 46) | ||
31 | PATH_SEGMENT@[39; 46) | ||
32 | NAME_REF@[39; 46) | ||
33 | IDENT@[39; 46) "ScopeId" | ||
34 | WHITESPACE@[46; 47) " " | ||
35 | BLOCK@[47; 161) | ||
36 | L_CURLY@[47; 48) "{" | ||
37 | WHITESPACE@[48; 57) "\n " | ||
38 | LET_STMT@[57; 85) | ||
39 | LET_KW@[57; 60) "let" | ||
40 | WHITESPACE@[60; 61) " " | ||
41 | BIND_PAT@[61; 64) | ||
42 | NAME@[61; 64) | ||
43 | IDENT@[61; 64) "res" | ||
44 | WHITESPACE@[64; 65) " " | ||
45 | EQ@[65; 66) "=" | ||
46 | WHITESPACE@[66; 67) " " | ||
47 | METHOD_CALL_EXPR@[67; 84) | ||
48 | FIELD_EXPR@[67; 78) | ||
49 | PATH_EXPR@[67; 71) | ||
50 | PATH@[67; 71) | ||
51 | PATH_SEGMENT@[67; 71) | ||
52 | SELF_KW@[67; 71) "self" | ||
53 | DOT@[71; 72) "." | ||
54 | NAME_REF@[72; 78) | ||
55 | IDENT@[72; 78) "scopes" | ||
56 | DOT@[78; 79) "." | ||
57 | NAME_REF@[79; 82) | ||
58 | IDENT@[79; 82) "len" | ||
59 | ARG_LIST@[82; 84) | ||
60 | L_PAREN@[82; 83) "(" | ||
61 | R_PAREN@[83; 84) ")" | ||
62 | SEMI@[84; 85) ";" | ||
63 | WHITESPACE@[85; 94) "\n " | ||
64 | METHOD_CALL_EXPR@[94; 155) | ||
65 | FIELD_EXPR@[94; 105) | ||
66 | PATH_EXPR@[94; 98) | ||
67 | PATH@[94; 98) | ||
68 | PATH_SEGMENT@[94; 98) | ||
69 | SELF_KW@[94; 98) "self" | ||
70 | DOT@[98; 99) "." | ||
71 | NAME_REF@[99; 105) | ||
72 | IDENT@[99; 105) "scopes" | ||
73 | DOT@[105; 106) "." | ||
74 | NAME_REF@[106; 110) | ||
75 | IDENT@[106; 110) "push" | ||
76 | ARG_LIST@[110; 155) | ||
77 | L_PAREN@[110; 111) "(" | ||
78 | STRUCT_LIT@[111; 154) | ||
79 | PATH@[111; 120) | ||
80 | PATH_SEGMENT@[111; 120) | ||
81 | NAME_REF@[111; 120) | ||
82 | IDENT@[111; 120) "ScopeData" | ||
83 | WHITESPACE@[120; 121) " " | ||
84 | NAMED_FIELD_LIST@[121; 154) | ||
85 | L_CURLY@[121; 122) "{" | ||
86 | WHITESPACE@[122; 123) " " | ||
87 | NAMED_FIELD@[123; 135) | ||
88 | NAME_REF@[123; 129) | ||
89 | IDENT@[123; 129) "parent" | ||
90 | COLON@[129; 130) ":" | ||
91 | WHITESPACE@[130; 131) " " | ||
92 | PATH_EXPR@[131; 135) | ||
93 | PATH@[131; 135) | ||
94 | PATH_SEGMENT@[131; 135) | ||
95 | NAME_REF@[131; 135) | ||
96 | IDENT@[131; 135) "None" | ||
97 | COMMA@[135; 136) "," | ||
98 | WHITESPACE@[136; 137) " " | ||
99 | NAMED_FIELD@[137; 152) | ||
100 | NAME_REF@[137; 144) | ||
101 | IDENT@[137; 144) "entries" | ||
102 | COLON@[144; 145) ":" | ||
103 | WHITESPACE@[145; 146) " " | ||
104 | MACRO_CALL@[146; 152) | ||
105 | PATH@[146; 149) | ||
106 | PATH_SEGMENT@[146; 149) | ||
107 | NAME_REF@[146; 149) | ||
108 | IDENT@[146; 149) "vec" | ||
109 | EXCL@[149; 150) "!" | ||
110 | TOKEN_TREE@[150; 152) | ||
111 | L_BRACK@[150; 151) "[" | ||
112 | R_BRACK@[151; 152) "]" | ||
113 | WHITESPACE@[152; 153) " " | ||
114 | R_CURLY@[153; 154) "}" | ||
115 | R_PAREN@[154; 155) ")" | ||
116 | WHITESPACE@[155; 160) "\n " | ||
117 | R_CURLY@[160; 161) "}" | ||
118 | WHITESPACE@[161; 167) "\n\n " | ||
119 | FN_DEF@[167; 180) | ||
120 | FN_KW@[167; 169) "fn" | ||
121 | WHITESPACE@[169; 170) " " | ||
122 | NAME@[170; 180) | ||
123 | IDENT@[170; 180) "set_parent" | ||
124 | WHITESPACE@[180; 181) "\n" | ||
125 | R_CURLY@[181; 182) "}" | ||
126 | WHITESPACE@[182; 183) "\n" | ||
127 | error 34: expected pattern | ||
128 | error 34: expected COLON | ||
129 | error 34: expected type | ||
130 | error 180: expected function arguments | ||
131 | error 180: expected a block | ||