aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2019-09-10 13:57:51 +0100
committerAleksey Kladov <[email protected]>2019-09-10 13:57:51 +0100
commited726081d1df2fb6a1c21101996dcae203f79021 (patch)
tree14e74b81c7195bcd5b308e799c3fd447e76274ca
parent1c5800dee89b14406e816accf41c597e7860aff8 (diff)
add a jointness parser tests
cc https://github.com/rust-lang/rust/issues/64242
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.rs5
-rw-r--r--crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.txt50
2 files changed, 55 insertions, 0 deletions
diff --git a/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.rs b/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.rs
new file mode 100644
index 000000000..cd204f65e
--- /dev/null
+++ b/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.rs
@@ -0,0 +1,5 @@
1type X = ();
2
3fn main() {
4 let ():::X = ();
5}
diff --git a/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.txt b/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.txt
new file mode 100644
index 000000000..d656e74b1
--- /dev/null
+++ b/crates/ra_syntax/test_data/parser/ok/0055_dot_dot_dot.txt
@@ -0,0 +1,50 @@
1SOURCE_FILE@[0; 49)
2 TYPE_ALIAS_DEF@[0; 12)
3 TYPE_KW@[0; 4) "type"
4 WHITESPACE@[4; 5) " "
5 NAME@[5; 6)
6 IDENT@[5; 6) "X"
7 WHITESPACE@[6; 7) " "
8 EQ@[7; 8) "="
9 WHITESPACE@[8; 9) " "
10 TUPLE_TYPE@[9; 11)
11 L_PAREN@[9; 10) "("
12 R_PAREN@[10; 11) ")"
13 SEMI@[11; 12) ";"
14 WHITESPACE@[12; 14) "\n\n"
15 FN_DEF@[14; 48)
16 FN_KW@[14; 16) "fn"
17 WHITESPACE@[16; 17) " "
18 NAME@[17; 21)
19 IDENT@[17; 21) "main"
20 PARAM_LIST@[21; 23)
21 L_PAREN@[21; 22) "("
22 R_PAREN@[22; 23) ")"
23 WHITESPACE@[23; 24) " "
24 BLOCK_EXPR@[24; 48)
25 BLOCK@[24; 48)
26 L_CURLY@[24; 25) "{"
27 WHITESPACE@[25; 30) "\n "
28 LET_STMT@[30; 46)
29 LET_KW@[30; 33) "let"
30 WHITESPACE@[33; 34) " "
31 TUPLE_PAT@[34; 36)
32 L_PAREN@[34; 35) "("
33 R_PAREN@[35; 36) ")"
34 COLON@[36; 37) ":"
35 PATH_TYPE@[37; 40)
36 PATH@[37; 40)
37 PATH_SEGMENT@[37; 40)
38 COLONCOLON@[37; 39) "::"
39 NAME_REF@[39; 40)
40 IDENT@[39; 40) "X"
41 WHITESPACE@[40; 41) " "
42 EQ@[41; 42) "="
43 WHITESPACE@[42; 43) " "
44 TUPLE_EXPR@[43; 45)
45 L_PAREN@[43; 44) "("
46 R_PAREN@[44; 45) ")"
47 SEMI@[45; 46) ";"
48 WHITESPACE@[46; 47) "\n"
49 R_CURLY@[47; 48) "}"
50 WHITESPACE@[48; 49) "\n"