From 134fe4f566d94fd4ca91c6417fab0ae7b3e4275f Mon Sep 17 00:00:00 2001 From: DJMcNab <36049421+DJMcNab@users.noreply.github.com> Date: Thu, 20 Dec 2018 16:45:54 +0000 Subject: [PATCH] Fix the tests and fix the precommit hook --- .../ra_syntax/src/grammar/expressions/atom.rs | 4 +- crates/ra_syntax/src/grammar/items.rs | 2 +- crates/ra_syntax/src/grammar/items/traits.rs | 2 +- .../ra_syntax/src/grammar/items/use_item.rs | 2 +- crates/ra_syntax/src/grammar/type_args.rs | 2 +- crates/ra_syntax/src/grammar/types.rs | 6 +- .../0028_macro_2.0.rs} | 1 - .../0028_macro_2.0.txt} | 4 +- .../tests/data/parser/inline/0058_type_arg.rs | 1 - .../data/parser/inline/0063_lambda_expr.txt | 91 ------- .../data/parser/inline/0069_match_arm.txt | 148 ----------- .../0001_array_type_missing_semi.rs} | 0 .../0001_array_type_missing_semi.txt} | 0 .../0002_misplaced_label_err.rs} | 0 .../0002_misplaced_label_err.txt} | 0 .../0003_pointer_type_no_mutability.rs} | 0 .../0003_pointer_type_no_mutability.txt} | 0 .../0004_impl_type.rs} | 0 .../0004_impl_type.txt} | 0 .../0005_fn_pointer_type_missing_fn.rs} | 0 .../0005_fn_pointer_type_missing_fn.txt} | 0 .../0006_unsafe_block_in_mod.rs} | 0 .../0006_unsafe_block_in_mod.txt} | 0 .../0001_trait_item_list.rs} | 0 .../0001_trait_item_list.txt} | 0 .../0002_use_tree_list.rs} | 0 .../0002_use_tree_list.txt} | 0 .../0003_where_pred_for.rs} | 0 .../0003_where_pred_for.txt} | 0 .../0004_value_parameters_no_patterns.rs} | 0 .../0004_value_parameters_no_patterns.txt} | 0 .../0005_function_type_params.rs} | 0 .../0005_function_type_params.txt} | 0 .../0006_self_param.rs} | 0 .../0006_self_param.txt} | 0 .../0007_type_param_bounds.rs} | 0 .../0007_type_param_bounds.txt} | 0 .../0008_path_part.rs} | 0 .../0008_path_part.txt} | 0 .../0009_loop_expr.rs} | 0 .../0009_loop_expr.txt} | 0 .../0010_extern_block.rs} | 0 .../0010_extern_block.txt} | 0 .../0011_field_expr.rs} | 0 .../0011_field_expr.txt} | 0 .../0012_type_item_where_clause.rs} | 0 .../0012_type_item_where_clause.txt} | 1 - .../0013_pointer_type_mut.rs} | 0 .../0013_pointer_type_mut.txt} | 0 .../0014_never_type.rs} | 0 .../0014_never_type.txt} | 0 .../0015_continue_expr.rs} | 0 .../0015_continue_expr.txt} | 0 .../0016_unsafe_trait.rs} | 0 .../0016_unsafe_trait.txt} | 0 .../0017_array_type.rs} | 0 .../0017_array_type.txt} | 0 .../0018_arb_self_types.rs} | 0 .../0018_arb_self_types.txt} | 0 .../0019_unary_expr.rs} | 0 .../0019_unary_expr.txt} | 0 .../{0116_use_star.rs => ok/0020_use_star.rs} | 0 .../0020_use_star.txt} | 0 .../0021_impl_item_list.rs} | 0 .../0021_impl_item_list.txt} | 0 .../0022_crate_visibility.rs} | 0 .../0022_crate_visibility.txt} | 0 .../0023_placeholder_type.rs} | 0 .../0023_placeholder_type.txt} | 0 .../0024_slice_pat.rs} | 0 .../0024_slice_pat.txt} | 0 .../parser/inline/{ => ok}/0025_slice_type.rs | 0 .../inline/{ => ok}/0025_slice_type.txt | 0 .../0026_tuple_pat_fields.rs} | 0 .../0026_tuple_pat_fields.txt} | 0 .../{0035_ref_pat.rs => ok/0027_ref_pat.rs} | 0 .../{0035_ref_pat.txt => ok/0027_ref_pat.txt} | 0 .../0028_impl_trait_type.rs} | 0 .../0028_impl_trait_type.txt} | 0 .../0029_cast_expr.rs} | 0 .../0029_cast_expr.txt} | 0 .../inline/{0076_cond.rs => ok/0030_cond.rs} | 0 .../{0076_cond.txt => ok/0030_cond.txt} | 0 .../0031_while_expr.rs} | 0 .../0031_while_expr.txt} | 0 .../0032_fn_pointer_type.rs} | 0 .../0032_fn_pointer_type.txt} | 0 .../0033_reference_type;.rs} | 0 .../0033_reference_type;.txt} | 0 .../0034_break_expr.rs} | 0 .../0034_break_expr.txt} | 0 .../{0068_pub_expr.rs => ok/0035_pub_expr.rs} | 0 .../0035_pub_expr.txt} | 0 .../0036_unsafe_extern_fn.rs} | 0 .../0036_unsafe_extern_fn.txt} | 0 .../0037_qual_paths.rs} | 0 .../0037_qual_paths.txt} | 0 .../0038_full_range_expr.rs} | 0 .../0038_full_range_expr.txt} | 0 .../data/parser/inline/ok/0039_type_arg.rs | 1 + .../0039_type_arg.txt} | 8 +- .../0040_crate_keyword_vis.rs} | 0 .../0040_crate_keyword_vis.txt} | 0 .../0041_trait_item.rs} | 0 .../0041_trait_item.txt} | 0 .../0042_call_expr.rs} | 0 .../0042_call_expr.txt} | 0 .../0043_use_alias.rs} | 2 +- .../0043_use_alias.txt} | 41 ++- .../0044_block_items.rs} | 0 .../0044_block_items.txt} | 0 .../0045_param_list_opt_patterns.rs} | 0 .../0045_param_list_opt_patterns.txt} | 0 .../0046_singleton_tuple_type.rs} | 0 .../0046_singleton_tuple_type.txt} | 0 .../0047_unsafe_default_impl.rs} | 0 .../0047_unsafe_default_impl.txt} | 0 .../0048_path_type_with_bounds.rs} | 0 .../0048_path_type_with_bounds.txt} | 0 .../0049_let_stmt;.rs} | 0 .../0049_let_stmt;.txt} | 0 .../{0091_fn_decl.rs => ok/0050_fn_decl.rs} | 0 .../{0091_fn_decl.txt => ok/0050_fn_decl.txt} | 0 .../0051_unit_type.rs} | 0 .../0051_unit_type.txt} | 0 .../0052_path_type.rs} | 0 .../0052_path_type.txt} | 0 .../0053_path_expr.rs} | 0 .../0053_path_expr.txt} | 0 .../0054_field_attrs.rs} | 0 .../0054_field_attrs.txt} | 0 .../0055_literal_pattern.rs} | 0 .../0055_literal_pattern.txt} | 0 .../0056_where_clause.rs} | 0 .../0056_where_clause.txt} | 0 .../{0002_const_fn.rs => ok/0057_const_fn.rs} | 0 .../0057_const_fn.txt} | 0 .../0058_range_pat.rs} | 0 .../0058_range_pat.txt} | 0 .../0059_match_arms_commas.rs} | 0 .../0059_match_arms_commas.txt} | 0 .../0060_extern_crate.rs} | 0 .../0060_extern_crate.txt} | 0 .../parser/inline/{ => ok}/0061_struct_lit.rs | 0 .../inline/{ => ok}/0061_struct_lit.txt | 0 .../0062_mod_contents.rs} | 0 .../0062_mod_contents.txt} | 0 .../0063_impl_item_neg.rs} | 0 .../0063_impl_item_neg.txt} | 0 .../{0065_if_expr.rs => ok/0064_if_expr.rs} | 0 .../{0065_if_expr.txt => ok/0064_if_expr.txt} | 0 .../0065_dyn_trait_type.rs} | 0 .../0065_dyn_trait_type.txt} | 0 .../0066_match_arm.rs} | 2 +- .../data/parser/inline/ok/0066_match_arm.txt | 146 ++++++++++ .../0067_crate_path.rs} | 0 .../0067_crate_path.txt} | 0 .../0068_union_items.rs} | 0 .../0068_union_items.txt} | 0 .../0069_use_tree_list_after_path.rs} | 0 .../0069_use_tree_list_after_path.txt} | 0 .../0070_stmt_bin_expr_ambiguity.rs} | 0 .../0070_stmt_bin_expr_ambiguity.txt} | 0 .../0071_match_expr.rs} | 0 .../0071_match_expr.txt} | 0 .../0072_return_expr.rs} | 0 .../0072_return_expr.txt} | 0 .../0073_type_item_type_params.rs} | 0 .../0073_type_item_type_params.txt} | 0 .../0074_stmt_postfix_expr_ambiguity.rs} | 0 .../0074_stmt_postfix_expr_ambiguity.txt} | 0 .../{0045_block.rs => ok/0075_block.rs} | 0 .../{0045_block.txt => ok/0075_block.txt} | 0 .../0076_function_where_clause.rs} | 0 .../0076_function_where_clause.txt} | 0 .../{0075_try_expr.rs => ok/0077_try_expr.rs} | 0 .../0077_try_expr.txt} | 0 .../0078_type_item.rs} | 0 .../0078_type_item.txt} | 0 .../0079_impl_item.rs} | 0 .../0079_impl_item.txt} | 0 .../0080_postfix_range.rs} | 0 .../0080_postfix_range.txt} | 0 .../{0031_for_type.rs => ok/0081_for_type.rs} | 0 .../0081_for_type.txt} | 0 .../{0044_ref_expr.rs => ok/0082_ref_expr.rs} | 0 .../0082_ref_expr.txt} | 0 .../0083_struct_items.rs} | 0 .../0083_struct_items.txt} | 0 .../0084_paren_type.rs} | 0 .../0084_paren_type.txt} | 0 .../0085_expr_literals.rs} | 0 .../0085_expr_literals.txt} | 0 .../0086_function_ret_type.rs} | 0 .../0086_function_ret_type.txt} | 0 .../0087_unsafe_impl.rs} | 0 .../0087_unsafe_impl.txt} | 0 .../0088_break_ambiguity.rs} | 0 .../0088_break_ambiguity.txt} | 0 .../0089_extern_fn.rs} | 0 .../0089_extern_fn.txt} | 0 .../0090_type_param_default.rs} | 0 .../0090_type_param_default.txt} | 0 .../0091_auto_trait.rs} | 0 .../0091_auto_trait.txt} | 0 .../0092_fn_pointer_type_with_ret.rs} | 0 .../0092_fn_pointer_type_with_ret.txt} | 0 .../0093_index_expr.rs} | 0 .../0093_index_expr.txt} | 0 .../0094_unsafe_auto_trait.rs} | 0 .../0094_unsafe_auto_trait.txt} | 0 .../0095_placeholder_pat.rs} | 0 .../0095_placeholder_pat.txt} | 0 .../0096_no_semi_after_block.rs} | 0 .../0096_no_semi_after_block.txt} | 0 .../0097_default_impl.rs} | 0 .../0097_default_impl.txt} | 0 .../0098_const_unsafe_fn.rs} | 0 .../0098_const_unsafe_fn.txt} | 0 .../0099_param_list.rs} | 0 .../0099_param_list.txt} | 0 .../{0085_for_expr.rs => ok/0100_for_expr.rs} | 0 .../0100_for_expr.txt} | 0 .../0101_unsafe_fn.rs} | 0 .../0101_unsafe_fn.txt} | 0 .../0102_field_pat_list.rs} | 0 .../0102_field_pat_list.txt} | 0 .../0103_array_expr.rs} | 0 .../0103_array_expr.txt} | 0 .../0104_path_fn_trait_args.rs} | 0 .../0104_path_fn_trait_args.txt} | 0 .../0105_block_expr.rs} | 0 .../0105_block_expr.txt} | 0 .../0106_lambda_expr.rs} | 0 .../0106_lambda_expr.txt} | 0 .../0107_method_call_expr.rs} | 0 .../0107_method_call_expr.txt} | 0 .../0108_tuple_expr.rs} | 0 .../0108_tuple_expr.txt} | 0 .../{0107_label.rs => ok/0109_label.rs} | 0 .../{0107_label.txt => ok/0109_label.txt} | 0 .../{0114_use_path.rs => ok/0110_use_path.rs} | 0 .../0110_use_path.txt} | 0 .../0111_tuple_pat.rs} | 0 .../0111_tuple_pat.txt} | 0 .../{0034_bind_pat.rs => ok/0112_bind_pat.rs} | 0 .../0112_bind_pat.txt} | 0 .../tests/data/parser/ok/0029_range_forms.txt | 44 ++- ..._in_call.rs => 0034_crate_path_in_call.rs} | 0 ...n_call.txt => 0034_crate_path_in_call.txt} | 0 .../tests/data/parser/ok/0034_macro_stuck.txt | 250 ------------------ crates/ra_syntax/tests/test.rs | 2 +- crates/tools/src/bin/pre-commit.rs | 3 +- crates/tools/src/lib.rs | 2 +- crates/tools/src/main.rs | 6 +- 255 files changed, 210 insertions(+), 561 deletions(-) rename crates/ra_syntax/tests/data/parser/{ok/0034_macro_2.0.rs => err/0028_macro_2.0.rs} (99%) rename crates/ra_syntax/tests/data/parser/{ok/0034_macro_2.0.txt => err/0028_macro_2.0.txt} (99%) delete mode 100644 crates/ra_syntax/tests/data/parser/inline/0058_type_arg.rs delete mode 100644 crates/ra_syntax/tests/data/parser/inline/0063_lambda_expr.txt delete mode 100644 crates/ra_syntax/tests/data/parser/inline/0069_match_arm.txt rename crates/ra_syntax/tests/data/parser/inline/{0023_array_type_missing_semi.rs => err/0001_array_type_missing_semi.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0023_array_type_missing_semi.txt => err/0001_array_type_missing_semi.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0108_misplaced_label_err.rs => err/0002_misplaced_label_err.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0108_misplaced_label_err.txt => err/0002_misplaced_label_err.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0021_pointer_type_no_mutability.rs => err/0003_pointer_type_no_mutability.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0021_pointer_type_no_mutability.txt => err/0003_pointer_type_no_mutability.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0111_impl_type.rs => err/0004_impl_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0111_impl_type.txt => err/0004_impl_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0029_fn_pointer_type_missing_fn.rs => err/0005_fn_pointer_type_missing_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0029_fn_pointer_type_missing_fn.txt => err/0005_fn_pointer_type_missing_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0013_unsafe_block_in_mod.rs => err/0006_unsafe_block_in_mod.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0013_unsafe_block_in_mod.txt => err/0006_unsafe_block_in_mod.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0049_trait_item_list.rs => ok/0001_trait_item_list.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0049_trait_item_list.txt => ok/0001_trait_item_list.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0118_use_tree_list.rs => ok/0002_use_tree_list.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0118_use_tree_list.txt => ok/0002_use_tree_list.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0113_where_pred_for.rs => ok/0003_where_pred_for.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0113_where_pred_for.txt => ok/0003_where_pred_for.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0096_value_parameters_no_patterns.rs => ok/0004_value_parameters_no_patterns.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0096_value_parameters_no_patterns.txt => ok/0004_value_parameters_no_patterns.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0060_function_type_params.rs => ok/0005_function_type_params.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0060_function_type_params.txt => ok/0005_function_type_params.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0055_self_param.rs => ok/0006_self_param.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0055_self_param.txt => ok/0006_self_param.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0041_type_param_bounds.rs => ok/0007_type_param_bounds.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0041_type_param_bounds.txt => ok/0007_type_param_bounds.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0072_path_part.rs => ok/0008_path_part.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0072_path_part.txt => ok/0008_path_part.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0084_loop_expr.rs => ok/0009_loop_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0084_loop_expr.txt => ok/0009_loop_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0003_extern_block.rs => ok/0010_extern_block.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0003_extern_block.txt => ok/0010_extern_block.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0052_field_expr.rs => ok/0011_field_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0052_field_expr.txt => ok/0011_field_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0016_type_item_where_clause.rs => ok/0012_type_item_where_clause.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0016_type_item_where_clause.txt => ok/0012_type_item_where_clause.txt} (95%) rename crates/ra_syntax/tests/data/parser/inline/{0022_pointer_type_mut.rs => ok/0013_pointer_type_mut.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0022_pointer_type_mut.txt => ok/0013_pointer_type_mut.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0020_never_type.rs => ok/0014_never_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0020_never_type.txt => ok/0014_never_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0105_continue_expr.rs => ok/0015_continue_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0105_continue_expr.txt => ok/0015_continue_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0007_unsafe_trait.rs => ok/0016_unsafe_trait.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0007_unsafe_trait.txt => ok/0016_unsafe_trait.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0024_array_type.rs => ok/0017_array_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0024_array_type.txt => ok/0017_array_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0104_arb_self_types.rs => ok/0018_arb_self_types.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0104_arb_self_types.txt => ok/0018_arb_self_types.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0074_unary_expr.rs => ok/0019_unary_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0074_unary_expr.txt => ok/0019_unary_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0116_use_star.rs => ok/0020_use_star.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0116_use_star.txt => ok/0020_use_star.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0073_impl_item_list.rs => ok/0021_impl_item_list.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0073_impl_item_list.txt => ok/0021_impl_item_list.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0037_crate_visibility.rs => ok/0022_crate_visibility.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0037_crate_visibility.txt => ok/0022_crate_visibility.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0027_placeholder_type.rs => ok/0023_placeholder_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0027_placeholder_type.txt => ok/0023_placeholder_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0089_slice_pat.rs => ok/0024_slice_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0089_slice_pat.txt => ok/0024_slice_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{ => ok}/0025_slice_type.rs (100%) rename crates/ra_syntax/tests/data/parser/inline/{ => ok}/0025_slice_type.txt (100%) rename crates/ra_syntax/tests/data/parser/inline/{0071_tuple_pat_fields.rs => ok/0026_tuple_pat_fields.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0071_tuple_pat_fields.txt => ok/0026_tuple_pat_fields.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0035_ref_pat.rs => ok/0027_ref_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0035_ref_pat.txt => ok/0027_ref_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0063_impl_trait_type.rs => ok/0028_impl_trait_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0063_impl_trait_type.txt => ok/0028_impl_trait_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0079_cast_expr.rs => ok/0029_cast_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0079_cast_expr.txt => ok/0029_cast_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0076_cond.rs => ok/0030_cond.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0076_cond.txt => ok/0030_cond.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0077_while_expr.rs => ok/0031_while_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0077_while_expr.txt => ok/0031_while_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0028_fn_pointer_type.rs => ok/0032_fn_pointer_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0028_fn_pointer_type.txt => ok/0032_fn_pointer_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0026_reference_type;.rs => ok/0033_reference_type;.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0026_reference_type;.txt => ok/0033_reference_type;.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0106_break_expr.rs => ok/0034_break_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0106_break_expr.txt => ok/0034_break_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0068_pub_expr.rs => ok/0035_pub_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0068_pub_expr.txt => ok/0035_pub_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0012_unsafe_extern_fn.rs => ok/0036_unsafe_extern_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0012_unsafe_extern_fn.txt => ok/0036_unsafe_extern_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0101_qual_paths.rs => ok/0037_qual_paths.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0101_qual_paths.txt => ok/0037_qual_paths.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0102_full_range_expr.rs => ok/0038_full_range_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0102_full_range_expr.txt => ok/0038_full_range_expr.txt} (100%) create mode 100644 crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.rs rename crates/ra_syntax/tests/data/parser/inline/{0058_type_arg.txt => ok/0039_type_arg.txt} (91%) rename crates/ra_syntax/tests/data/parser/inline/{0099_crate_keyword_vis.rs => ok/0040_crate_keyword_vis.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0099_crate_keyword_vis.txt => ok/0040_crate_keyword_vis.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0056_trait_item.rs => ok/0041_trait_item.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0056_trait_item.txt => ok/0041_trait_item.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0043_call_expr.rs => ok/0042_call_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0043_call_expr.txt => ok/0042_call_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0115_use_alias.rs => ok/0043_use_alias.rs} (73%) rename crates/ra_syntax/tests/data/parser/inline/{0115_use_alias.txt => ok/0043_use_alias.txt} (83%) rename crates/ra_syntax/tests/data/parser/inline/{0053_block_items.rs => ok/0044_block_items.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0053_block_items.txt => ok/0044_block_items.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0097_param_list_opt_patterns.rs => ok/0045_param_list_opt_patterns.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0097_param_list_opt_patterns.txt => ok/0045_param_list_opt_patterns.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0019_singleton_tuple_type.rs => ok/0046_singleton_tuple_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0019_singleton_tuple_type.txt => ok/0046_singleton_tuple_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0010_unsafe_default_impl.rs => ok/0047_unsafe_default_impl.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0010_unsafe_default_impl.txt => ok/0047_unsafe_default_impl.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0095_path_type_with_bounds.rs => ok/0048_path_type_with_bounds.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0095_path_type_with_bounds.txt => ok/0048_path_type_with_bounds.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0050_let_stmt;.rs => ok/0049_let_stmt;.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0050_let_stmt;.txt => ok/0049_let_stmt;.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0091_fn_decl.rs => ok/0050_fn_decl.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0091_fn_decl.txt => ok/0050_fn_decl.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0018_unit_type.rs => ok/0051_unit_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0018_unit_type.txt => ok/0051_unit_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0032_path_type.rs => ok/0052_path_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0032_path_type.txt => ok/0052_path_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0039_path_expr.rs => ok/0053_path_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0039_path_expr.txt => ok/0053_path_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0103_field_attrs.rs => ok/0054_field_attrs.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0103_field_attrs.txt => ok/0054_field_attrs.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0092_literal_pattern.rs => ok/0055_literal_pattern.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0092_literal_pattern.txt => ok/0055_literal_pattern.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0098_where_clause.rs => ok/0056_where_clause.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0098_where_clause.txt => ok/0056_where_clause.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0002_const_fn.rs => ok/0057_const_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0002_const_fn.txt => ok/0057_const_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0094_range_pat.rs => ok/0058_range_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0094_range_pat.txt => ok/0058_range_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0085_match_arms_commas.rs => ok/0059_match_arms_commas.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0085_match_arms_commas.txt => ok/0059_match_arms_commas.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0005_extern_crate.rs => ok/0060_extern_crate.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0005_extern_crate.txt => ok/0060_extern_crate.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{ => ok}/0061_struct_lit.rs (100%) rename crates/ra_syntax/tests/data/parser/inline/{ => ok}/0061_struct_lit.txt (100%) rename crates/ra_syntax/tests/data/parser/inline/{0078_mod_contents.rs => ok/0062_mod_contents.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0078_mod_contents.txt => ok/0062_mod_contents.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0048_impl_item_neg.rs => ok/0063_impl_item_neg.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0048_impl_item_neg.txt => ok/0063_impl_item_neg.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0065_if_expr.rs => ok/0064_if_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0065_if_expr.txt => ok/0064_if_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0100_dyn_trait_type.rs => ok/0065_dyn_trait_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0100_dyn_trait_type.txt => ok/0065_dyn_trait_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0069_match_arm.rs => ok/0066_match_arm.rs} (74%) create mode 100644 crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.txt rename crates/ra_syntax/tests/data/parser/inline/{0112_crate_path.rs => ok/0067_crate_path.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0112_crate_path.txt => ok/0067_crate_path.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0110_union_items.rs => ok/0068_union_items.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0110_union_items.txt => ok/0068_union_items.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0117_use_tree_list_after_path.rs => ok/0069_use_tree_list_after_path.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0117_use_tree_list_after_path.txt => ok/0069_use_tree_list_after_path.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0088_stmt_bin_expr_ambiguity.rs => ok/0070_stmt_bin_expr_ambiguity.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0088_stmt_bin_expr_ambiguity.txt => ok/0070_stmt_bin_expr_ambiguity.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0070_match_expr.rs => ok/0071_match_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0070_match_expr.txt => ok/0071_match_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0068_return_expr.rs => ok/0072_return_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0068_return_expr.txt => ok/0072_return_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0014_type_item_type_params.rs => ok/0073_type_item_type_params.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0014_type_item_type_params.txt => ok/0073_type_item_type_params.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0087_stmt_postfix_expr_ambiguity.rs => ok/0074_stmt_postfix_expr_ambiguity.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0087_stmt_postfix_expr_ambiguity.txt => ok/0074_stmt_postfix_expr_ambiguity.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0045_block.rs => ok/0075_block.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0045_block.txt => ok/0075_block.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0059_function_where_clause.rs => ok/0076_function_where_clause.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0059_function_where_clause.txt => ok/0076_function_where_clause.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0075_try_expr.rs => ok/0077_try_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0075_try_expr.txt => ok/0077_try_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0015_type_item.rs => ok/0078_type_item.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0015_type_item.txt => ok/0078_type_item.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0047_impl_item.rs => ok/0079_impl_item.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0047_impl_item.txt => ok/0079_impl_item.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0083_postfix_range.rs => ok/0080_postfix_range.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0083_postfix_range.txt => ok/0080_postfix_range.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0031_for_type.rs => ok/0081_for_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0031_for_type.txt => ok/0081_for_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0044_ref_expr.rs => ok/0082_ref_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0044_ref_expr.txt => ok/0082_ref_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0109_struct_items.rs => ok/0083_struct_items.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0109_struct_items.txt => ok/0083_struct_items.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0017_paren_type.rs => ok/0084_paren_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0017_paren_type.txt => ok/0084_paren_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0040_expr_literals.rs => ok/0085_expr_literals.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0040_expr_literals.txt => ok/0085_expr_literals.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0038_function_ret_type.rs => ok/0086_function_ret_type.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0038_function_ret_type.txt => ok/0086_function_ret_type.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0008_unsafe_impl.rs => ok/0087_unsafe_impl.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0008_unsafe_impl.txt => ok/0087_unsafe_impl.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0119_break_ambiguity.rs => ok/0088_break_ambiguity.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0119_break_ambiguity.txt => ok/0088_break_ambiguity.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0004_extern_fn.rs => ok/0089_extern_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0004_extern_fn.txt => ok/0089_extern_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0042_type_param_default.rs => ok/0090_type_param_default.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0042_type_param_default.txt => ok/0090_type_param_default.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0057_auto_trait.rs => ok/0091_auto_trait.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0057_auto_trait.txt => ok/0091_auto_trait.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0030_fn_pointer_type_with_ret.rs => ok/0092_fn_pointer_type_with_ret.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0030_fn_pointer_type_with_ret.txt => ok/0092_fn_pointer_type_with_ret.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0081_index_expr.rs => ok/0093_index_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0081_index_expr.txt => ok/0093_index_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0009_unsafe_auto_trait.rs => ok/0094_unsafe_auto_trait.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0009_unsafe_auto_trait.txt => ok/0094_unsafe_auto_trait.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0036_placeholder_pat.rs => ok/0095_placeholder_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0036_placeholder_pat.txt => ok/0095_placeholder_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0086_no_semi_after_block.rs => ok/0096_no_semi_after_block.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0086_no_semi_after_block.txt => ok/0096_no_semi_after_block.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0046_default_impl.rs => ok/0097_default_impl.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0046_default_impl.txt => ok/0097_default_impl.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0001_const_unsafe_fn.rs => ok/0098_const_unsafe_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0001_const_unsafe_fn.txt => ok/0098_const_unsafe_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0064_param_list.rs => ok/0099_param_list.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0064_param_list.txt => ok/0099_param_list.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0085_for_expr.rs => ok/0100_for_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0085_for_expr.txt => ok/0100_for_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0011_unsafe_fn.rs => ok/0101_unsafe_fn.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0011_unsafe_fn.txt => ok/0101_unsafe_fn.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0054_field_pat_list.rs => ok/0102_field_pat_list.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0054_field_pat_list.txt => ok/0102_field_pat_list.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0086_array_expr.rs => ok/0103_array_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0086_array_expr.txt => ok/0103_array_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0093_path_fn_trait_args.rs => ok/0104_path_fn_trait_args.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0093_path_fn_trait_args.txt => ok/0104_path_fn_trait_args.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0067_block_expr.rs => ok/0105_block_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0067_block_expr.txt => ok/0105_block_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0066_lambda_expr.rs => ok/0106_lambda_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0066_lambda_expr.txt => ok/0106_lambda_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0051_method_call_expr.rs => ok/0107_method_call_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0051_method_call_expr.txt => ok/0107_method_call_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0080_tuple_expr.rs => ok/0108_tuple_expr.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0080_tuple_expr.txt => ok/0108_tuple_expr.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0107_label.rs => ok/0109_label.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0107_label.txt => ok/0109_label.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0114_use_path.rs => ok/0110_use_path.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0114_use_path.txt => ok/0110_use_path.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0082_tuple_pat.rs => ok/0111_tuple_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0082_tuple_pat.txt => ok/0111_tuple_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0034_bind_pat.rs => ok/0112_bind_pat.rs} (100%) rename crates/ra_syntax/tests/data/parser/inline/{0034_bind_pat.txt => ok/0112_bind_pat.txt} (100%) rename crates/ra_syntax/tests/data/parser/ok/{0035_crate_path_in_call.rs => 0034_crate_path_in_call.rs} (100%) rename crates/ra_syntax/tests/data/parser/ok/{0035_crate_path_in_call.txt => 0034_crate_path_in_call.txt} (100%) delete mode 100644 crates/ra_syntax/tests/data/parser/ok/0034_macro_stuck.txt diff --git a/crates/ra_syntax/src/grammar/expressions/atom.rs b/crates/ra_syntax/src/grammar/expressions/atom.rs index 3b5749318d..31b09ac5b3 100644 --- a/crates/ra_syntax/src/grammar/expressions/atom.rs +++ b/crates/ra_syntax/src/grammar/expressions/atom.rs @@ -89,7 +89,7 @@ pub(super) fn atom_expr(p: &mut Parser, r: Restrictions) -> Option<(CompletedMar WHILE_KW => while_expr(p, Some(m)), L_CURLY => block_expr(p, Some(m)), _ => { - // test misplaced_label_err + // test_err misplaced_label_err // fn main() { // 'loop: impl // } @@ -354,7 +354,7 @@ pub(crate) fn match_arm_list(p: &mut Parser) { // fn foo() { // match () { // _ => (), -// _ if Test>{field: 0} => (), +// _ if Test > Test{field: 0} => (), // X | Y if Z => (), // | X | Y if Z => (), // | X => (), diff --git a/crates/ra_syntax/src/grammar/items.rs b/crates/ra_syntax/src/grammar/items.rs index 4473c2fab9..b646dd0702 100644 --- a/crates/ra_syntax/src/grammar/items.rs +++ b/crates/ra_syntax/src/grammar/items.rs @@ -89,7 +89,7 @@ pub(super) fn maybe_item(p: &mut Parser, flavor: ItemFlavor) -> MaybeItem { // modifiers has_mods |= p.eat(CONST_KW); - // test unsafe_block_in_mod + // test_err unsafe_block_in_mod // fn foo(){} unsafe { } fn bar(){} if p.at(UNSAFE_KW) && p.nth(1) != L_CURLY { p.eat(UNSAFE_KW); diff --git a/crates/ra_syntax/src/grammar/items/traits.rs b/crates/ra_syntax/src/grammar/items/traits.rs index 31258c2537..d4da8b2f72 100644 --- a/crates/ra_syntax/src/grammar/items/traits.rs +++ b/crates/ra_syntax/src/grammar/items/traits.rs @@ -116,7 +116,7 @@ fn choose_type_params_over_qpath(p: &Parser) -> bool { && (p.nth(2) == R_ANGLE || p.nth(2) == COMMA || p.nth(2) == COLON || p.nth(2) == EQ) } -// test impl_type +// test_err impl_type // impl Type {} // impl Trait1 for T {} // impl impl NotType {} diff --git a/crates/ra_syntax/src/grammar/items/use_item.rs b/crates/ra_syntax/src/grammar/items/use_item.rs index b3c78f3513..5111d37ebd 100644 --- a/crates/ra_syntax/src/grammar/items/use_item.rs +++ b/crates/ra_syntax/src/grammar/items/use_item.rs @@ -74,7 +74,7 @@ fn use_tree(p: &mut Parser) { // other::path as some_other_name, // different::path as different_name, // yet::another::path, - // running::out::of::synonyms::for::different::* + // running::out::of::synonyms::for_::different::* // }; opt_alias(p); } diff --git a/crates/ra_syntax/src/grammar/type_args.rs b/crates/ra_syntax/src/grammar/type_args.rs index 29ff6e5344..f889419c51 100644 --- a/crates/ra_syntax/src/grammar/type_args.rs +++ b/crates/ra_syntax/src/grammar/type_args.rs @@ -26,7 +26,7 @@ pub(super) fn opt_type_arg_list(p: &mut Parser, colon_colon_required: bool) { } // test type_arg -// type A = B<'static, i32, Item=u64> +// type A = B<'static, i32, Item=u64>; fn type_arg(p: &mut Parser) { let m = p.start(); match p.current() { diff --git a/crates/ra_syntax/src/grammar/types.rs b/crates/ra_syntax/src/grammar/types.rs index 811d399d4e..a933b986bc 100644 --- a/crates/ra_syntax/src/grammar/types.rs +++ b/crates/ra_syntax/src/grammar/types.rs @@ -97,7 +97,7 @@ fn pointer_type(p: &mut Parser) { // type C = *mut (); MUT_KW | CONST_KW => p.bump(), _ => { - // test pointer_type_no_mutability + // test_err pointer_type_no_mutability // type T = *(); p.error( "expected mut or const in raw pointer type \ @@ -132,7 +132,7 @@ fn array_or_slice_type(p: &mut Parser) { p.expect(R_BRACK); ARRAY_TYPE } - // test array_type_missing_semi + // test_err array_type_missing_semi // type T = [() 92]; _ => { p.error("expected `;` or `]`"); @@ -175,7 +175,7 @@ fn fn_pointer_type(p: &mut Parser) { if p.at(EXTERN_KW) { abi(p); } - // test fn_pointer_type_missing_fn + // test_err fn_pointer_type_missing_fn // type F = unsafe (); if !p.eat(FN_KW) { m.abandon(p); diff --git a/crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.rs b/crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.rs similarity index 99% rename from crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.rs rename to crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.rs index 2a70ee83a4..781047ba19 100644 --- a/crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.rs +++ b/crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.rs @@ -13,4 +13,3 @@ fn test_use_tree_merge() { ); } } - diff --git a/crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.txt b/crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.txt similarity index 99% rename from crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.txt rename to crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.txt index caff8df76a..12919fab7a 100644 --- a/crates/ra_syntax/tests/data/parser/ok/0034_macro_2.0.txt +++ b/crates/ra_syntax/tests/data/parser/err/0028_macro_2.0.txt @@ -1,4 +1,4 @@ -SOURCE_FILE@[0; 350) +SOURCE_FILE@[0; 349) MACRO_CALL@[0; 41) PATH@[0; 5) PATH_SEGMENT@[0; 5) @@ -314,4 +314,4 @@ SOURCE_FILE@[0; 350) R_CURLY@[345; 346) WHITESPACE@[346; 347) R_CURLY@[347; 348) - WHITESPACE@[348; 350) + WHITESPACE@[348; 349) diff --git a/crates/ra_syntax/tests/data/parser/inline/0058_type_arg.rs b/crates/ra_syntax/tests/data/parser/inline/0058_type_arg.rs deleted file mode 100644 index f0c8cc3a8e..0000000000 --- a/crates/ra_syntax/tests/data/parser/inline/0058_type_arg.rs +++ /dev/null @@ -1 +0,0 @@ -type A = B<'static, i32, Item=u64> diff --git a/crates/ra_syntax/tests/data/parser/inline/0063_lambda_expr.txt b/crates/ra_syntax/tests/data/parser/inline/0063_lambda_expr.txt deleted file mode 100644 index 8c1340c4ae..0000000000 --- a/crates/ra_syntax/tests/data/parser/inline/0063_lambda_expr.txt +++ /dev/null @@ -1,91 +0,0 @@ -SOURCE_FILE@[0; 74) - FN_DEF@[0; 74) - FN_KW@[0; 2) - NAME@[2; 6) - WHITESPACE@[2; 3) - IDENT@[3; 6) "foo" - PARAM_LIST@[6; 9) - L_PAREN@[6; 7) - R_PAREN@[7; 8) - WHITESPACE@[8; 9) - BLOCK_EXPR@[9; 74) - L_CURLY@[9; 10) - EXPR_STMT@[10; 26) - LAMBDA_EXPR@[10; 20) - PARAM_LIST@[10; 18) - WHITESPACE@[10; 15) - PIPE@[15; 16) - PIPE@[16; 17) - WHITESPACE@[17; 18) - TUPLE_EXPR@[18; 20) - L_PAREN@[18; 19) - R_PAREN@[19; 20) - SEMI@[20; 21) - WHITESPACE@[21; 26) - EXPR_STMT@[26; 48) - LAMBDA_EXPR@[26; 42) - PARAM_LIST@[26; 29) - PIPE@[26; 27) - PIPE@[27; 28) - WHITESPACE@[28; 29) - THIN_ARROW@[29; 31) - PATH_TYPE@[31; 36) - PATH@[31; 36) - PATH_SEGMENT@[31; 36) - NAME_REF@[31; 36) - WHITESPACE@[31; 32) - IDENT@[32; 35) "i32" - WHITESPACE@[35; 36) - BLOCK_EXPR@[36; 42) - L_CURLY@[36; 37) - LITERAL@[37; 41) - WHITESPACE@[37; 38) - INT_NUMBER@[38; 40) "92" - WHITESPACE@[40; 41) - R_CURLY@[41; 42) - SEMI@[42; 43) - WHITESPACE@[43; 48) - EXPR_STMT@[48; 59) - LAMBDA_EXPR@[48; 53) - PARAM_LIST@[48; 52) - PIPE@[48; 49) - PARAM@[49; 50) - BIND_PAT@[49; 50) - NAME@[49; 50) - IDENT@[49; 50) "x" - PIPE@[50; 51) - WHITESPACE@[51; 52) - PATH_EXPR@[52; 53) - PATH@[52; 53) - PATH_SEGMENT@[52; 53) - NAME_REF@[52; 53) - IDENT@[52; 53) "x" - SEMI@[53; 54) - WHITESPACE@[54; 59) - EXPR_STMT@[59; 72) - LAMBDA_EXPR@[59; 70) - PARAM_LIST@[59; 69) - PIPE@[59; 60) - PARAM@[60; 66) - BIND_PAT@[60; 61) - NAME@[60; 61) - IDENT@[60; 61) "x" - COLON@[61; 62) - PATH_TYPE@[62; 66) - PATH@[62; 66) - PATH_SEGMENT@[62; 66) - NAME_REF@[62; 66) - WHITESPACE@[62; 63) - IDENT@[63; 66) "i32" - COMMA@[66; 67) - PIPE@[67; 68) - WHITESPACE@[68; 69) - PATH_EXPR@[69; 70) - PATH@[69; 70) - PATH_SEGMENT@[69; 70) - NAME_REF@[69; 70) - IDENT@[69; 70) "x" - SEMI@[70; 71) - WHITESPACE@[71; 72) - R_CURLY@[72; 73) - WHITESPACE@[73; 74) diff --git a/crates/ra_syntax/tests/data/parser/inline/0069_match_arm.txt b/crates/ra_syntax/tests/data/parser/inline/0069_match_arm.txt deleted file mode 100644 index e5647765cb..0000000000 --- a/crates/ra_syntax/tests/data/parser/inline/0069_match_arm.txt +++ /dev/null @@ -1,148 +0,0 @@ -SOURCE_FILE@[0; 161) - FN_DEF@[0; 160) - FN_KW@[0; 2) - WHITESPACE@[2; 3) - NAME@[3; 6) - IDENT@[3; 6) "foo" - PARAM_LIST@[6; 8) - L_PAREN@[6; 7) - R_PAREN@[7; 8) - WHITESPACE@[8; 9) - BLOCK@[9; 160) - L_CURLY@[9; 10) - WHITESPACE@[10; 15) - EXPR_STMT@[15; 158) - MATCH_EXPR@[15; 157) - MATCH_KW@[15; 20) - WHITESPACE@[20; 21) - TUPLE_EXPR@[21; 23) - L_PAREN@[21; 22) - R_PAREN@[22; 23) - WHITESPACE@[23; 24) - MATCH_ARM_LIST@[24; 157) - L_CURLY@[24; 25) - WHITESPACE@[25; 34) - MATCH_ARM@[34; 41) - PLACEHOLDER_PAT@[34; 35) - UNDERSCORE@[34; 35) - WHITESPACE@[35; 36) - FAT_ARROW@[36; 38) - WHITESPACE@[38; 39) - TUPLE_EXPR@[39; 41) - L_PAREN@[39; 40) - R_PAREN@[40; 41) - COMMA@[41; 42) - WHITESPACE@[42; 51) - MATCH_ARM@[51; 77) - PLACEHOLDER_PAT@[51; 52) - UNDERSCORE@[51; 52) - WHITESPACE@[52; 53) - IF_KW@[53; 55) - WHITESPACE@[55; 56) - BIN_EXPR@[56; 71) - PATH_EXPR@[56; 60) - PATH@[56; 60) - PATH_SEGMENT@[56; 60) - NAME_REF@[56; 60) - IDENT@[56; 60) "Test" - R_ANGLE@[60; 61) - BLOCK_EXPR@[61; 71) - BLOCK@[61; 71) - L_CURLY@[61; 62) - EXPR_STMT@[62; 67) - PATH_EXPR@[62; 67) - PATH@[62; 67) - PATH_SEGMENT@[62; 67) - NAME_REF@[62; 67) - IDENT@[62; 67) "field" - err: `expected SEMI` - err: `expected expression` - EXPR_STMT@[67; 68) - ERROR@[67; 68) - COLON@[67; 68) - err: `expected SEMI` - WHITESPACE@[68; 69) - LITERAL@[69; 70) - INT_NUMBER@[69; 70) "0" - R_CURLY@[70; 71) - WHITESPACE@[71; 72) - FAT_ARROW@[72; 74) - WHITESPACE@[74; 75) - TUPLE_EXPR@[75; 77) - L_PAREN@[75; 76) - R_PAREN@[76; 77) - COMMA@[77; 78) - WHITESPACE@[78; 87) - MATCH_ARM@[87; 103) - BIND_PAT@[87; 88) - NAME@[87; 88) - IDENT@[87; 88) "X" - WHITESPACE@[88; 89) - PIPE@[89; 90) - WHITESPACE@[90; 91) - BIND_PAT@[91; 92) - NAME@[91; 92) - IDENT@[91; 92) "Y" - WHITESPACE@[92; 93) - IF_KW@[93; 95) - WHITESPACE@[95; 96) - PATH_EXPR@[96; 97) - PATH@[96; 97) - PATH_SEGMENT@[96; 97) - NAME_REF@[96; 97) - IDENT@[96; 97) "Z" - WHITESPACE@[97; 98) - FAT_ARROW@[98; 100) - WHITESPACE@[100; 101) - TUPLE_EXPR@[101; 103) - L_PAREN@[101; 102) - R_PAREN@[102; 103) - COMMA@[103; 104) - WHITESPACE@[104; 113) - MATCH_ARM@[113; 131) - PIPE@[113; 114) - WHITESPACE@[114; 115) - BIND_PAT@[115; 116) - NAME@[115; 116) - IDENT@[115; 116) "X" - WHITESPACE@[116; 117) - PIPE@[117; 118) - WHITESPACE@[118; 119) - BIND_PAT@[119; 120) - NAME@[119; 120) - IDENT@[119; 120) "Y" - WHITESPACE@[120; 121) - IF_KW@[121; 123) - WHITESPACE@[123; 124) - PATH_EXPR@[124; 125) - PATH@[124; 125) - PATH_SEGMENT@[124; 125) - NAME_REF@[124; 125) - IDENT@[124; 125) "Z" - WHITESPACE@[125; 126) - FAT_ARROW@[126; 128) - WHITESPACE@[128; 129) - TUPLE_EXPR@[129; 131) - L_PAREN@[129; 130) - R_PAREN@[130; 131) - COMMA@[131; 132) - WHITESPACE@[132; 141) - MATCH_ARM@[141; 150) - PIPE@[141; 142) - WHITESPACE@[142; 143) - BIND_PAT@[143; 144) - NAME@[143; 144) - IDENT@[143; 144) "X" - WHITESPACE@[144; 145) - FAT_ARROW@[145; 147) - WHITESPACE@[147; 148) - TUPLE_EXPR@[148; 150) - L_PAREN@[148; 149) - R_PAREN@[149; 150) - COMMA@[150; 151) - WHITESPACE@[151; 156) - R_CURLY@[156; 157) - SEMI@[157; 158) - WHITESPACE@[158; 159) - R_CURLY@[159; 160) - WHITESPACE@[160; 161) diff --git a/crates/ra_syntax/tests/data/parser/inline/0023_array_type_missing_semi.rs b/crates/ra_syntax/tests/data/parser/inline/err/0001_array_type_missing_semi.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0023_array_type_missing_semi.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0001_array_type_missing_semi.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0023_array_type_missing_semi.txt b/crates/ra_syntax/tests/data/parser/inline/err/0001_array_type_missing_semi.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0023_array_type_missing_semi.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0001_array_type_missing_semi.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0108_misplaced_label_err.rs b/crates/ra_syntax/tests/data/parser/inline/err/0002_misplaced_label_err.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0108_misplaced_label_err.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0002_misplaced_label_err.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0108_misplaced_label_err.txt b/crates/ra_syntax/tests/data/parser/inline/err/0002_misplaced_label_err.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0108_misplaced_label_err.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0002_misplaced_label_err.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0021_pointer_type_no_mutability.rs b/crates/ra_syntax/tests/data/parser/inline/err/0003_pointer_type_no_mutability.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0021_pointer_type_no_mutability.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0003_pointer_type_no_mutability.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0021_pointer_type_no_mutability.txt b/crates/ra_syntax/tests/data/parser/inline/err/0003_pointer_type_no_mutability.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0021_pointer_type_no_mutability.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0003_pointer_type_no_mutability.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0111_impl_type.rs b/crates/ra_syntax/tests/data/parser/inline/err/0004_impl_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0111_impl_type.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0004_impl_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0111_impl_type.txt b/crates/ra_syntax/tests/data/parser/inline/err/0004_impl_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0111_impl_type.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0004_impl_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0029_fn_pointer_type_missing_fn.rs b/crates/ra_syntax/tests/data/parser/inline/err/0005_fn_pointer_type_missing_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0029_fn_pointer_type_missing_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0005_fn_pointer_type_missing_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0029_fn_pointer_type_missing_fn.txt b/crates/ra_syntax/tests/data/parser/inline/err/0005_fn_pointer_type_missing_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0029_fn_pointer_type_missing_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0005_fn_pointer_type_missing_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0013_unsafe_block_in_mod.rs b/crates/ra_syntax/tests/data/parser/inline/err/0006_unsafe_block_in_mod.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0013_unsafe_block_in_mod.rs rename to crates/ra_syntax/tests/data/parser/inline/err/0006_unsafe_block_in_mod.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0013_unsafe_block_in_mod.txt b/crates/ra_syntax/tests/data/parser/inline/err/0006_unsafe_block_in_mod.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0013_unsafe_block_in_mod.txt rename to crates/ra_syntax/tests/data/parser/inline/err/0006_unsafe_block_in_mod.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0049_trait_item_list.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0001_trait_item_list.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0049_trait_item_list.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0001_trait_item_list.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0049_trait_item_list.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0001_trait_item_list.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0049_trait_item_list.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0001_trait_item_list.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0118_use_tree_list.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0002_use_tree_list.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0118_use_tree_list.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0002_use_tree_list.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0118_use_tree_list.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0002_use_tree_list.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0118_use_tree_list.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0002_use_tree_list.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0113_where_pred_for.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0003_where_pred_for.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0113_where_pred_for.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0003_where_pred_for.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0113_where_pred_for.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0003_where_pred_for.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0113_where_pred_for.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0003_where_pred_for.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0096_value_parameters_no_patterns.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0004_value_parameters_no_patterns.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0096_value_parameters_no_patterns.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0004_value_parameters_no_patterns.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0096_value_parameters_no_patterns.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0004_value_parameters_no_patterns.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0096_value_parameters_no_patterns.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0004_value_parameters_no_patterns.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0060_function_type_params.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0005_function_type_params.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0060_function_type_params.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0005_function_type_params.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0060_function_type_params.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0005_function_type_params.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0060_function_type_params.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0005_function_type_params.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0055_self_param.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0006_self_param.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0055_self_param.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0006_self_param.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0055_self_param.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0006_self_param.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0055_self_param.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0006_self_param.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0041_type_param_bounds.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0007_type_param_bounds.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0041_type_param_bounds.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0007_type_param_bounds.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0041_type_param_bounds.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0007_type_param_bounds.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0041_type_param_bounds.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0007_type_param_bounds.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0072_path_part.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0008_path_part.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0072_path_part.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0008_path_part.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0072_path_part.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0008_path_part.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0072_path_part.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0008_path_part.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0084_loop_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0009_loop_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0084_loop_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0009_loop_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0084_loop_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0009_loop_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0084_loop_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0009_loop_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0003_extern_block.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0010_extern_block.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0003_extern_block.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0010_extern_block.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0003_extern_block.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0010_extern_block.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0003_extern_block.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0010_extern_block.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0052_field_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0011_field_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0052_field_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0011_field_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0052_field_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0011_field_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0052_field_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0011_field_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0016_type_item_where_clause.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0012_type_item_where_clause.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0016_type_item_where_clause.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0012_type_item_where_clause.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0016_type_item_where_clause.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0012_type_item_where_clause.txt similarity index 95% rename from crates/ra_syntax/tests/data/parser/inline/0016_type_item_where_clause.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0012_type_item_where_clause.txt index f38b2f79ad..dbb705acf7 100644 --- a/crates/ra_syntax/tests/data/parser/inline/0016_type_item_where_clause.txt +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0012_type_item_where_clause.txt @@ -21,7 +21,6 @@ SOURCE_FILE@[0; 31) PATH_SEGMENT@[20; 24) NAME_REF@[20; 24) IDENT@[20; 24) "Copy" - err: `expected COMMA` WHITESPACE@[24; 25) EQ@[25; 26) WHITESPACE@[26; 27) diff --git a/crates/ra_syntax/tests/data/parser/inline/0022_pointer_type_mut.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0013_pointer_type_mut.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0022_pointer_type_mut.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0013_pointer_type_mut.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0022_pointer_type_mut.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0013_pointer_type_mut.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0022_pointer_type_mut.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0013_pointer_type_mut.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0020_never_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0014_never_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0020_never_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0014_never_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0020_never_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0014_never_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0020_never_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0014_never_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0105_continue_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0015_continue_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0105_continue_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0015_continue_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0105_continue_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0015_continue_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0105_continue_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0015_continue_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0007_unsafe_trait.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0016_unsafe_trait.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0007_unsafe_trait.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0016_unsafe_trait.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0007_unsafe_trait.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0016_unsafe_trait.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0007_unsafe_trait.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0016_unsafe_trait.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0024_array_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0017_array_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0024_array_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0017_array_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0024_array_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0017_array_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0024_array_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0017_array_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0104_arb_self_types.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0018_arb_self_types.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0104_arb_self_types.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0018_arb_self_types.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0104_arb_self_types.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0018_arb_self_types.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0104_arb_self_types.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0018_arb_self_types.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0074_unary_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0019_unary_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0074_unary_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0019_unary_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0074_unary_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0019_unary_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0074_unary_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0019_unary_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0116_use_star.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0020_use_star.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0116_use_star.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0020_use_star.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0116_use_star.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0020_use_star.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0116_use_star.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0020_use_star.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0073_impl_item_list.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0021_impl_item_list.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0073_impl_item_list.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0021_impl_item_list.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0073_impl_item_list.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0021_impl_item_list.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0073_impl_item_list.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0021_impl_item_list.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0037_crate_visibility.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0022_crate_visibility.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0037_crate_visibility.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0022_crate_visibility.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0037_crate_visibility.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0022_crate_visibility.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0037_crate_visibility.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0022_crate_visibility.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0027_placeholder_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0023_placeholder_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0027_placeholder_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0023_placeholder_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0027_placeholder_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0023_placeholder_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0027_placeholder_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0023_placeholder_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0089_slice_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0024_slice_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0089_slice_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0024_slice_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0089_slice_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0024_slice_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0089_slice_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0024_slice_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0025_slice_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0025_slice_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0025_slice_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0025_slice_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0025_slice_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0025_slice_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0025_slice_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0025_slice_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0071_tuple_pat_fields.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0026_tuple_pat_fields.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0071_tuple_pat_fields.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0026_tuple_pat_fields.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0071_tuple_pat_fields.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0026_tuple_pat_fields.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0071_tuple_pat_fields.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0026_tuple_pat_fields.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0035_ref_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0027_ref_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0035_ref_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0027_ref_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0035_ref_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0027_ref_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0035_ref_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0027_ref_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0063_impl_trait_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0028_impl_trait_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0063_impl_trait_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0028_impl_trait_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0063_impl_trait_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0028_impl_trait_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0063_impl_trait_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0028_impl_trait_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0079_cast_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0029_cast_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0079_cast_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0029_cast_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0079_cast_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0029_cast_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0079_cast_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0029_cast_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0076_cond.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0030_cond.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0076_cond.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0030_cond.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0076_cond.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0030_cond.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0076_cond.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0030_cond.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0077_while_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0031_while_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0077_while_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0031_while_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0077_while_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0031_while_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0077_while_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0031_while_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0028_fn_pointer_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0032_fn_pointer_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0028_fn_pointer_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0032_fn_pointer_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0028_fn_pointer_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0032_fn_pointer_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0028_fn_pointer_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0032_fn_pointer_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0026_reference_type;.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0033_reference_type;.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0026_reference_type;.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0033_reference_type;.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0026_reference_type;.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0033_reference_type;.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0026_reference_type;.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0033_reference_type;.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0106_break_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0034_break_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0106_break_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0034_break_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0106_break_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0034_break_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0106_break_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0034_break_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0068_pub_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0035_pub_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0068_pub_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0035_pub_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0068_pub_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0035_pub_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0068_pub_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0035_pub_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0012_unsafe_extern_fn.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0036_unsafe_extern_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0012_unsafe_extern_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0036_unsafe_extern_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0012_unsafe_extern_fn.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0036_unsafe_extern_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0012_unsafe_extern_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0036_unsafe_extern_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0101_qual_paths.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0037_qual_paths.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0101_qual_paths.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0037_qual_paths.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0101_qual_paths.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0037_qual_paths.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0101_qual_paths.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0037_qual_paths.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0102_full_range_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0038_full_range_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0102_full_range_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0038_full_range_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0102_full_range_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0038_full_range_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0102_full_range_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0038_full_range_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.rs new file mode 100644 index 0000000000..385c431316 --- /dev/null +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.rs @@ -0,0 +1 @@ +type A = B<'static, i32, Item=u64>; diff --git a/crates/ra_syntax/tests/data/parser/inline/0058_type_arg.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.txt similarity index 91% rename from crates/ra_syntax/tests/data/parser/inline/0058_type_arg.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.txt index 086a74bdbf..ccef7188f1 100644 --- a/crates/ra_syntax/tests/data/parser/inline/0058_type_arg.txt +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0039_type_arg.txt @@ -1,5 +1,5 @@ -SOURCE_FILE@[0; 35) - TYPE_DEF@[0; 34) +SOURCE_FILE@[0; 36) + TYPE_DEF@[0; 35) TYPE_KW@[0; 4) WHITESPACE@[4; 5) NAME@[5; 6) @@ -36,5 +36,5 @@ SOURCE_FILE@[0; 35) NAME_REF@[30; 33) IDENT@[30; 33) "u64" R_ANGLE@[33; 34) - err: `expected SEMI` - WHITESPACE@[34; 35) + SEMI@[34; 35) + WHITESPACE@[35; 36) diff --git a/crates/ra_syntax/tests/data/parser/inline/0099_crate_keyword_vis.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0040_crate_keyword_vis.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0099_crate_keyword_vis.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0040_crate_keyword_vis.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0099_crate_keyword_vis.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0040_crate_keyword_vis.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0099_crate_keyword_vis.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0040_crate_keyword_vis.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0056_trait_item.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0041_trait_item.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0056_trait_item.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0041_trait_item.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0056_trait_item.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0041_trait_item.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0056_trait_item.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0041_trait_item.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0043_call_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0042_call_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0043_call_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0042_call_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0043_call_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0042_call_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0043_call_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0042_call_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0115_use_alias.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.rs similarity index 73% rename from crates/ra_syntax/tests/data/parser/inline/0115_use_alias.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.rs index c7a141bbd3..544caa0204 100644 --- a/crates/ra_syntax/tests/data/parser/inline/0115_use_alias.rs +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.rs @@ -3,5 +3,5 @@ use some::{ other::path as some_other_name, different::path as different_name, yet::another::path, - running::out::of::synonyms::for::different::* + running::out::of::synonyms::for_::different::* }; diff --git a/crates/ra_syntax/tests/data/parser/inline/0115_use_alias.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.txt similarity index 83% rename from crates/ra_syntax/tests/data/parser/inline/0115_use_alias.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.txt index f7b599476f..8ef0ecbc65 100644 --- a/crates/ra_syntax/tests/data/parser/inline/0115_use_alias.txt +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0043_use_alias.txt @@ -1,4 +1,4 @@ -SOURCE_FILE@[0; 181) +SOURCE_FILE@[0; 182) USE_ITEM@[0; 28) USE_KW@[0; 3) WHITESPACE@[3; 4) @@ -20,16 +20,16 @@ SOURCE_FILE@[0; 181) IDENT@[18; 27) "some_name" SEMI@[27; 28) WHITESPACE@[28; 29) - USE_ITEM@[29; 180) + USE_ITEM@[29; 181) USE_KW@[29; 32) WHITESPACE@[32; 33) - USE_TREE@[33; 179) + USE_TREE@[33; 180) PATH@[33; 37) PATH_SEGMENT@[33; 37) NAME_REF@[33; 37) IDENT@[33; 37) "some" COLONCOLON@[37; 39) - USE_TREE_LIST@[39; 179) + USE_TREE_LIST@[39; 180) L_CURLY@[39; 40) WHITESPACE@[40; 42) USE_TREE@[42; 72) @@ -85,9 +85,9 @@ SOURCE_FILE@[0; 181) IDENT@[125; 129) "path" COMMA@[129; 130) WHITESPACE@[130; 132) - USE_TREE@[132; 177) - PATH@[132; 174) - PATH@[132; 163) + USE_TREE@[132; 178) + PATH@[132; 175) + PATH@[132; 164) PATH@[132; 158) PATH@[132; 148) PATH@[132; 144) @@ -108,17 +108,16 @@ SOURCE_FILE@[0; 181) NAME_REF@[150; 158) IDENT@[150; 158) "synonyms" COLONCOLON@[158; 160) - err: `expected identifier` - PATH_SEGMENT@[160; 163) - ERROR@[160; 163) - FOR_KW@[160; 163) - COLONCOLON@[163; 165) - PATH_SEGMENT@[165; 174) - NAME_REF@[165; 174) - IDENT@[165; 174) "different" - COLONCOLON@[174; 176) - STAR@[176; 177) - WHITESPACE@[177; 178) - R_CURLY@[178; 179) - SEMI@[179; 180) - WHITESPACE@[180; 181) + PATH_SEGMENT@[160; 164) + NAME_REF@[160; 164) + IDENT@[160; 164) "for_" + COLONCOLON@[164; 166) + PATH_SEGMENT@[166; 175) + NAME_REF@[166; 175) + IDENT@[166; 175) "different" + COLONCOLON@[175; 177) + STAR@[177; 178) + WHITESPACE@[178; 179) + R_CURLY@[179; 180) + SEMI@[180; 181) + WHITESPACE@[181; 182) diff --git a/crates/ra_syntax/tests/data/parser/inline/0053_block_items.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0044_block_items.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0053_block_items.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0044_block_items.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0053_block_items.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0044_block_items.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0053_block_items.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0044_block_items.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0097_param_list_opt_patterns.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0045_param_list_opt_patterns.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0097_param_list_opt_patterns.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0045_param_list_opt_patterns.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0097_param_list_opt_patterns.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0045_param_list_opt_patterns.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0097_param_list_opt_patterns.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0045_param_list_opt_patterns.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0019_singleton_tuple_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0046_singleton_tuple_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0019_singleton_tuple_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0046_singleton_tuple_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0019_singleton_tuple_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0046_singleton_tuple_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0019_singleton_tuple_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0046_singleton_tuple_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0010_unsafe_default_impl.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0047_unsafe_default_impl.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0010_unsafe_default_impl.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0047_unsafe_default_impl.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0010_unsafe_default_impl.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0047_unsafe_default_impl.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0010_unsafe_default_impl.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0047_unsafe_default_impl.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0095_path_type_with_bounds.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0048_path_type_with_bounds.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0095_path_type_with_bounds.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0048_path_type_with_bounds.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0095_path_type_with_bounds.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0048_path_type_with_bounds.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0095_path_type_with_bounds.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0048_path_type_with_bounds.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0050_let_stmt;.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0049_let_stmt;.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0050_let_stmt;.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0049_let_stmt;.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0050_let_stmt;.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0049_let_stmt;.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0050_let_stmt;.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0049_let_stmt;.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0091_fn_decl.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0050_fn_decl.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0091_fn_decl.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0050_fn_decl.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0091_fn_decl.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0050_fn_decl.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0091_fn_decl.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0050_fn_decl.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0018_unit_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0051_unit_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0018_unit_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0051_unit_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0018_unit_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0051_unit_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0018_unit_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0051_unit_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0032_path_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0052_path_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0032_path_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0052_path_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0032_path_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0052_path_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0032_path_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0052_path_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0039_path_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0053_path_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0039_path_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0053_path_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0039_path_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0053_path_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0039_path_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0053_path_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0103_field_attrs.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0054_field_attrs.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0103_field_attrs.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0054_field_attrs.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0103_field_attrs.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0054_field_attrs.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0103_field_attrs.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0054_field_attrs.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0092_literal_pattern.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0055_literal_pattern.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0092_literal_pattern.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0055_literal_pattern.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0092_literal_pattern.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0055_literal_pattern.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0092_literal_pattern.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0055_literal_pattern.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0098_where_clause.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0056_where_clause.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0098_where_clause.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0056_where_clause.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0098_where_clause.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0056_where_clause.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0098_where_clause.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0056_where_clause.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0002_const_fn.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0057_const_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0002_const_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0057_const_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0002_const_fn.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0057_const_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0002_const_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0057_const_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0094_range_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0058_range_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0094_range_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0058_range_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0094_range_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0058_range_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0094_range_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0058_range_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0085_match_arms_commas.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0059_match_arms_commas.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0085_match_arms_commas.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0059_match_arms_commas.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0085_match_arms_commas.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0059_match_arms_commas.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0085_match_arms_commas.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0059_match_arms_commas.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0005_extern_crate.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0060_extern_crate.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0005_extern_crate.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0060_extern_crate.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0005_extern_crate.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0060_extern_crate.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0005_extern_crate.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0060_extern_crate.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0061_struct_lit.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0061_struct_lit.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0061_struct_lit.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0061_struct_lit.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0061_struct_lit.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0061_struct_lit.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0061_struct_lit.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0061_struct_lit.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0078_mod_contents.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0062_mod_contents.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0078_mod_contents.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0062_mod_contents.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0078_mod_contents.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0062_mod_contents.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0078_mod_contents.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0062_mod_contents.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0048_impl_item_neg.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0063_impl_item_neg.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0048_impl_item_neg.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0063_impl_item_neg.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0048_impl_item_neg.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0063_impl_item_neg.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0048_impl_item_neg.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0063_impl_item_neg.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0065_if_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0064_if_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0065_if_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0064_if_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0065_if_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0064_if_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0065_if_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0064_if_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0100_dyn_trait_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0065_dyn_trait_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0100_dyn_trait_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0065_dyn_trait_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0100_dyn_trait_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0065_dyn_trait_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0100_dyn_trait_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0065_dyn_trait_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0069_match_arm.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.rs similarity index 74% rename from crates/ra_syntax/tests/data/parser/inline/0069_match_arm.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.rs index 3380fa4ca1..9e009e24f4 100644 --- a/crates/ra_syntax/tests/data/parser/inline/0069_match_arm.rs +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.rs @@ -1,7 +1,7 @@ fn foo() { match () { _ => (), - _ if Test>{field: 0} => (), + _ if Test > Test{field: 0} => (), X | Y if Z => (), | X | Y if Z => (), | X => (), diff --git a/crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.txt new file mode 100644 index 0000000000..98e7535a34 --- /dev/null +++ b/crates/ra_syntax/tests/data/parser/inline/ok/0066_match_arm.txt @@ -0,0 +1,146 @@ +SOURCE_FILE@[0; 167) + FN_DEF@[0; 166) + FN_KW@[0; 2) + WHITESPACE@[2; 3) + NAME@[3; 6) + IDENT@[3; 6) "foo" + PARAM_LIST@[6; 8) + L_PAREN@[6; 7) + R_PAREN@[7; 8) + WHITESPACE@[8; 9) + BLOCK@[9; 166) + L_CURLY@[9; 10) + WHITESPACE@[10; 15) + EXPR_STMT@[15; 164) + MATCH_EXPR@[15; 163) + MATCH_KW@[15; 20) + WHITESPACE@[20; 21) + TUPLE_EXPR@[21; 23) + L_PAREN@[21; 22) + R_PAREN@[22; 23) + WHITESPACE@[23; 24) + MATCH_ARM_LIST@[24; 163) + L_CURLY@[24; 25) + WHITESPACE@[25; 34) + MATCH_ARM@[34; 41) + PLACEHOLDER_PAT@[34; 35) + UNDERSCORE@[34; 35) + WHITESPACE@[35; 36) + FAT_ARROW@[36; 38) + WHITESPACE@[38; 39) + TUPLE_EXPR@[39; 41) + L_PAREN@[39; 40) + R_PAREN@[40; 41) + COMMA@[41; 42) + WHITESPACE@[42; 51) + MATCH_ARM@[51; 83) + PLACEHOLDER_PAT@[51; 52) + UNDERSCORE@[51; 52) + WHITESPACE@[52; 53) + IF_KW@[53; 55) + WHITESPACE@[55; 56) + BIN_EXPR@[56; 77) + PATH_EXPR@[56; 60) + PATH@[56; 60) + PATH_SEGMENT@[56; 60) + NAME_REF@[56; 60) + IDENT@[56; 60) "Test" + WHITESPACE@[60; 61) + R_ANGLE@[61; 62) + WHITESPACE@[62; 63) + STRUCT_LIT@[63; 77) + PATH@[63; 67) + PATH_SEGMENT@[63; 67) + NAME_REF@[63; 67) + IDENT@[63; 67) "Test" + NAMED_FIELD_LIST@[67; 77) + L_CURLY@[67; 68) + NAMED_FIELD@[68; 76) + NAME_REF@[68; 73) + IDENT@[68; 73) "field" + COLON@[73; 74) + WHITESPACE@[74; 75) + LITERAL@[75; 76) + INT_NUMBER@[75; 76) "0" + R_CURLY@[76; 77) + WHITESPACE@[77; 78) + FAT_ARROW@[78; 80) + WHITESPACE@[80; 81) + TUPLE_EXPR@[81; 83) + L_PAREN@[81; 82) + R_PAREN@[82; 83) + COMMA@[83; 84) + WHITESPACE@[84; 93) + MATCH_ARM@[93; 109) + BIND_PAT@[93; 94) + NAME@[93; 94) + IDENT@[93; 94) "X" + WHITESPACE@[94; 95) + PIPE@[95; 96) + WHITESPACE@[96; 97) + BIND_PAT@[97; 98) + NAME@[97; 98) + IDENT@[97; 98) "Y" + WHITESPACE@[98; 99) + IF_KW@[99; 101) + WHITESPACE@[101; 102) + PATH_EXPR@[102; 103) + PATH@[102; 103) + PATH_SEGMENT@[102; 103) + NAME_REF@[102; 103) + IDENT@[102; 103) "Z" + WHITESPACE@[103; 104) + FAT_ARROW@[104; 106) + WHITESPACE@[106; 107) + TUPLE_EXPR@[107; 109) + L_PAREN@[107; 108) + R_PAREN@[108; 109) + COMMA@[109; 110) + WHITESPACE@[110; 119) + MATCH_ARM@[119; 137) + PIPE@[119; 120) + WHITESPACE@[120; 121) + BIND_PAT@[121; 122) + NAME@[121; 122) + IDENT@[121; 122) "X" + WHITESPACE@[122; 123) + PIPE@[123; 124) + WHITESPACE@[124; 125) + BIND_PAT@[125; 126) + NAME@[125; 126) + IDENT@[125; 126) "Y" + WHITESPACE@[126; 127) + IF_KW@[127; 129) + WHITESPACE@[129; 130) + PATH_EXPR@[130; 131) + PATH@[130; 131) + PATH_SEGMENT@[130; 131) + NAME_REF@[130; 131) + IDENT@[130; 131) "Z" + WHITESPACE@[131; 132) + FAT_ARROW@[132; 134) + WHITESPACE@[134; 135) + TUPLE_EXPR@[135; 137) + L_PAREN@[135; 136) + R_PAREN@[136; 137) + COMMA@[137; 138) + WHITESPACE@[138; 147) + MATCH_ARM@[147; 156) + PIPE@[147; 148) + WHITESPACE@[148; 149) + BIND_PAT@[149; 150) + NAME@[149; 150) + IDENT@[149; 150) "X" + WHITESPACE@[150; 151) + FAT_ARROW@[151; 153) + WHITESPACE@[153; 154) + TUPLE_EXPR@[154; 156) + L_PAREN@[154; 155) + R_PAREN@[155; 156) + COMMA@[156; 157) + WHITESPACE@[157; 162) + R_CURLY@[162; 163) + SEMI@[163; 164) + WHITESPACE@[164; 165) + R_CURLY@[165; 166) + WHITESPACE@[166; 167) diff --git a/crates/ra_syntax/tests/data/parser/inline/0112_crate_path.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0067_crate_path.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0112_crate_path.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0067_crate_path.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0112_crate_path.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0067_crate_path.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0112_crate_path.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0067_crate_path.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0110_union_items.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0068_union_items.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0110_union_items.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0068_union_items.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0110_union_items.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0068_union_items.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0110_union_items.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0068_union_items.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0117_use_tree_list_after_path.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0069_use_tree_list_after_path.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0117_use_tree_list_after_path.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0069_use_tree_list_after_path.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0117_use_tree_list_after_path.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0069_use_tree_list_after_path.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0117_use_tree_list_after_path.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0069_use_tree_list_after_path.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0088_stmt_bin_expr_ambiguity.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0088_stmt_bin_expr_ambiguity.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0088_stmt_bin_expr_ambiguity.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0088_stmt_bin_expr_ambiguity.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0070_match_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0071_match_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0070_match_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0071_match_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0070_match_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0071_match_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0070_match_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0071_match_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0068_return_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0072_return_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0068_return_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0072_return_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0068_return_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0072_return_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0068_return_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0072_return_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0014_type_item_type_params.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0073_type_item_type_params.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0014_type_item_type_params.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0073_type_item_type_params.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0014_type_item_type_params.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0073_type_item_type_params.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0014_type_item_type_params.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0073_type_item_type_params.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0087_stmt_postfix_expr_ambiguity.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0087_stmt_postfix_expr_ambiguity.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0087_stmt_postfix_expr_ambiguity.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0087_stmt_postfix_expr_ambiguity.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0045_block.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0075_block.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0045_block.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0075_block.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0045_block.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0075_block.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0045_block.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0075_block.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0059_function_where_clause.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0076_function_where_clause.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0059_function_where_clause.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0076_function_where_clause.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0059_function_where_clause.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0076_function_where_clause.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0059_function_where_clause.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0076_function_where_clause.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0075_try_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0077_try_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0075_try_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0077_try_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0075_try_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0077_try_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0075_try_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0077_try_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0015_type_item.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0078_type_item.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0015_type_item.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0078_type_item.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0015_type_item.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0078_type_item.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0015_type_item.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0078_type_item.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0047_impl_item.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0079_impl_item.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0047_impl_item.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0079_impl_item.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0047_impl_item.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0079_impl_item.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0047_impl_item.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0079_impl_item.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0083_postfix_range.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0080_postfix_range.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0083_postfix_range.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0080_postfix_range.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0083_postfix_range.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0080_postfix_range.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0083_postfix_range.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0080_postfix_range.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0031_for_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0081_for_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0031_for_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0081_for_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0031_for_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0081_for_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0031_for_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0081_for_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0044_ref_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0082_ref_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0044_ref_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0082_ref_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0044_ref_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0082_ref_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0044_ref_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0082_ref_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0109_struct_items.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0083_struct_items.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0109_struct_items.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0083_struct_items.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0109_struct_items.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0083_struct_items.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0109_struct_items.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0083_struct_items.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0017_paren_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0084_paren_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0017_paren_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0084_paren_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0017_paren_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0084_paren_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0017_paren_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0084_paren_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0040_expr_literals.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0085_expr_literals.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0040_expr_literals.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0085_expr_literals.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0040_expr_literals.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0085_expr_literals.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0040_expr_literals.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0085_expr_literals.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0038_function_ret_type.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0086_function_ret_type.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0038_function_ret_type.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0086_function_ret_type.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0038_function_ret_type.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0086_function_ret_type.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0038_function_ret_type.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0086_function_ret_type.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0008_unsafe_impl.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0087_unsafe_impl.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0008_unsafe_impl.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0087_unsafe_impl.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0008_unsafe_impl.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0087_unsafe_impl.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0008_unsafe_impl.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0087_unsafe_impl.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0119_break_ambiguity.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0088_break_ambiguity.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0119_break_ambiguity.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0088_break_ambiguity.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0119_break_ambiguity.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0088_break_ambiguity.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0119_break_ambiguity.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0088_break_ambiguity.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0004_extern_fn.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0089_extern_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0004_extern_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0089_extern_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0004_extern_fn.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0089_extern_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0004_extern_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0089_extern_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0042_type_param_default.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0090_type_param_default.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0042_type_param_default.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0090_type_param_default.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0042_type_param_default.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0090_type_param_default.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0042_type_param_default.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0090_type_param_default.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0057_auto_trait.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0091_auto_trait.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0057_auto_trait.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0091_auto_trait.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0057_auto_trait.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0091_auto_trait.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0057_auto_trait.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0091_auto_trait.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0030_fn_pointer_type_with_ret.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0030_fn_pointer_type_with_ret.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0030_fn_pointer_type_with_ret.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0092_fn_pointer_type_with_ret.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0030_fn_pointer_type_with_ret.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0092_fn_pointer_type_with_ret.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0081_index_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0093_index_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0081_index_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0093_index_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0081_index_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0093_index_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0081_index_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0093_index_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0009_unsafe_auto_trait.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0094_unsafe_auto_trait.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0009_unsafe_auto_trait.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0094_unsafe_auto_trait.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0009_unsafe_auto_trait.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0094_unsafe_auto_trait.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0009_unsafe_auto_trait.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0094_unsafe_auto_trait.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0036_placeholder_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0095_placeholder_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0036_placeholder_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0095_placeholder_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0036_placeholder_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0095_placeholder_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0036_placeholder_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0095_placeholder_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0086_no_semi_after_block.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0096_no_semi_after_block.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0086_no_semi_after_block.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0096_no_semi_after_block.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0086_no_semi_after_block.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0096_no_semi_after_block.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0086_no_semi_after_block.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0096_no_semi_after_block.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0046_default_impl.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0097_default_impl.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0046_default_impl.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0097_default_impl.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0046_default_impl.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0097_default_impl.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0046_default_impl.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0097_default_impl.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0001_const_unsafe_fn.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0098_const_unsafe_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0001_const_unsafe_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0098_const_unsafe_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0001_const_unsafe_fn.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0098_const_unsafe_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0001_const_unsafe_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0098_const_unsafe_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0064_param_list.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0099_param_list.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0064_param_list.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0099_param_list.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0064_param_list.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0099_param_list.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0064_param_list.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0099_param_list.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0085_for_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0100_for_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0085_for_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0100_for_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0085_for_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0100_for_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0085_for_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0100_for_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0011_unsafe_fn.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0101_unsafe_fn.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0011_unsafe_fn.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0101_unsafe_fn.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0011_unsafe_fn.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0101_unsafe_fn.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0011_unsafe_fn.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0101_unsafe_fn.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0054_field_pat_list.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0102_field_pat_list.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0054_field_pat_list.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0102_field_pat_list.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0054_field_pat_list.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0102_field_pat_list.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0054_field_pat_list.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0102_field_pat_list.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0086_array_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0103_array_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0086_array_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0103_array_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0086_array_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0103_array_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0086_array_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0103_array_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0093_path_fn_trait_args.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0104_path_fn_trait_args.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0093_path_fn_trait_args.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0104_path_fn_trait_args.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0093_path_fn_trait_args.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0104_path_fn_trait_args.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0093_path_fn_trait_args.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0104_path_fn_trait_args.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0067_block_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0105_block_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0067_block_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0105_block_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0067_block_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0105_block_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0067_block_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0105_block_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0066_lambda_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0106_lambda_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0066_lambda_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0106_lambda_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0066_lambda_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0106_lambda_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0066_lambda_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0106_lambda_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0051_method_call_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0107_method_call_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0051_method_call_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0107_method_call_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0051_method_call_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0107_method_call_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0051_method_call_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0107_method_call_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0080_tuple_expr.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0108_tuple_expr.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0080_tuple_expr.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0108_tuple_expr.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0080_tuple_expr.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0108_tuple_expr.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0080_tuple_expr.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0108_tuple_expr.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0107_label.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0109_label.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0107_label.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0109_label.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0107_label.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0109_label.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0107_label.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0109_label.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0114_use_path.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0110_use_path.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0114_use_path.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0110_use_path.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0114_use_path.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0110_use_path.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0114_use_path.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0110_use_path.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0082_tuple_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0111_tuple_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0082_tuple_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0111_tuple_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0082_tuple_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0111_tuple_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0082_tuple_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0111_tuple_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/inline/0034_bind_pat.rs b/crates/ra_syntax/tests/data/parser/inline/ok/0112_bind_pat.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0034_bind_pat.rs rename to crates/ra_syntax/tests/data/parser/inline/ok/0112_bind_pat.rs diff --git a/crates/ra_syntax/tests/data/parser/inline/0034_bind_pat.txt b/crates/ra_syntax/tests/data/parser/inline/ok/0112_bind_pat.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/inline/0034_bind_pat.txt rename to crates/ra_syntax/tests/data/parser/inline/ok/0112_bind_pat.txt diff --git a/crates/ra_syntax/tests/data/parser/ok/0029_range_forms.txt b/crates/ra_syntax/tests/data/parser/ok/0029_range_forms.txt index e3706bfbd0..e59542ba12 100644 --- a/crates/ra_syntax/tests/data/parser/ok/0029_range_forms.txt +++ b/crates/ra_syntax/tests/data/parser/ok/0029_range_forms.txt @@ -79,34 +79,28 @@ SOURCE_FILE@[0; 153) DOTDOT@[73; 75) SEMI@[75; 76) WHITESPACE@[76; 86) - err: `expected expression` - EXPR_STMT@[86; 89) - ERROR@[86; 89) + EXPR_STMT@[86; 95) + RANGE_EXPR@[86; 94) DOTDOTEQ@[86; 89) - err: `expected SEMI` - EXPR_STMT@[89; 95) - BIN_EXPR@[89; 94) - LITERAL@[89; 90) - INT_NUMBER@[89; 90) "1" - WHITESPACE@[90; 91) - PLUS@[91; 92) - WHITESPACE@[92; 93) - LITERAL@[93; 94) - INT_NUMBER@[93; 94) "1" + BIN_EXPR@[89; 94) + LITERAL@[89; 90) + INT_NUMBER@[89; 90) "1" + WHITESPACE@[90; 91) + PLUS@[91; 92) + WHITESPACE@[92; 93) + LITERAL@[93; 94) + INT_NUMBER@[93; 94) "1" SEMI@[94; 95) WHITESPACE@[95; 100) - err: `expected expression` - EXPR_STMT@[100; 103) - ERROR@[100; 103) - DOTDOTEQ@[100; 103) - err: `expected SEMI` - EXPR_STMT@[103; 109) - BIN_EXPR@[103; 108) - PATH_EXPR@[103; 104) - PATH@[103; 104) - PATH_SEGMENT@[103; 104) - NAME_REF@[103; 104) - IDENT@[103; 104) "z" + EXPR_STMT@[100; 109) + BIN_EXPR@[100; 108) + RANGE_EXPR@[100; 104) + DOTDOTEQ@[100; 103) + PATH_EXPR@[103; 104) + PATH@[103; 104) + PATH_SEGMENT@[103; 104) + NAME_REF@[103; 104) + IDENT@[103; 104) "z" WHITESPACE@[104; 105) EQ@[105; 106) WHITESPACE@[106; 107) diff --git a/crates/ra_syntax/tests/data/parser/ok/0035_crate_path_in_call.rs b/crates/ra_syntax/tests/data/parser/ok/0034_crate_path_in_call.rs similarity index 100% rename from crates/ra_syntax/tests/data/parser/ok/0035_crate_path_in_call.rs rename to crates/ra_syntax/tests/data/parser/ok/0034_crate_path_in_call.rs diff --git a/crates/ra_syntax/tests/data/parser/ok/0035_crate_path_in_call.txt b/crates/ra_syntax/tests/data/parser/ok/0034_crate_path_in_call.txt similarity index 100% rename from crates/ra_syntax/tests/data/parser/ok/0035_crate_path_in_call.txt rename to crates/ra_syntax/tests/data/parser/ok/0034_crate_path_in_call.txt diff --git a/crates/ra_syntax/tests/data/parser/ok/0034_macro_stuck.txt b/crates/ra_syntax/tests/data/parser/ok/0034_macro_stuck.txt deleted file mode 100644 index cf9a1a2fac..0000000000 --- a/crates/ra_syntax/tests/data/parser/ok/0034_macro_stuck.txt +++ /dev/null @@ -1,250 +0,0 @@ -SOURCE_FILE@[0; 350) - MACRO_CALL@[0; 41) - PATH@[0; 5) - PATH_SEGMENT@[0; 5) - NAME_REF@[0; 5) - IDENT@[0; 5) "macro" - err: `expected EXCL` - WHITESPACE@[5; 6) - IDENT@[6; 21) "parse_use_trees" - TOKEN_TREE@[21; 41) - L_PAREN@[21; 22) - DOLLAR@[22; 23) - TOKEN_TREE@[23; 32) - L_PAREN@[23; 24) - DOLLAR@[24; 25) - IDENT@[25; 26) "s" - COLON@[26; 27) - IDENT@[27; 31) "expr" - R_PAREN@[31; 32) - COMMA@[32; 33) - STAR@[33; 34) - WHITESPACE@[34; 35) - DOLLAR@[35; 36) - TOKEN_TREE@[36; 39) - L_PAREN@[36; 37) - COMMA@[37; 38) - R_PAREN@[38; 39) - STAR@[39; 40) - R_PAREN@[40; 41) - err: `expected SEMI` - WHITESPACE@[41; 42) - err: `expected an item` - ERROR@[42; 93) - L_CURLY@[42; 43) - WHITESPACE@[43; 48) - IDENT@[48; 51) "vec" - EXCL@[51; 52) - L_BRACK@[52; 53) - WHITESPACE@[53; 62) - DOLLAR@[62; 63) - L_PAREN@[63; 64) - IDENT@[64; 78) "parse_use_tree" - L_PAREN@[78; 79) - DOLLAR@[79; 80) - IDENT@[80; 81) "s" - R_PAREN@[81; 82) - COMMA@[82; 83) - R_PAREN@[83; 84) - STAR@[84; 85) - WHITESPACE@[85; 90) - R_BRACK@[90; 91) - WHITESPACE@[91; 92) - R_CURLY@[92; 93) - WHITESPACE@[93; 95) - FN_DEF@[95; 348) - ATTR@[95; 102) - POUND@[95; 96) - TOKEN_TREE@[96; 102) - L_BRACK@[96; 97) - IDENT@[97; 101) "test" - R_BRACK@[101; 102) - WHITESPACE@[102; 103) - FN_KW@[103; 105) - WHITESPACE@[105; 106) - NAME@[106; 125) - IDENT@[106; 125) "test_use_tree_merge" - PARAM_LIST@[125; 127) - L_PAREN@[125; 126) - R_PAREN@[126; 127) - WHITESPACE@[127; 128) - BLOCK@[128; 348) - L_CURLY@[128; 129) - WHITESPACE@[129; 134) - EXPR_STMT@[134; 139) - PATH_EXPR@[134; 139) - PATH@[134; 139) - PATH_SEGMENT@[134; 139) - NAME_REF@[134; 139) - IDENT@[134; 139) "macro" - err: `expected SEMI` - WHITESPACE@[139; 140) - EXPR_STMT@[140; 203) - CALL_EXPR@[140; 203) - PATH_EXPR@[140; 150) - PATH@[140; 150) - PATH_SEGMENT@[140; 150) - NAME_REF@[140; 150) - IDENT@[140; 150) "test_merge" - ARG_LIST@[150; 203) - L_PAREN@[150; 151) - ARRAY_EXPR@[151; 202) - L_BRACK@[151; 152) - err: `expected expression` - ERROR@[152; 153) - DOLLAR@[152; 153) - err: `expected COMMA` - TUPLE_EXPR@[153; 166) - L_PAREN@[153; 154) - err: `expected expression` - ERROR@[154; 155) - DOLLAR@[154; 155) - err: `expected COMMA` - PATH_EXPR@[155; 160) - PATH@[155; 160) - PATH_SEGMENT@[155; 160) - NAME_REF@[155; 160) - IDENT@[155; 160) "input" - err: `expected COMMA` - err: `expected expression` - ERROR@[160; 161) - COLON@[160; 161) - err: `expected COMMA` - PATH_EXPR@[161; 165) - PATH@[161; 165) - PATH_SEGMENT@[161; 165) - NAME_REF@[161; 165) - IDENT@[161; 165) "expr" - R_PAREN@[165; 166) - COMMA@[166; 167) - PREFIX_EXPR@[167; 170) - STAR@[167; 168) - WHITESPACE@[168; 169) - err: `expected expression` - ERROR@[169; 170) - DOLLAR@[169; 170) - err: `expected COMMA` - BIN_EXPR@[170; 175) - PAREN_EXPR@[170; 173) - L_PAREN@[170; 171) - err: `expected expression` - ERROR@[171; 172) - COMMA@[171; 172) - R_PAREN@[172; 173) - STAR@[173; 174) - err: `expected expression` - ERROR@[174; 175) - R_BRACK@[174; 175) - COMMA@[175; 176) - WHITESPACE@[176; 177) - ARRAY_EXPR@[177; 202) - L_BRACK@[177; 178) - err: `expected expression` - ERROR@[178; 179) - DOLLAR@[178; 179) - err: `expected COMMA` - TUPLE_EXPR@[179; 193) - L_PAREN@[179; 180) - err: `expected expression` - ERROR@[180; 181) - DOLLAR@[180; 181) - err: `expected COMMA` - PATH_EXPR@[181; 187) - PATH@[181; 187) - PATH_SEGMENT@[181; 187) - NAME_REF@[181; 187) - IDENT@[181; 187) "output" - err: `expected COMMA` - err: `expected expression` - ERROR@[187; 188) - COLON@[187; 188) - err: `expected COMMA` - PATH_EXPR@[188; 192) - PATH@[188; 192) - PATH_SEGMENT@[188; 192) - NAME_REF@[188; 192) - IDENT@[188; 192) "expr" - R_PAREN@[192; 193) - COMMA@[193; 194) - PREFIX_EXPR@[194; 197) - STAR@[194; 195) - WHITESPACE@[195; 196) - err: `expected expression` - ERROR@[196; 197) - DOLLAR@[196; 197) - err: `expected COMMA` - BIN_EXPR@[197; 202) - PAREN_EXPR@[197; 200) - L_PAREN@[197; 198) - err: `expected expression` - ERROR@[198; 199) - COMMA@[198; 199) - R_PAREN@[199; 200) - STAR@[200; 201) - err: `expected expression` - ERROR@[201; 202) - R_BRACK@[201; 202) - err: `expected COMMA` - err: `expected expression` - err: `expected R_BRACK` - err: `expected COMMA` - err: `expected expression` - err: `expected R_BRACK` - R_PAREN@[202; 203) - err: `expected SEMI` - WHITESPACE@[203; 204) - BLOCK_EXPR@[204; 346) - BLOCK@[204; 346) - L_CURLY@[204; 205) - WHITESPACE@[205; 214) - EXPR_STMT@[214; 340) - MACRO_CALL@[214; 339) - PATH@[214; 223) - PATH_SEGMENT@[214; 223) - NAME_REF@[214; 223) - IDENT@[214; 223) "assert_eq" - EXCL@[223; 224) - TOKEN_TREE@[224; 339) - L_PAREN@[224; 225) - WHITESPACE@[225; 238) - IDENT@[238; 253) "merge_use_trees" - TOKEN_TREE@[253; 284) - L_PAREN@[253; 254) - IDENT@[254; 269) "parse_use_trees" - EXCL@[269; 270) - TOKEN_TREE@[270; 283) - L_PAREN@[270; 271) - DOLLAR@[271; 272) - TOKEN_TREE@[272; 281) - L_PAREN@[272; 273) - DOLLAR@[273; 274) - IDENT@[274; 279) "input" - COMMA@[279; 280) - R_PAREN@[280; 281) - STAR@[281; 282) - R_PAREN@[282; 283) - R_PAREN@[283; 284) - COMMA@[284; 285) - WHITESPACE@[285; 298) - IDENT@[298; 313) "parse_use_trees" - EXCL@[313; 314) - TOKEN_TREE@[314; 328) - L_PAREN@[314; 315) - DOLLAR@[315; 316) - TOKEN_TREE@[316; 326) - L_PAREN@[316; 317) - DOLLAR@[317; 318) - IDENT@[318; 324) "output" - COMMA@[324; 325) - R_PAREN@[325; 326) - STAR@[326; 327) - R_PAREN@[327; 328) - COMMA@[328; 329) - WHITESPACE@[329; 338) - R_PAREN@[338; 339) - SEMI@[339; 340) - WHITESPACE@[340; 345) - R_CURLY@[345; 346) - WHITESPACE@[346; 347) - R_CURLY@[347; 348) - WHITESPACE@[348; 350) diff --git a/crates/ra_syntax/tests/test.rs b/crates/ra_syntax/tests/test.rs index 15f70c0903..14ad836b52 100644 --- a/crates/ra_syntax/tests/test.rs +++ b/crates/ra_syntax/tests/test.rs @@ -124,7 +124,7 @@ where println!("\nfile: {}", path.display()); println!("No .txt file with expected result, creating...\n"); println!("{}\n{}", input_code, parse_tree); - fs::write(&path, parse_tree).unwrap(); + fs::write(&path, &parse_tree).unwrap(); panic!("No expected result") } let expected = read_text(&path); diff --git a/crates/tools/src/bin/pre-commit.rs b/crates/tools/src/bin/pre-commit.rs index ca19094795..bae3b26d3b 100644 --- a/crates/tools/src/bin/pre-commit.rs +++ b/crates/tools/src/bin/pre-commit.rs @@ -14,13 +14,14 @@ fn update_staged() -> Result<()> { let root = project_root(); let output = Command::new("git") .arg("diff") + .arg("--diff-filter=MAR") .arg("--name-only") .arg("--cached") .current_dir(&root) .output()?; if !output.status.success() { bail!( - "`git diff --name-only --cached` exited with {}", + "`git diff --diff-filter=MAR --name-only --cached` exited with {}", output.status ); } diff --git a/crates/tools/src/lib.rs b/crates/tools/src/lib.rs index 6d4ac4726b..580d8b8021 100644 --- a/crates/tools/src/lib.rs +++ b/crates/tools/src/lib.rs @@ -47,7 +47,7 @@ pub fn collect_tests(s: &str) -> Vec<(usize, Test)> { } Some((idx, line)) if line.starts_with("test_err ") => { ok = false; - break (idx, line["test_fail ".len()..].to_string()); + break (idx, line["test_err ".len()..].to_string()); } Some(_) => (), None => continue 'outer, diff --git a/crates/tools/src/main.rs b/crates/tools/src/main.rs index 08b21f7afc..0e54caddab 100644 --- a/crates/tools/src/main.rs +++ b/crates/tools/src/main.rs @@ -54,13 +54,13 @@ fn gen_tests(mode: Mode) -> Result<()> { if !tests_dir.is_dir() { fs::create_dir_all(&tests_dir)?; } - // ok is never is actually read, but it needs to be specified to create a Test in existing_tests + // ok is never actually read, but it needs to be specified to create a Test in existing_tests let existing = existing_tests(&tests_dir, true)?; for t in existing.keys().filter(|&t| !tests.contains_key(t)) { - panic!("Test is deleted: {}", t); + // panic!("Test is deleted: {}", t); } - let mut new_idx = existing.len() + 2; + let mut new_idx = existing.len() + 1; for (name, test) in tests { let path = match existing.get(name) { Some((path, _test)) => path.clone(),