diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/data/parser/inline/0074_expr_binding_power.rs | 3 | ||||
-rw-r--r-- | tests/data/parser/inline/0074_expr_binding_power.txt | 48 | ||||
-rw-r--r-- | tests/data/parser/inline/0075_try_expr.rs | 3 | ||||
-rw-r--r-- | tests/data/parser/inline/0075_try_expr.txt | 25 |
4 files changed, 79 insertions, 0 deletions
diff --git a/tests/data/parser/inline/0074_expr_binding_power.rs b/tests/data/parser/inline/0074_expr_binding_power.rs new file mode 100644 index 000000000..db855fd02 --- /dev/null +++ b/tests/data/parser/inline/0074_expr_binding_power.rs | |||
@@ -0,0 +1,3 @@ | |||
1 | fn foo() { | ||
2 | 1 + 2 * 3 == 1 * 2 + 3 | ||
3 | } | ||
diff --git a/tests/data/parser/inline/0074_expr_binding_power.txt b/tests/data/parser/inline/0074_expr_binding_power.txt new file mode 100644 index 000000000..05aad25e9 --- /dev/null +++ b/tests/data/parser/inline/0074_expr_binding_power.txt | |||
@@ -0,0 +1,48 @@ | |||
1 | FILE@[0; 40) | ||
2 | FN_ITEM@[0; 40) | ||
3 | FN_KW@[0; 2) | ||
4 | NAME@[2; 6) | ||
5 | WHITESPACE@[2; 3) | ||
6 | IDENT@[3; 6) "foo" | ||
7 | PARAM_LIST@[6; 9) | ||
8 | L_PAREN@[6; 7) | ||
9 | R_PAREN@[7; 8) | ||
10 | WHITESPACE@[8; 9) | ||
11 | BLOCK_EXPR@[9; 40) | ||
12 | L_CURLY@[9; 10) | ||
13 | BIN_EXPR@[10; 38) | ||
14 | BIN_EXPR@[10; 25) | ||
15 | LITERAL@[10; 17) | ||
16 | WHITESPACE@[10; 15) | ||
17 | INT_NUMBER@[15; 16) "1" | ||
18 | WHITESPACE@[16; 17) | ||
19 | PLUS@[17; 18) | ||
20 | BIN_EXPR@[18; 25) | ||
21 | LITERAL@[18; 21) | ||
22 | WHITESPACE@[18; 19) | ||
23 | INT_NUMBER@[19; 20) "2" | ||
24 | WHITESPACE@[20; 21) | ||
25 | STAR@[21; 22) | ||
26 | LITERAL@[22; 25) | ||
27 | WHITESPACE@[22; 23) | ||
28 | INT_NUMBER@[23; 24) "3" | ||
29 | WHITESPACE@[24; 25) | ||
30 | EQEQ@[25; 27) | ||
31 | BIN_EXPR@[27; 38) | ||
32 | BIN_EXPR@[27; 34) | ||
33 | LITERAL@[27; 30) | ||
34 | WHITESPACE@[27; 28) | ||
35 | INT_NUMBER@[28; 29) "1" | ||
36 | WHITESPACE@[29; 30) | ||
37 | STAR@[30; 31) | ||
38 | LITERAL@[31; 34) | ||
39 | WHITESPACE@[31; 32) | ||
40 | INT_NUMBER@[32; 33) "2" | ||
41 | WHITESPACE@[33; 34) | ||
42 | PLUS@[34; 35) | ||
43 | LITERAL@[35; 38) | ||
44 | WHITESPACE@[35; 36) | ||
45 | INT_NUMBER@[36; 37) "3" | ||
46 | WHITESPACE@[37; 38) | ||
47 | R_CURLY@[38; 39) | ||
48 | WHITESPACE@[39; 40) | ||
diff --git a/tests/data/parser/inline/0075_try_expr.rs b/tests/data/parser/inline/0075_try_expr.rs new file mode 100644 index 000000000..8b74f7bc8 --- /dev/null +++ b/tests/data/parser/inline/0075_try_expr.rs | |||
@@ -0,0 +1,3 @@ | |||
1 | fn foo() { | ||
2 | x?; | ||
3 | } | ||
diff --git a/tests/data/parser/inline/0075_try_expr.txt b/tests/data/parser/inline/0075_try_expr.txt new file mode 100644 index 000000000..49edce956 --- /dev/null +++ b/tests/data/parser/inline/0075_try_expr.txt | |||
@@ -0,0 +1,25 @@ | |||
1 | FILE@[0; 21) | ||
2 | FN_ITEM@[0; 21) | ||
3 | FN_KW@[0; 2) | ||
4 | NAME@[2; 6) | ||
5 | WHITESPACE@[2; 3) | ||
6 | IDENT@[3; 6) "foo" | ||
7 | PARAM_LIST@[6; 9) | ||
8 | L_PAREN@[6; 7) | ||
9 | R_PAREN@[7; 8) | ||
10 | WHITESPACE@[8; 9) | ||
11 | BLOCK_EXPR@[9; 21) | ||
12 | L_CURLY@[9; 10) | ||
13 | EXPR_STMT@[10; 19) | ||
14 | TRY_EXPR@[10; 17) | ||
15 | PATH_EXPR@[10; 16) | ||
16 | PATH@[10; 16) | ||
17 | PATH_SEGMENT@[10; 16) | ||
18 | NAME_REF@[10; 16) | ||
19 | WHITESPACE@[10; 15) | ||
20 | IDENT@[15; 16) "x" | ||
21 | QUESTION@[16; 17) | ||
22 | SEMI@[17; 18) | ||
23 | WHITESPACE@[18; 19) | ||
24 | R_CURLY@[19; 20) | ||
25 | WHITESPACE@[20; 21) | ||