From a1e18695548b5cd6661f26a985b34c8b105e1896 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sat, 29 Feb 2020 21:24:40 +0100 Subject: Rename ast::ImplBlock -> ast::ImplDef --- .../parser/inline/err/0002_misplaced_label_err.txt | 2 +- .../test_data/parser/inline/err/0004_impl_type.txt | 12 +++++------ .../parser/inline/ok/0001_trait_item_list.txt | 2 +- .../test_data/parser/inline/ok/0006_self_param.txt | 2 +- .../parser/inline/ok/0018_arb_self_types.txt | 2 +- .../parser/inline/ok/0021_impl_item_list.txt | 2 +- .../parser/inline/ok/0047_unsafe_default_impl.txt | 2 +- .../parser/inline/ok/0063_impl_block_neg.rs | 1 - .../parser/inline/ok/0063_impl_block_neg.txt | 23 ---------------------- .../parser/inline/ok/0063_impl_def_neg.rs | 1 + .../parser/inline/ok/0063_impl_def_neg.txt | 23 ++++++++++++++++++++++ .../test_data/parser/inline/ok/0079_impl_block.rs | 1 - .../test_data/parser/inline/ok/0079_impl_block.txt | 14 ------------- .../test_data/parser/inline/ok/0079_impl_def.rs | 1 + .../test_data/parser/inline/ok/0079_impl_def.txt | 14 +++++++++++++ .../parser/inline/ok/0087_unsafe_impl.txt | 2 +- .../parser/inline/ok/0097_default_impl.txt | 2 +- .../inline/ok/0118_impl_inner_attributes.txt | 2 +- .../parser/inline/ok/0132_default_fn_type.txt | 2 +- .../parser/inline/ok/0150_impl_type_params.txt | 2 +- .../parser/inline/ok/0152_fn_patterns.txt | 2 +- 21 files changed, 57 insertions(+), 57 deletions(-) delete mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.rs delete mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.txt create mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs create mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.txt delete mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.rs delete mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.txt create mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rs create mode 100644 crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.txt (limited to 'crates/ra_syntax/test_data/parser/inline') diff --git a/crates/ra_syntax/test_data/parser/inline/err/0002_misplaced_label_err.txt b/crates/ra_syntax/test_data/parser/inline/err/0002_misplaced_label_err.txt index 0187d872d..01a853d63 100644 --- a/crates/ra_syntax/test_data/parser/inline/err/0002_misplaced_label_err.txt +++ b/crates/ra_syntax/test_data/parser/inline/err/0002_misplaced_label_err.txt @@ -18,7 +18,7 @@ SOURCE_FILE@[0; 30) LIFETIME@[16; 21) "\'loop" COLON@[21; 22) ":" WHITESPACE@[22; 23) " " - IMPL_BLOCK@[23; 27) + IMPL_DEF@[23; 27) IMPL_KW@[23; 27) "impl" WHITESPACE@[27; 28) "\n" R_CURLY@[28; 29) "}" diff --git a/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.txt b/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.txt index d5aea05c2..124f0a891 100644 --- a/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.txt +++ b/crates/ra_syntax/test_data/parser/inline/err/0004_impl_type.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 87) - IMPL_BLOCK@[0; 12) + IMPL_DEF@[0; 12) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 9) @@ -12,7 +12,7 @@ SOURCE_FILE@[0; 87) L_CURLY@[10; 11) "{" R_CURLY@[11; 12) "}" WHITESPACE@[12; 13) "\n" - IMPL_BLOCK@[13; 33) + IMPL_DEF@[13; 33) IMPL_KW@[13; 17) "impl" WHITESPACE@[17; 18) " " PATH_TYPE@[18; 24) @@ -33,10 +33,10 @@ SOURCE_FILE@[0; 87) L_CURLY@[31; 32) "{" R_CURLY@[32; 33) "}" WHITESPACE@[33; 34) "\n" - IMPL_BLOCK@[34; 38) + IMPL_DEF@[34; 38) IMPL_KW@[34; 38) "impl" WHITESPACE@[38; 39) " " - IMPL_BLOCK@[39; 54) + IMPL_DEF@[39; 54) IMPL_KW@[39; 43) "impl" WHITESPACE@[43; 44) " " PATH_TYPE@[44; 51) @@ -49,7 +49,7 @@ SOURCE_FILE@[0; 87) L_CURLY@[52; 53) "{" R_CURLY@[53; 54) "}" WHITESPACE@[54; 55) "\n" - IMPL_BLOCK@[55; 70) + IMPL_DEF@[55; 70) IMPL_KW@[55; 59) "impl" WHITESPACE@[59; 60) " " PATH_TYPE@[60; 66) @@ -60,7 +60,7 @@ SOURCE_FILE@[0; 87) WHITESPACE@[66; 67) " " FOR_KW@[67; 70) "for" WHITESPACE@[70; 71) " " - IMPL_BLOCK@[71; 86) + IMPL_DEF@[71; 86) IMPL_KW@[71; 75) "impl" WHITESPACE@[75; 76) " " PATH_TYPE@[76; 83) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.txt b/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.txt index d4e710dd4..ad9f0965e 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0001_trait_item_list.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 83) - IMPL_BLOCK@[0; 82) + IMPL_DEF@[0; 82) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.txt b/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.txt index 0ccd12b0a..757ac092a 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0006_self_param.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 128) - IMPL_BLOCK@[0; 127) + IMPL_DEF@[0; 127) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.txt b/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.txt index d0beeb81e..89caee543 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0018_arb_self_types.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 69) - IMPL_BLOCK@[0; 68) + IMPL_DEF@[0; 68) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.txt b/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.txt index 0768f0518..b1af67976 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0021_impl_item_list.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 89) - IMPL_BLOCK@[0; 88) + IMPL_DEF@[0; 88) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.txt b/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.txt index 8f3dcaf88..0a768a8e3 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0047_unsafe_default_impl.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 27) - IMPL_BLOCK@[0; 26) + IMPL_DEF@[0; 26) UNSAFE_KW@[0; 6) "unsafe" WHITESPACE@[6; 7) " " DEFAULT_KW@[7; 14) "default" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.rs b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.rs deleted file mode 100644 index b7527c870..000000000 --- a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.rs +++ /dev/null @@ -1 +0,0 @@ -impl !Send for X {} diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.txt b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.txt deleted file mode 100644 index dfff947fe..000000000 --- a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_block_neg.txt +++ /dev/null @@ -1,23 +0,0 @@ -SOURCE_FILE@[0; 20) - IMPL_BLOCK@[0; 19) - IMPL_KW@[0; 4) "impl" - WHITESPACE@[4; 5) " " - EXCL@[5; 6) "!" - PATH_TYPE@[6; 10) - PATH@[6; 10) - PATH_SEGMENT@[6; 10) - NAME_REF@[6; 10) - IDENT@[6; 10) "Send" - WHITESPACE@[10; 11) " " - FOR_KW@[11; 14) "for" - WHITESPACE@[14; 15) " " - PATH_TYPE@[15; 16) - PATH@[15; 16) - PATH_SEGMENT@[15; 16) - NAME_REF@[15; 16) - IDENT@[15; 16) "X" - WHITESPACE@[16; 17) " " - ITEM_LIST@[17; 19) - L_CURLY@[17; 18) "{" - R_CURLY@[18; 19) "}" - WHITESPACE@[19; 20) "\n" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs new file mode 100644 index 000000000..b7527c870 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs @@ -0,0 +1 @@ +impl !Send for X {} diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.txt b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.txt new file mode 100644 index 000000000..0cc3ac085 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/inline/ok/0063_impl_def_neg.txt @@ -0,0 +1,23 @@ +SOURCE_FILE@[0; 20) + IMPL_DEF@[0; 19) + IMPL_KW@[0; 4) "impl" + WHITESPACE@[4; 5) " " + EXCL@[5; 6) "!" + PATH_TYPE@[6; 10) + PATH@[6; 10) + PATH_SEGMENT@[6; 10) + NAME_REF@[6; 10) + IDENT@[6; 10) "Send" + WHITESPACE@[10; 11) " " + FOR_KW@[11; 14) "for" + WHITESPACE@[14; 15) " " + PATH_TYPE@[15; 16) + PATH@[15; 16) + PATH_SEGMENT@[15; 16) + NAME_REF@[15; 16) + IDENT@[15; 16) "X" + WHITESPACE@[16; 17) " " + ITEM_LIST@[17; 19) + L_CURLY@[17; 18) "{" + R_CURLY@[18; 19) "}" + WHITESPACE@[19; 20) "\n" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.rs b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.rs deleted file mode 100644 index d6337f6b3..000000000 --- a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.rs +++ /dev/null @@ -1 +0,0 @@ -impl Foo {} diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.txt b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.txt deleted file mode 100644 index bda3435e8..000000000 --- a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_block.txt +++ /dev/null @@ -1,14 +0,0 @@ -SOURCE_FILE@[0; 12) - IMPL_BLOCK@[0; 11) - IMPL_KW@[0; 4) "impl" - WHITESPACE@[4; 5) " " - PATH_TYPE@[5; 8) - PATH@[5; 8) - PATH_SEGMENT@[5; 8) - NAME_REF@[5; 8) - IDENT@[5; 8) "Foo" - WHITESPACE@[8; 9) " " - ITEM_LIST@[9; 11) - L_CURLY@[9; 10) "{" - R_CURLY@[10; 11) "}" - WHITESPACE@[11; 12) "\n" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rs b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rs new file mode 100644 index 000000000..d6337f6b3 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.rs @@ -0,0 +1 @@ +impl Foo {} diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.txt b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.txt new file mode 100644 index 000000000..4c2863ba7 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/inline/ok/0079_impl_def.txt @@ -0,0 +1,14 @@ +SOURCE_FILE@[0; 12) + IMPL_DEF@[0; 11) + IMPL_KW@[0; 4) "impl" + WHITESPACE@[4; 5) " " + PATH_TYPE@[5; 8) + PATH@[5; 8) + PATH_SEGMENT@[5; 8) + NAME_REF@[5; 8) + IDENT@[5; 8) "Foo" + WHITESPACE@[8; 9) " " + ITEM_LIST@[9; 11) + L_CURLY@[9; 10) "{" + R_CURLY@[10; 11) "}" + WHITESPACE@[11; 12) "\n" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.txt b/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.txt index 590e2a88f..e614acc6f 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0087_unsafe_impl.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 19) - IMPL_BLOCK@[0; 18) + IMPL_DEF@[0; 18) UNSAFE_KW@[0; 6) "unsafe" WHITESPACE@[6; 7) " " IMPL_KW@[7; 11) "impl" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.txt b/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.txt index ada94a824..af9077270 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0097_default_impl.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 20) - IMPL_BLOCK@[0; 19) + IMPL_DEF@[0; 19) DEFAULT_KW@[0; 7) "default" WHITESPACE@[7; 8) " " IMPL_KW@[8; 12) "impl" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.txt b/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.txt index 0e9e9b95b..5053ebde7 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.txt @@ -8,7 +8,7 @@ SOURCE_FILE@[0; 94) L_CURLY@[6; 7) "{" R_CURLY@[7; 8) "}" WHITESPACE@[8; 9) "\n" - IMPL_BLOCK@[9; 93) + IMPL_DEF@[9; 93) IMPL_KW@[9; 13) "impl" WHITESPACE@[13; 14) " " PATH_TYPE@[14; 15) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.txt b/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.txt index 022070b0c..e1734224b 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0132_default_fn_type.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 69) - IMPL_BLOCK@[0; 68) + IMPL_DEF@[0; 68) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.txt b/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.txt index 47fadef85..2d46eebb3 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0150_impl_type_params.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 29) - IMPL_BLOCK@[0; 28) + IMPL_DEF@[0; 28) IMPL_KW@[0; 4) "impl" TYPE_PARAM_LIST@[4; 18) L_ANGLE@[4; 5) "<" diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0152_fn_patterns.txt b/crates/ra_syntax/test_data/parser/inline/ok/0152_fn_patterns.txt index 933f5b7bd..b30030de3 100644 --- a/crates/ra_syntax/test_data/parser/inline/ok/0152_fn_patterns.txt +++ b/crates/ra_syntax/test_data/parser/inline/ok/0152_fn_patterns.txt @@ -1,5 +1,5 @@ SOURCE_FILE@[0; 137) - IMPL_BLOCK@[0; 136) + IMPL_DEF@[0; 136) IMPL_KW@[0; 4) "impl" WHITESPACE@[4; 5) " " PATH_TYPE@[5; 6) -- cgit v1.2.3