aboutsummaryrefslogtreecommitdiff
path: root/crates/syntax/test_data/parser/inline/ok
diff options
context:
space:
mode:
Diffstat (limited to 'crates/syntax/test_data/parser/inline/ok')
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rast136
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rast60
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rast60
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rast37
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0006_self_param.rast116
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0006_self_param.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rast40
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0008_path_part.rast96
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0008_path_part.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rast24
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0010_extern_block.rast9
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0010_extern_block.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0011_field_expr.rast59
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0011_field_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rast33
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rast35
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0014_never_type.rast13
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0014_never_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rast35
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0017_array_type.rast21
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0017_array_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rast72
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rast44
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0020_use_star.rast59
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0020_use_star.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rast78
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rast53
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rast13
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rast41
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0025_slice_type.rast17
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0025_slice_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rast104
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rast49
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rast43
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rast89
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0030_cond.rast202
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0030_cond.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0031_while_expr.rast84
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0031_while_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rast98
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rast50
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0034_break_expr.rast53
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0034_break_expr.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rast78
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rast28
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0039_type_arg.rast55
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0039_type_arg.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rast62
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0041_trait_item.rast125
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0041_trait_item.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0042_call_expr.rast147
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0042_call_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0043_use_alias.rast138
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0043_use_alias.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0044_block_items.rast28
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0044_block_items.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rast46
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rast20
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rast81
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rast22
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0051_unit_type.rast14
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0051_unit_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0052_path_type.rast70
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0052_path_type.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0053_path_expr.rast95
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0053_path_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rast44
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rast76
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0056_where_clause.rast110
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0056_where_clause.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0058_range_pat.rast82
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0058_range_pat.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rast58
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rast10
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0061_record_lit.rast124
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0061_record_lit.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rast66
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast23
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0064_if_expr.rast121
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0064_if_expr.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rast43
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0066_match_arm.rast151
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0066_match_arm.rs9
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0067_crate_path.rast15
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0067_crate_path.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0068_union_items.rast46
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0068_union_items.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rast37
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rast50
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0071_match_expr.rast93
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0071_match_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0072_return_expr.rast28
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0072_return_expr.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rast20
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rast59
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs7
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0075_block.rast86
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0075_block.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rast39
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0077_try_expr.rast25
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0077_try_expr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0078_type_item.rast16
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0078_type_item.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0079_impl_def.rast14
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0079_impl_def.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rast95
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0081_for_type.rast112
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0081_for_type.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rast138
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rs10
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0083_struct_items.rast87
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0083_struct_items.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0084_paren_type.rast19
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0084_paren_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rast135
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rs12
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rast34
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rast65
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rast22
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rast23
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0093_index_expr.rast33
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0093_index_expr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rast28
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rast123
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rs13
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0099_param_list.rast99
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0099_param_list.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0100_for_expr.rast34
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0100_for_expr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rast132
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0103_array_expr.rast54
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0103_array_expr.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rast41
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rast135
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rs9
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rast62
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rast38
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0109_label.rast64
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0109_label.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0110_use_path.rast38
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0110_use_path.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rast89
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rast127
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rast55
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rast64
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rast41
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rast43
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast40
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0118_match_guard.rast47
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0118_match_guard.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rast80
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rast145
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rs12
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rast65
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rast50
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rast31
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rast47
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rast97
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rs6
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rast57
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rast36
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rast126
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rs9
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rast31
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0131_existential_type.rast31
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0131_existential_type.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0132_box_expr.rast89
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0132_box_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rast62
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0137_await_expr.rast69
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0137_await_expr.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rast55
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rast64
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rast25
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rast34
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rast40
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0143_box_pat.rast110
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0143_box_pat.rs5
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rast455
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rs25
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rast75
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rs4
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rast42
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0147_const_param.rast23
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0147_const_param.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0147_macro_def.rast45
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0147_macro_def.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rast21
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rast47
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rast38
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0151_fn.rast14
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0151_fn.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rast128
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rast36
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0152_impl.rast22
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0152_impl.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0153_trait.rast11
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0153_trait.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rast58
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rs2
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0155_closure_params.rast69
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0155_closure_params.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rast43
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rast111
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rs8
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rast26
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rast30
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rast36
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rast43
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rast34
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rast27
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rast26
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rast23
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rast44
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rs3
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0164_default_item.rast24
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0164_default_item.rs1
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rast38
-rw-r--r--crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rs1
304 files changed, 9988 insertions, 0 deletions
diff --git a/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rast b/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rast
new file mode 100644
index 000000000..1e80dd7e2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rast
@@ -0,0 +1,136 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected] "{"
8 [email protected]
9 [email protected]
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "crate"
15 [email protected] "::"
16 [email protected]
17 [email protected]
18 [email protected] "path"
19 [email protected] "::"
20 [email protected]
21 [email protected]
22 [email protected] "from"
23 [email protected] "::"
24 [email protected]
25 [email protected]
26 [email protected] "root"
27 [email protected] ","
28 [email protected] " "
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "or"
37 [email protected] "::"
38 [email protected]
39 [email protected]
40 [email protected] "path"
41 [email protected] "::"
42 [email protected]
43 [email protected]
44 [email protected] "from"
45 [email protected] "::"
46 [email protected]
47 [email protected]
48 [email protected] "crate_name"
49 [email protected] "}"
50 [email protected] ";"
51 [email protected] " "
52 [email protected] "// Rust 2018 (with a ..."
53 [email protected] "\n"
54 [email protected]
55 [email protected] "use"
56 [email protected] " "
57 [email protected]
58 [email protected]
59 [email protected] "{"
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected]
65 [email protected]
66 [email protected] "path"
67 [email protected] "::"
68 [email protected]
69 [email protected]
70 [email protected] "from"
71 [email protected] "::"
72 [email protected]
73 [email protected]
74 [email protected] "root"
75 [email protected] "}"
76 [email protected] ";"
77 [email protected] " "
78 [email protected] "// Rust 2015"
79 [email protected] "\n"
80 [email protected]
81 [email protected] "use"
82 [email protected] " "
83 [email protected]
84 [email protected] "::"
85 [email protected]
86 [email protected] "{"
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected]
91 [email protected]
92 [email protected]
93 [email protected] "some"
94 [email protected] "::"
95 [email protected]
96 [email protected]
97 [email protected] "arbritrary"
98 [email protected] "::"
99 [email protected]
100 [email protected]
101 [email protected] "path"
102 [email protected] "}"
103 [email protected] ";"
104 [email protected] " "
105 [email protected] "// Rust 2015"
106 [email protected] "\n"
107 [email protected]
108 [email protected] "use"
109 [email protected] " "
110 [email protected]
111 [email protected] "::"
112 [email protected]
113 [email protected] "{"
114 [email protected]
115 [email protected]
116 [email protected] "{"
117 [email protected]
118 [email protected]
119 [email protected] "{"
120 [email protected]
121 [email protected]
122 [email protected]
123 [email protected]
124 [email protected]
125 [email protected] "root"
126 [email protected] "::"
127 [email protected]
128 [email protected]
129 [email protected] "export"
130 [email protected] "}"
131 [email protected] "}"
132 [email protected] "}"
133 [email protected] ";"
134 [email protected] " "
135 [email protected] "// Nonsensical but pe ..."
136 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rs b/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rs
new file mode 100644
index 000000000..381cba1e2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0002_use_tree_list.rs
@@ -0,0 +1,4 @@
1use {crate::path::from::root, or::path::from::crate_name}; // Rust 2018 (with a crate named `or`)
2use {path::from::root}; // Rust 2015
3use ::{some::arbritrary::path}; // Rust 2015
4use ::{{{root::export}}}; // Nonsensical but perfectly legal nesting
diff --git a/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rast b/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rast
new file mode 100644
index 000000000..62da7b887
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rast
@@ -0,0 +1,60 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "for_trait"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "F"
12 [email protected] ">"
13 [email protected]
14 [email protected] "("
15 [email protected] ")"
16 [email protected] "\n"
17 [email protected]
18 [email protected] "where"
19 [email protected] "\n "
20 [email protected]
21 [email protected] "for"
22 [email protected]
23 [email protected] "<"
24 [email protected]
25 [email protected] "\'a"
26 [email protected] ">"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "F"
33 [email protected] ":"
34 [email protected] " "
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "Fn"
42 [email protected]
43 [email protected] "("
44 [email protected]
45 [email protected]
46 [email protected] "&"
47 [email protected] "\'a"
48 [email protected] " "
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected]
53 [email protected] "str"
54 [email protected] ")"
55 [email protected] "\n"
56 [email protected]
57 [email protected] "{"
58 [email protected] " "
59 [email protected] "}"
60 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rs b/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rs
new file mode 100644
index 000000000..423bc105b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0003_where_pred_for.rs
@@ -0,0 +1,4 @@
1fn for_trait<F>()
2where
3 for<'a> F: Fn(&'a str)
4{ }
diff --git a/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rast b/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rast
new file mode 100644
index 000000000..b650735ba
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rast
@@ -0,0 +1,60 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "F"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "Box"
15 [email protected]
16 [email protected] "<"
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "Fn"
23 [email protected]
24 [email protected] "("
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "i32"
31 [email protected] ","
32 [email protected] " "
33 [email protected]
34 [email protected]
35 [email protected] "&"
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "i32"
41 [email protected] ","
42 [email protected] " "
43 [email protected]
44 [email protected]
45 [email protected] "&"
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected] "i32"
51 [email protected] ","
52 [email protected] " "
53 [email protected]
54 [email protected]
55 [email protected] "("
56 [email protected] ")"
57 [email protected] ")"
58 [email protected] ">"
59 [email protected] ";"
60 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rs b/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rs
new file mode 100644
index 000000000..93636e926
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0004_value_parameters_no_patterns.rs
@@ -0,0 +1 @@
type F = Box<Fn(i32, &i32, &i32, ())>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rast b/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rast
new file mode 100644
index 000000000..8e0252ce7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rast
@@ -0,0 +1,37 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ":"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "Clone"
21 [email protected] " "
22 [email protected] "+"
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "Copy"
30 [email protected] ">"
31 [email protected]
32 [email protected] "("
33 [email protected] ")"
34 [email protected]
35 [email protected] "{"
36 [email protected] "}"
37 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rs b/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rs
new file mode 100644
index 000000000..9df40ed39
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0005_function_type_params.rs
@@ -0,0 +1 @@
fn foo<T: Clone + Copy>(){}
diff --git a/crates/syntax/test_data/parser/inline/ok/0006_self_param.rast b/crates/syntax/test_data/parser/inline/ok/0006_self_param.rast
new file mode 100644
index 000000000..d24ad7423
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0006_self_param.rast
@@ -0,0 +1,116 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "S"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "fn"
16 [email protected] " "
17 [email protected]
18 [email protected] "a"
19 [email protected]
20 [email protected] "("
21 [email protected]
22 [email protected] "self"
23 [email protected] ")"
24 [email protected] " "
25 [email protected]
26 [email protected] "{"
27 [email protected] "}"
28 [email protected] "\n "
29 [email protected]
30 [email protected] "fn"
31 [email protected] " "
32 [email protected]
33 [email protected] "b"
34 [email protected]
35 [email protected] "("
36 [email protected]
37 [email protected] "&"
38 [email protected] "self"
39 [email protected] ","
40 [email protected] ")"
41 [email protected] " "
42 [email protected]
43 [email protected] "{"
44 [email protected] "}"
45 [email protected] "\n "
46 [email protected]
47 [email protected] "fn"
48 [email protected] " "
49 [email protected]
50 [email protected] "c"
51 [email protected]
52 [email protected] "("
53 [email protected]
54 [email protected] "&"
55 [email protected] "\'a"
56 [email protected] " "
57 [email protected] "self"
58 [email protected] ","
59 [email protected] ")"
60 [email protected] " "
61 [email protected]
62 [email protected] "{"
63 [email protected] "}"
64 [email protected] "\n "
65 [email protected]
66 [email protected] "fn"
67 [email protected] " "
68 [email protected]
69 [email protected] "d"
70 [email protected]
71 [email protected] "("
72 [email protected]
73 [email protected] "&"
74 [email protected] "\'a"
75 [email protected] " "
76 [email protected] "mut"
77 [email protected] " "
78 [email protected] "self"
79 [email protected] ","
80 [email protected] " "
81 [email protected]
82 [email protected]
83 [email protected]
84 [email protected] "x"
85 [email protected] ":"
86 [email protected] " "
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected]
91 [email protected] "i32"
92 [email protected] ")"
93 [email protected] " "
94 [email protected]
95 [email protected] "{"
96 [email protected] "}"
97 [email protected] "\n "
98 [email protected]
99 [email protected] "fn"
100 [email protected] " "
101 [email protected]
102 [email protected] "e"
103 [email protected]
104 [email protected] "("
105 [email protected]
106 [email protected] "mut"
107 [email protected] " "
108 [email protected] "self"
109 [email protected] ")"
110 [email protected] " "
111 [email protected]
112 [email protected] "{"
113 [email protected] "}"
114 [email protected] "\n"
115 [email protected] "}"
116 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0006_self_param.rs b/crates/syntax/test_data/parser/inline/ok/0006_self_param.rs
new file mode 100644
index 000000000..80c0a43f5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0006_self_param.rs
@@ -0,0 +1,7 @@
1impl S {
2 fn a(self) {}
3 fn b(&self,) {}
4 fn c(&'a self,) {}
5 fn d(&'a mut self, x: i32) {}
6 fn e(mut self) {}
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rast b/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rast
new file mode 100644
index 000000000..e95688f56
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rast
@@ -0,0 +1,40 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "S"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ":"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected] "\'a"
17 [email protected] " "
18 [email protected] "+"
19 [email protected] " "
20 [email protected]
21 [email protected] "?"
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected] "Sized"
27 [email protected] " "
28 [email protected] "+"
29 [email protected] " "
30 [email protected]
31 [email protected] "("
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "Copy"
37 [email protected] ")"
38 [email protected] ">"
39 [email protected] ";"
40 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rs b/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rs
new file mode 100644
index 000000000..919bde0ee
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0007_type_param_bounds.rs
@@ -0,0 +1 @@
struct S<T: 'a + ?Sized + (Copy)>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0008_path_part.rast b/crates/syntax/test_data/parser/inline/ok/0008_path_part.rast
new file mode 100644
index 000000000..7d2f7eab0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0008_path_part.rast
@@ -0,0 +1,96 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "foo"
23 [email protected] "::"
24 [email protected]
25 [email protected]
26 [email protected] "Bar"
27 [email protected] " "
28 [email protected] "="
29 [email protected] " "
30 [email protected]
31 [email protected] "("
32 [email protected] ")"
33 [email protected] ";"
34 [email protected] "\n "
35 [email protected]
36 [email protected] "let"
37 [email protected] " "
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "::"
42 [email protected]
43 [email protected] "Bar"
44 [email protected] " "
45 [email protected] "="
46 [email protected] " "
47 [email protected]
48 [email protected] "("
49 [email protected] ")"
50 [email protected] ";"
51 [email protected] "\n "
52 [email protected]
53 [email protected] "let"
54 [email protected] " "
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected] "Bar"
60 [email protected] " "
61 [email protected]
62 [email protected] "{"
63 [email protected] " "
64 [email protected] ".."
65 [email protected] " "
66 [email protected] "}"
67 [email protected] " "
68 [email protected] "="
69 [email protected] " "
70 [email protected]
71 [email protected] "("
72 [email protected] ")"
73 [email protected] ";"
74 [email protected] "\n "
75 [email protected]
76 [email protected] "let"
77 [email protected] " "
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "Bar"
83 [email protected] "("
84 [email protected]
85 [email protected] ".."
86 [email protected] ")"
87 [email protected] " "
88 [email protected] "="
89 [email protected] " "
90 [email protected]
91 [email protected] "("
92 [email protected] ")"
93 [email protected] ";"
94 [email protected] "\n"
95 [email protected] "}"
96 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0008_path_part.rs b/crates/syntax/test_data/parser/inline/ok/0008_path_part.rs
new file mode 100644
index 000000000..f6e32c7c1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0008_path_part.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 let foo::Bar = ();
3 let ::Bar = ();
4 let Bar { .. } = ();
5 let Bar(..) = ();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rast b/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rast
new file mode 100644
index 000000000..f62826fd5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rast
@@ -0,0 +1,24 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "loop"
17 [email protected] " "
18 [email protected]
19 [email protected] "{"
20 [email protected] "}"
21 [email protected] ";"
22 [email protected] "\n"
23 [email protected] "}"
24 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rs b/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rs
new file mode 100644
index 000000000..9f078fa48
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0009_loop_expr.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 loop {};
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rast b/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rast
new file mode 100644
index 000000000..869875875
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rast
@@ -0,0 +1,9 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected] "extern"
5 [email protected] " "
6 [email protected]
7 [email protected] "{"
8 [email protected] "}"
9 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rs b/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rs
new file mode 100644
index 000000000..26a9ccd1e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0010_extern_block.rs
@@ -0,0 +1 @@
extern {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rast b/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rast
new file mode 100644
index 000000000..66a609346
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rast
@@ -0,0 +1,59 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "x"
21 [email protected] "."
22 [email protected]
23 [email protected] "foo"
24 [email protected] ";"
25 [email protected] "\n "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected] "x"
34 [email protected] "."
35 [email protected]
36 [email protected] "0"
37 [email protected] "."
38 [email protected]
39 [email protected] "bar"
40 [email protected] ";"
41 [email protected] "\n "
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "x"
50 [email protected] "."
51 [email protected]
52 [email protected] "0"
53 [email protected]
54 [email protected] "("
55 [email protected] ")"
56 [email protected] ";"
57 [email protected] "\n"
58 [email protected] "}"
59 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rs b/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rs
new file mode 100644
index 000000000..b8da2ddc3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0011_field_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 x.foo;
3 x.0.bar;
4 x.0();
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rast b/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rast
new file mode 100644
index 000000000..28c94bfd6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rast
@@ -0,0 +1,33 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] " "
8 [email protected]
9 [email protected] "where"
10 [email protected] " "
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected] "Foo"
17 [email protected] ":"
18 [email protected] " "
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "Copy"
26 [email protected] " "
27 [email protected] "="
28 [email protected] " "
29 [email protected]
30 [email protected] "("
31 [email protected] ")"
32 [email protected] ";"
33 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rs b/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rs
new file mode 100644
index 000000000..a602d07f0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0012_type_item_where_clause.rs
@@ -0,0 +1 @@
type Foo where Foo: Copy = ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rast b/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rast
new file mode 100644
index 000000000..d33215b50
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rast
@@ -0,0 +1,35 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "M"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "*"
12 [email protected] "mut"
13 [email protected] " "
14 [email protected]
15 [email protected] "("
16 [email protected] ")"
17 [email protected] ";"
18 [email protected] "\n"
19 [email protected]
20 [email protected] "type"
21 [email protected] " "
22 [email protected]
23 [email protected] "C"
24 [email protected] " "
25 [email protected] "="
26 [email protected] " "
27 [email protected]
28 [email protected] "*"
29 [email protected] "mut"
30 [email protected] " "
31 [email protected]
32 [email protected] "("
33 [email protected] ")"
34 [email protected] ";"
35 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rs b/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rs
new file mode 100644
index 000000000..04b2bb9ba
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0013_pointer_type_mut.rs
@@ -0,0 +1,2 @@
1type M = *mut ();
2type C = *mut ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0014_never_type.rast b/crates/syntax/test_data/parser/inline/ok/0014_never_type.rast
new file mode 100644
index 000000000..b1d5106ce
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0014_never_type.rast
@@ -0,0 +1,13 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Never"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "!"
12 [email protected] ";"
13 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0014_never_type.rs b/crates/syntax/test_data/parser/inline/ok/0014_never_type.rs
new file mode 100644
index 000000000..de399fcf4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0014_never_type.rs
@@ -0,0 +1 @@
type Never = !;
diff --git a/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rast b/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rast
new file mode 100644
index 000000000..104e153ce
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rast
@@ -0,0 +1,35 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "loop"
16 [email protected] " "
17 [email protected]
18 [email protected] "{"
19 [email protected] "\n "
20 [email protected]
21 [email protected]
22 [email protected] "continue"
23 [email protected] ";"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected] "continue"
28 [email protected] " "
29 [email protected] "\'l"
30 [email protected] ";"
31 [email protected] "\n "
32 [email protected] "}"
33 [email protected] "\n"
34 [email protected] "}"
35 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rs b/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rs
new file mode 100644
index 000000000..474cc3f0e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0015_continue_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 loop {
3 continue;
4 continue 'l;
5 }
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0017_array_type.rast b/crates/syntax/test_data/parser/inline/ok/0017_array_type.rast
new file mode 100644
index 000000000..c131df1c9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0017_array_type.rast
@@ -0,0 +1,21 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "["
12 [email protected]
13 [email protected] "("
14 [email protected] ")"
15 [email protected] ";"
16 [email protected] " "
17 [email protected]
18 [email protected] "92"
19 [email protected] "]"
20 [email protected] ";"
21 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0017_array_type.rs b/crates/syntax/test_data/parser/inline/ok/0017_array_type.rs
new file mode 100644
index 000000000..27eb22f22
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0017_array_type.rs
@@ -0,0 +1 @@
type T = [(); 92];
diff --git a/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rast b/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rast
new file mode 100644
index 000000000..ddbd66588
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rast
@@ -0,0 +1,72 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "S"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "fn"
16 [email protected] " "
17 [email protected]
18 [email protected] "a"
19 [email protected]
20 [email protected] "("
21 [email protected]
22 [email protected] "self"
23 [email protected] ":"
24 [email protected] " "
25 [email protected]
26 [email protected] "&"
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected] "Self"
32 [email protected] ")"
33 [email protected] " "
34 [email protected]
35 [email protected] "{"
36 [email protected] "}"
37 [email protected] "\n "
38 [email protected]
39 [email protected] "fn"
40 [email protected] " "
41 [email protected]
42 [email protected] "b"
43 [email protected]
44 [email protected] "("
45 [email protected]
46 [email protected] "mut"
47 [email protected] " "
48 [email protected] "self"
49 [email protected] ":"
50 [email protected] " "
51 [email protected]
52 [email protected]
53 [email protected]
54 [email protected]
55 [email protected] "Box"
56 [email protected]
57 [email protected] "<"
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected] "Self"
64 [email protected] ">"
65 [email protected] ")"
66 [email protected] " "
67 [email protected]
68 [email protected] "{"
69 [email protected] "}"
70 [email protected] "\n"
71 [email protected] "}"
72 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rs b/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rs
new file mode 100644
index 000000000..6a170d5ac
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0018_arb_self_types.rs
@@ -0,0 +1,4 @@
1impl S {
2 fn a(self: &Self) {}
3 fn b(mut self: Box<Self>) {}
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rast b/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rast
new file mode 100644
index 000000000..7db38ea4d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rast
@@ -0,0 +1,44 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "*"
17 [email protected]
18 [email protected] "*"
19 [email protected]
20 [email protected] "&"
21 [email protected]
22 [email protected] "1"
23 [email protected] ";"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected] "!"
28 [email protected]
29 [email protected] "!"
30 [email protected]
31 [email protected] "true"
32 [email protected] ";"
33 [email protected] "\n "
34 [email protected]
35 [email protected]
36 [email protected] "-"
37 [email protected]
38 [email protected] "-"
39 [email protected]
40 [email protected] "1"
41 [email protected] ";"
42 [email protected] "\n"
43 [email protected] "}"
44 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rs b/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rs
new file mode 100644
index 000000000..f1c3f7118
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0019_unary_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 **&1;
3 !!true;
4 --1;
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0020_use_star.rast b/crates/syntax/test_data/parser/inline/ok/0020_use_star.rast
new file mode 100644
index 000000000..b3623c445
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0020_use_star.rast
@@ -0,0 +1,59 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected] "*"
7 [email protected] ";"
8 [email protected] "\n"
9 [email protected]
10 [email protected] "use"
11 [email protected] " "
12 [email protected]
13 [email protected] "::"
14 [email protected] "*"
15 [email protected] ";"
16 [email protected] "\n"
17 [email protected]
18 [email protected] "use"
19 [email protected] " "
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "some"
26 [email protected] "::"
27 [email protected]
28 [email protected]
29 [email protected] "path"
30 [email protected] "::"
31 [email protected]
32 [email protected] "{"
33 [email protected]
34 [email protected] "*"
35 [email protected] "}"
36 [email protected] ";"
37 [email protected] "\n"
38 [email protected]
39 [email protected] "use"
40 [email protected] " "
41 [email protected]
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected] "some"
47 [email protected] "::"
48 [email protected]
49 [email protected]
50 [email protected] "path"
51 [email protected] "::"
52 [email protected]
53 [email protected] "{"
54 [email protected]
55 [email protected] "::"
56 [email protected] "*"
57 [email protected] "}"
58 [email protected] ";"
59 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0020_use_star.rs b/crates/syntax/test_data/parser/inline/ok/0020_use_star.rs
new file mode 100644
index 000000000..6f15769a8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0020_use_star.rs
@@ -0,0 +1,4 @@
1use *;
2use ::*;
3use some::path::{*};
4use some::path::{::*};
diff --git a/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rast b/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rast
new file mode 100644
index 000000000..ca0702aba
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rast
@@ -0,0 +1,78 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "F"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "type"
16 [email protected] " "
17 [email protected]
18 [email protected] "A"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected] "i32"
27 [email protected] ";"
28 [email protected] "\n "
29 [email protected]
30 [email protected] "const"
31 [email protected] " "
32 [email protected]
33 [email protected] "B"
34 [email protected] ":"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "i32"
41 [email protected] " "
42 [email protected] "="
43 [email protected] " "
44 [email protected]
45 [email protected] "92"
46 [email protected] ";"
47 [email protected] "\n "
48 [email protected]
49 [email protected] "fn"
50 [email protected] " "
51 [email protected]
52 [email protected] "foo"
53 [email protected]
54 [email protected] "("
55 [email protected] ")"
56 [email protected] " "
57 [email protected]
58 [email protected] "{"
59 [email protected] "}"
60 [email protected] "\n "
61 [email protected]
62 [email protected] "fn"
63 [email protected] " "
64 [email protected]
65 [email protected] "bar"
66 [email protected]
67 [email protected] "("
68 [email protected]
69 [email protected] "&"
70 [email protected] "self"
71 [email protected] ")"
72 [email protected] " "
73 [email protected]
74 [email protected] "{"
75 [email protected] "}"
76 [email protected] "\n"
77 [email protected] "}"
78 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rs b/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rs
new file mode 100644
index 000000000..f10851487
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0021_impl_item_list.rs
@@ -0,0 +1,6 @@
1impl F {
2 type A = i32;
3 const B: i32 = 92;
4 fn foo() {}
5 fn bar(&self) {}
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rast b/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rast
new file mode 100644
index 000000000..50742cbcf
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rast
@@ -0,0 +1,53 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected] "pub"
5 [email protected] "("
6 [email protected] "crate"
7 [email protected] ")"
8 [email protected] " "
9 [email protected] "struct"
10 [email protected] " "
11 [email protected]
12 [email protected] "S"
13 [email protected] ";"
14 [email protected] "\n"
15 [email protected]
16 [email protected]
17 [email protected] "pub"
18 [email protected] "("
19 [email protected] "self"
20 [email protected] ")"
21 [email protected] " "
22 [email protected] "struct"
23 [email protected] " "
24 [email protected]
25 [email protected] "S"
26 [email protected] ";"
27 [email protected] "\n"
28 [email protected]
29 [email protected]
30 [email protected] "pub"
31 [email protected] "("
32 [email protected] "self"
33 [email protected] ")"
34 [email protected] " "
35 [email protected] "struct"
36 [email protected] " "
37 [email protected]
38 [email protected] "S"
39 [email protected] ";"
40 [email protected] "\n"
41 [email protected]
42 [email protected]
43 [email protected] "pub"
44 [email protected] "("
45 [email protected] "self"
46 [email protected] ")"
47 [email protected] " "
48 [email protected] "struct"
49 [email protected] " "
50 [email protected]
51 [email protected] "S"
52 [email protected] ";"
53 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rs b/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rs
new file mode 100644
index 000000000..faeefde94
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0022_crate_visibility.rs
@@ -0,0 +1,4 @@
1pub(crate) struct S;
2pub(self) struct S;
3pub(self) struct S;
4pub(self) struct S;
diff --git a/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rast b/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rast
new file mode 100644
index 000000000..e4fe2b948
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rast
@@ -0,0 +1,13 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Placeholder"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "_"
12 [email protected] ";"
13 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rs b/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rs
new file mode 100644
index 000000000..7952dbd57
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0023_placeholder_type.rs
@@ -0,0 +1 @@
type Placeholder = _;
diff --git a/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rast b/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rast
new file mode 100644
index 000000000..2dbce34b6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rast
@@ -0,0 +1,41 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "["
19 [email protected]
20 [email protected]
21 [email protected] "a"
22 [email protected] ","
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected] "b"
27 [email protected] ","
28 [email protected] " "
29 [email protected]
30 [email protected] ".."
31 [email protected] "]"
32 [email protected] " "
33 [email protected] "="
34 [email protected] " "
35 [email protected]
36 [email protected] "["
37 [email protected] "]"
38 [email protected] ";"
39 [email protected] "\n"
40 [email protected] "}"
41 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rs b/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rs
new file mode 100644
index 000000000..7955973b9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0024_slice_pat.rs
@@ -0,0 +1,3 @@
1fn main() {
2 let [a, b, ..] = [];
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rast b/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rast
new file mode 100644
index 000000000..fd819ea37
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rast
@@ -0,0 +1,17 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "["
12 [email protected]
13 [email protected] "("
14 [email protected] ")"
15 [email protected] "]"
16 [email protected] ";"
17 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rs b/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rs
new file mode 100644
index 000000000..4da1af827
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0025_slice_type.rs
@@ -0,0 +1 @@
type T = [()];
diff --git a/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rast b/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rast
new file mode 100644
index 000000000..467a30134
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rast
@@ -0,0 +1,104 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "S"
22 [email protected] "("
23 [email protected] ")"
24 [email protected] " "
25 [email protected] "="
26 [email protected] " "
27 [email protected]
28 [email protected] "("
29 [email protected] ")"
30 [email protected] ";"
31 [email protected] "\n "
32 [email protected]
33 [email protected] "let"
34 [email protected] " "
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected] "S"
40 [email protected] "("
41 [email protected]
42 [email protected] "_"
43 [email protected] ")"
44 [email protected] " "
45 [email protected] "="
46 [email protected] " "
47 [email protected]
48 [email protected] "("
49 [email protected] ")"
50 [email protected] ";"
51 [email protected] "\n "
52 [email protected]
53 [email protected] "let"
54 [email protected] " "
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected] "S"
60 [email protected] "("
61 [email protected]
62 [email protected] "_"
63 [email protected] ","
64 [email protected] ")"
65 [email protected] " "
66 [email protected] "="
67 [email protected] " "
68 [email protected]
69 [email protected] "("
70 [email protected] ")"
71 [email protected] ";"
72 [email protected] "\n "
73 [email protected]
74 [email protected] "let"
75 [email protected] " "
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected] "S"
81 [email protected] "("
82 [email protected]
83 [email protected] "_"
84 [email protected] ","
85 [email protected] " "
86 [email protected]
87 [email protected] ".."
88 [email protected] " "
89 [email protected] ","
90 [email protected] " "
91 [email protected]
92 [email protected]
93 [email protected] "x"
94 [email protected] ")"
95 [email protected] " "
96 [email protected] "="
97 [email protected] " "
98 [email protected]
99 [email protected] "("
100 [email protected] ")"
101 [email protected] ";"
102 [email protected] "\n"
103 [email protected] "}"
104 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rs b/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rs
new file mode 100644
index 000000000..0dfe63629
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0026_tuple_pat_fields.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 let S() = ();
3 let S(_) = ();
4 let S(_,) = ();
5 let S(_, .. , x) = ();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rast b/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rast
new file mode 100644
index 000000000..348b54dc9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rast
@@ -0,0 +1,49 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "&"
19 [email protected]
20 [email protected]
21 [email protected] "a"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected]
26 [email protected] "("
27 [email protected] ")"
28 [email protected] ";"
29 [email protected] "\n "
30 [email protected]
31 [email protected] "let"
32 [email protected] " "
33 [email protected]
34 [email protected] "&"
35 [email protected] "mut"
36 [email protected] " "
37 [email protected]
38 [email protected]
39 [email protected] "b"
40 [email protected] " "
41 [email protected] "="
42 [email protected] " "
43 [email protected]
44 [email protected] "("
45 [email protected] ")"
46 [email protected] ";"
47 [email protected] "\n"
48 [email protected] "}"
49 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rs b/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rs
new file mode 100644
index 000000000..de41f5cae
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0027_ref_pat.rs
@@ -0,0 +1,4 @@
1fn main() {
2 let &a = ();
3 let &mut b = ();
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rast b/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rast
new file mode 100644
index 000000000..32b2959bd
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rast
@@ -0,0 +1,43 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "impl"
12 [email protected] " "
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "Iterator"
20 [email protected]
21 [email protected] "<"
22 [email protected]
23 [email protected]
24 [email protected] "Item"
25 [email protected] "="
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "Foo"
31 [email protected]
32 [email protected] "<"
33 [email protected]
34 [email protected] "\'a"
35 [email protected] ">"
36 [email protected] ">"
37 [email protected] " "
38 [email protected] "+"
39 [email protected] " "
40 [email protected]
41 [email protected] "\'a"
42 [email protected] ";"
43 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rs b/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rs
new file mode 100644
index 000000000..54c5a7c46
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0028_impl_trait_type.rs
@@ -0,0 +1 @@
type A = impl Iterator<Item=Foo<'a>> + 'a;
diff --git a/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rast b/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rast
new file mode 100644
index 000000000..e096b3a1f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rast
@@ -0,0 +1,89 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "82"
18 [email protected] " "
19 [email protected] "as"
20 [email protected] " "
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "i32"
26 [email protected] ";"
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "81"
33 [email protected] " "
34 [email protected] "as"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "i8"
41 [email protected] " "
42 [email protected] "+"
43 [email protected] " "
44 [email protected]
45 [email protected] "1"
46 [email protected] ";"
47 [email protected] "\n "
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected] "79"
53 [email protected] " "
54 [email protected] "as"
55 [email protected] " "
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected]
60 [email protected] "i16"
61 [email protected] " "
62 [email protected] "-"
63 [email protected] " "
64 [email protected]
65 [email protected] "1"
66 [email protected] ";"
67 [email protected] "\n "
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected]
72 [email protected] "0x36"
73 [email protected] " "
74 [email protected] "as"
75 [email protected] " "
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected] "u8"
81 [email protected] " "
82 [email protected] "<="
83 [email protected] " "
84 [email protected]
85 [email protected] "0x37"
86 [email protected] ";"
87 [email protected] "\n"
88 [email protected] "}"
89 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rs b/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rs
new file mode 100644
index 000000000..bfe8e4b36
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0029_cast_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 82 as i32;
3 81 as i8 + 1;
4 79 as i16 - 1;
5 0x36 as u8 <= 0x37;
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0030_cond.rast b/crates/syntax/test_data/parser/inline/ok/0030_cond.rast
new file mode 100644
index 000000000..58a97d3ad
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0030_cond.rast
@@ -0,0 +1,202 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected] "if"
16 [email protected] " "
17 [email protected]
18 [email protected] "let"
19 [email protected] " "
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected] "Some"
25 [email protected] "("
26 [email protected]
27 [email protected] "_"
28 [email protected] ")"
29 [email protected] " "
30 [email protected] "="
31 [email protected] " "
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "None"
37 [email protected] " "
38 [email protected]
39 [email protected] "{"
40 [email protected] "}"
41 [email protected] " "
42 [email protected] "}"
43 [email protected] "\n"
44 [email protected]
45 [email protected] "fn"
46 [email protected] " "
47 [email protected]
48 [email protected] "bar"
49 [email protected]
50 [email protected] "("
51 [email protected] ")"
52 [email protected] " "
53 [email protected]
54 [email protected] "{"
55 [email protected] "\n "
56 [email protected]
57 [email protected]
58 [email protected] "if"
59 [email protected] " "
60 [email protected]
61 [email protected] "let"
62 [email protected] " "
63 [email protected]
64 [email protected]
65 [email protected]
66 [email protected]
67 [email protected]
68 [email protected] "Some"
69 [email protected] "("
70 [email protected]
71 [email protected] "_"
72 [email protected] ")"
73 [email protected] " "
74 [email protected] "|"
75 [email protected] " "
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected] "Some"
81 [email protected] "("
82 [email protected]
83 [email protected] "_"
84 [email protected] ")"
85 [email protected] " "
86 [email protected] "="
87 [email protected] " "
88 [email protected]
89 [email protected]
90 [email protected]
91 [email protected]
92 [email protected] "None"
93 [email protected] " "
94 [email protected]
95 [email protected] "{"
96 [email protected] "}"
97 [email protected] "\n "
98 [email protected]
99 [email protected]
100 [email protected] "if"
101 [email protected] " "
102 [email protected]
103 [email protected] "let"
104 [email protected] " "
105 [email protected] "|"
106 [email protected] " "
107 [email protected]
108 [email protected]
109 [email protected]
110 [email protected]
111 [email protected] "Some"
112 [email protected] "("
113 [email protected]
114 [email protected] "_"
115 [email protected] ")"
116 [email protected] " "
117 [email protected] "="
118 [email protected] " "
119 [email protected]
120 [email protected]
121 [email protected]
122 [email protected]
123 [email protected] "None"
124 [email protected] " "
125 [email protected]
126 [email protected] "{"
127 [email protected] "}"
128 [email protected] "\n "
129 [email protected]
130 [email protected]
131 [email protected] "while"
132 [email protected] " "
133 [email protected]
134 [email protected] "let"
135 [email protected] " "
136 [email protected]
137 [email protected]
138 [email protected]
139 [email protected]
140 [email protected]
141 [email protected] "Some"
142 [email protected] "("
143 [email protected]
144 [email protected] "_"
145 [email protected] ")"
146 [email protected] " "
147 [email protected] "|"
148 [email protected] " "
149 [email protected]
150 [email protected]
151 [email protected]
152 [email protected]
153 [email protected] "Some"
154 [email protected] "("
155 [email protected]
156 [email protected] "_"
157 [email protected] ")"
158 [email protected] " "
159 [email protected] "="
160 [email protected] " "
161 [email protected]
162 [email protected]
163 [email protected]
164 [email protected]
165 [email protected] "None"
166 [email protected] " "
167 [email protected]
168 [email protected] "{"
169 [email protected] "}"
170 [email protected] "\n "
171 [email protected]
172 [email protected] "while"
173 [email protected] " "
174 [email protected]
175 [email protected] "let"
176 [email protected] " "
177 [email protected] "|"
178 [email protected] " "
179 [email protected]
180 [email protected]
181 [email protected]
182 [email protected]
183 [email protected] "Some"
184 [email protected] "("
185 [email protected]
186 [email protected] "_"
187 [email protected] ")"
188 [email protected] " "
189 [email protected] "="
190 [email protected] " "
191 [email protected]
192 [email protected]
193 [email protected]
194 [email protected]
195 [email protected] "None"
196 [email protected] " "
197 [email protected]
198 [email protected] "{"
199 [email protected] "}"
200 [email protected] "\n"
201 [email protected] "}"
202 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0030_cond.rs b/crates/syntax/test_data/parser/inline/ok/0030_cond.rs
new file mode 100644
index 000000000..2552a2621
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0030_cond.rs
@@ -0,0 +1,7 @@
1fn foo() { if let Some(_) = None {} }
2fn bar() {
3 if let Some(_) | Some(_) = None {}
4 if let | Some(_) = None {}
5 while let Some(_) | Some(_) = None {}
6 while let | Some(_) = None {}
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rast b/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rast
new file mode 100644
index 000000000..173cecf6d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rast
@@ -0,0 +1,84 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "while"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "true"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] ";"
26 [email protected] "\n "
27 [email protected]
28 [email protected]
29 [email protected] "while"
30 [email protected] " "
31 [email protected]
32 [email protected] "let"
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected] "Some"
39 [email protected] "("
40 [email protected]
41 [email protected]
42 [email protected] "x"
43 [email protected] ")"
44 [email protected] " "
45 [email protected] "="
46 [email protected] " "
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected] "it"
53 [email protected] "."
54 [email protected]
55 [email protected] "next"
56 [email protected]
57 [email protected] "("
58 [email protected] ")"
59 [email protected] " "
60 [email protected]
61 [email protected] "{"
62 [email protected] "}"
63 [email protected] ";"
64 [email protected] "\n "
65 [email protected]
66 [email protected]
67 [email protected] "while"
68 [email protected] " "
69 [email protected]
70 [email protected]
71 [email protected] "{"
72 [email protected] " "
73 [email protected]
74 [email protected] "true"
75 [email protected] " "
76 [email protected] "}"
77 [email protected] " "
78 [email protected]
79 [email protected] "{"
80 [email protected] "}"
81 [email protected] ";"
82 [email protected] "\n"
83 [email protected] "}"
84 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rs b/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rs
new file mode 100644
index 000000000..2f8188160
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0031_while_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 while true {};
3 while let Some(x) = it.next() {};
4 while { true } {};
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rast b/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rast
new file mode 100644
index 000000000..dda6577ed
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rast
@@ -0,0 +1,98 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "fn"
12 [email protected]
13 [email protected] "("
14 [email protected] ")"
15 [email protected] ";"
16 [email protected] "\n"
17 [email protected]
18 [email protected] "type"
19 [email protected] " "
20 [email protected]
21 [email protected] "B"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected]
26 [email protected] "unsafe"
27 [email protected] " "
28 [email protected] "fn"
29 [email protected]
30 [email protected] "("
31 [email protected] ")"
32 [email protected] ";"
33 [email protected] "\n"
34 [email protected]
35 [email protected] "type"
36 [email protected] " "
37 [email protected]
38 [email protected] "C"
39 [email protected] " "
40 [email protected] "="
41 [email protected] " "
42 [email protected]
43 [email protected] "unsafe"
44 [email protected] " "
45 [email protected]
46 [email protected] "extern"
47 [email protected] " "
48 [email protected] "\"C\""
49 [email protected] " "
50 [email protected] "fn"
51 [email protected]
52 [email protected] "("
53 [email protected] ")"
54 [email protected] ";"
55 [email protected] "\n"
56 [email protected]
57 [email protected] "type"
58 [email protected] " "
59 [email protected]
60 [email protected] "D"
61 [email protected] " "
62 [email protected] "="
63 [email protected] " "
64 [email protected]
65 [email protected]
66 [email protected] "extern"
67 [email protected] " "
68 [email protected] "\"C\""
69 [email protected] " "
70 [email protected] "fn"
71 [email protected] " "
72 [email protected]
73 [email protected] "("
74 [email protected] " "
75 [email protected]
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected] "u8"
81 [email protected] " "
82 [email protected] ","
83 [email protected] " "
84 [email protected]
85 [email protected] "..."
86 [email protected] " "
87 [email protected] ")"
88 [email protected] " "
89 [email protected]
90 [email protected] "->"
91 [email protected] " "
92 [email protected]
93 [email protected]
94 [email protected]
95 [email protected]
96 [email protected] "u8"
97 [email protected] ";"
98 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rs b/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rs
new file mode 100644
index 000000000..9493da83d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0032_fn_pointer_type.rs
@@ -0,0 +1,4 @@
1type A = fn();
2type B = unsafe fn();
3type C = unsafe extern "C" fn();
4type D = extern "C" fn ( u8 , ... ) -> u8;
diff --git a/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rast b/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rast
new file mode 100644
index 000000000..974df9f9a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rast
@@ -0,0 +1,50 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "&"
12 [email protected]
13 [email protected] "("
14 [email protected] ")"
15 [email protected] ";"
16 [email protected] "\n"
17 [email protected]
18 [email protected] "type"
19 [email protected] " "
20 [email protected]
21 [email protected] "B"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected]
26 [email protected] "&"
27 [email protected] "\'static"
28 [email protected] " "
29 [email protected]
30 [email protected] "("
31 [email protected] ")"
32 [email protected] ";"
33 [email protected] "\n"
34 [email protected]
35 [email protected] "type"
36 [email protected] " "
37 [email protected]
38 [email protected] "C"
39 [email protected] " "
40 [email protected] "="
41 [email protected] " "
42 [email protected]
43 [email protected] "&"
44 [email protected] "mut"
45 [email protected] " "
46 [email protected]
47 [email protected] "("
48 [email protected] ")"
49 [email protected] ";"
50 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rs b/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rs
new file mode 100644
index 000000000..3ac0badab
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0033_reference_type;.rs
@@ -0,0 +1,3 @@
1type A = &();
2type B = &'static ();
3type C = &mut ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rast b/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rast
new file mode 100644
index 000000000..f905def6f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rast
@@ -0,0 +1,53 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "loop"
16 [email protected] " "
17 [email protected]
18 [email protected] "{"
19 [email protected] "\n "
20 [email protected]
21 [email protected]
22 [email protected] "break"
23 [email protected] ";"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected] "break"
28 [email protected] " "
29 [email protected] "\'l"
30 [email protected] ";"
31 [email protected] "\n "
32 [email protected]
33 [email protected]
34 [email protected] "break"
35 [email protected] " "
36 [email protected]
37 [email protected] "92"
38 [email protected] ";"
39 [email protected] "\n "
40 [email protected]
41 [email protected]
42 [email protected] "break"
43 [email protected] " "
44 [email protected] "\'l"
45 [email protected] " "
46 [email protected]
47 [email protected] "92"
48 [email protected] ";"
49 [email protected] "\n "
50 [email protected] "}"
51 [email protected] "\n"
52 [email protected] "}"
53 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rs b/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rs
new file mode 100644
index 000000000..1b4094636
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0034_break_expr.rs
@@ -0,0 +1,8 @@
1fn foo() {
2 loop {
3 break;
4 break 'l;
5 break 92;
6 break 'l 92;
7 }
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rast b/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rast
new file mode 100644
index 000000000..b6379e62f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rast
@@ -0,0 +1,78 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "X"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "<"
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "A"
20 [email protected] " "
21 [email protected] "as"
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected] "B"
28 [email protected] ">"
29 [email protected] "::"
30 [email protected]
31 [email protected]
32 [email protected] "Output"
33 [email protected] ";"
34 [email protected] "\n"
35 [email protected]
36 [email protected] "fn"
37 [email protected] " "
38 [email protected]
39 [email protected] "foo"
40 [email protected]
41 [email protected] "("
42 [email protected] ")"
43 [email protected] " "
44 [email protected]
45 [email protected] "{"
46 [email protected] " "
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected]
53 [email protected] "<"
54 [email protected]
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected] "usize"
59 [email protected] " "
60 [email protected] "as"
61 [email protected] " "
62 [email protected]
63 [email protected]
64 [email protected]
65 [email protected]
66 [email protected] "Default"
67 [email protected] ">"
68 [email protected] "::"
69 [email protected]
70 [email protected]
71 [email protected] "default"
72 [email protected]
73 [email protected] "("
74 [email protected] ")"
75 [email protected] ";"
76 [email protected] " "
77 [email protected] "}"
78 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rs b/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rs
new file mode 100644
index 000000000..d140692e2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0037_qual_paths.rs
@@ -0,0 +1,2 @@
1type X = <A as B>::Output;
2fn foo() { <usize as Default>::default(); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rast b/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rast
new file mode 100644
index 000000000..64e705fb3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rast
@@ -0,0 +1,28 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "xs"
21 [email protected] "["
22 [email protected]
23 [email protected] ".."
24 [email protected] "]"
25 [email protected] ";"
26 [email protected] " "
27 [email protected] "}"
28 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rs b/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rs
new file mode 100644
index 000000000..ae21ad94c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0038_full_range_expr.rs
@@ -0,0 +1 @@
fn foo() { xs[..]; }
diff --git a/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rast b/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rast
new file mode 100644
index 000000000..69e98b9d6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rast
@@ -0,0 +1,55 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "B"
15 [email protected]
16 [email protected] "<"
17 [email protected]
18 [email protected] "\'static"
19 [email protected] ","
20 [email protected] " "
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected] "i32"
27 [email protected] ","
28 [email protected] " "
29 [email protected]
30 [email protected]
31 [email protected] "1"
32 [email protected] ","
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected] "{"
37 [email protected] " "
38 [email protected]
39 [email protected] "2"
40 [email protected] " "
41 [email protected] "}"
42 [email protected] ","
43 [email protected] " "
44 [email protected]
45 [email protected]
46 [email protected] "Item"
47 [email protected] "="
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected] "u64"
53 [email protected] ">"
54 [email protected] ";"
55 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rs b/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rs
new file mode 100644
index 000000000..0d07d7651
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0039_type_arg.rs
@@ -0,0 +1 @@
type A = B<'static, i32, 1, { 2 }, Item=u64>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rast b/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rast
new file mode 100644
index 000000000..db5bd2849
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rast
@@ -0,0 +1,62 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected] "crate"
5 [email protected] " "
6 [email protected] "fn"
7 [email protected] " "
8 [email protected]
9 [email protected] "main"
10 [email protected]
11 [email protected] "("
12 [email protected] ")"
13 [email protected] " "
14 [email protected]
15 [email protected] "{"
16 [email protected] " "
17 [email protected] "}"
18 [email protected] "\n"
19 [email protected]
20 [email protected] "struct"
21 [email protected] " "
22 [email protected]
23 [email protected] "S"
24 [email protected] " "
25 [email protected]
26 [email protected] "{"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected] "crate"
31 [email protected] " "
32 [email protected]
33 [email protected] "field"
34 [email protected] ":"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "u32"
41 [email protected] " "
42 [email protected] "}"
43 [email protected] "\n"
44 [email protected]
45 [email protected] "struct"
46 [email protected] " "
47 [email protected]
48 [email protected] "T"
49 [email protected]
50 [email protected] "("
51 [email protected]
52 [email protected]
53 [email protected] "crate"
54 [email protected] " "
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected] "u32"
60 [email protected] ")"
61 [email protected] ";"
62 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rs b/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rs
new file mode 100644
index 000000000..e2b5f2161
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0040_crate_keyword_vis.rs
@@ -0,0 +1,3 @@
1crate fn main() { }
2struct S { crate field: u32 }
3struct T(crate u32);
diff --git a/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rast b/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rast
new file mode 100644
index 000000000..3638462f8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rast
@@ -0,0 +1,125 @@
1[email protected]
2 [email protected]
3 [email protected] "trait"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "U"
12 [email protected] ">"
13 [email protected] ":"
14 [email protected] " "
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "Hash"
22 [email protected] " "
23 [email protected] "+"
24 [email protected] " "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "Clone"
31 [email protected] " "
32 [email protected]
33 [email protected] "where"
34 [email protected] " "
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "U"
41 [email protected] ":"
42 [email protected] " "
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "Copy"
50 [email protected] " "
51 [email protected]
52 [email protected] "{"
53 [email protected] "}"
54 [email protected] "\n"
55 [email protected]
56 [email protected] "trait"
57 [email protected] " "
58 [email protected]
59 [email protected] "X"
60 [email protected]
61 [email protected] "<"
62 [email protected]
63 [email protected]
64 [email protected] "U"
65 [email protected] ":"
66 [email protected] " "
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected]
72 [email protected]
73 [email protected] "Debug"
74 [email protected] " "
75 [email protected] "+"
76 [email protected] " "
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "Display"
83 [email protected] ">"
84 [email protected] ":"
85 [email protected] " "
86 [email protected]
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected]
91 [email protected]
92 [email protected] "Hash"
93 [email protected] " "
94 [email protected] "+"
95 [email protected] " "
96 [email protected]
97 [email protected]
98 [email protected]
99 [email protected]
100 [email protected]
101 [email protected] "Clone"
102 [email protected] " "
103 [email protected]
104 [email protected] "where"
105 [email protected] " "
106 [email protected]
107 [email protected]
108 [email protected]
109 [email protected]
110 [email protected]
111 [email protected] "U"
112 [email protected] ":"
113 [email protected] " "
114 [email protected]
115 [email protected]
116 [email protected]
117 [email protected]
118 [email protected]
119 [email protected]
120 [email protected] "Copy"
121 [email protected] " "
122 [email protected]
123 [email protected] "{"
124 [email protected] "}"
125 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rs b/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rs
new file mode 100644
index 000000000..32761dd03
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0041_trait_item.rs
@@ -0,0 +1,2 @@
1trait T<U>: Hash + Clone where U: Copy {}
2trait X<U: Debug + Display>: Hash + Clone where U: Copy {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rast b/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rast
new file mode 100644
index 000000000..fa38e9466
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rast
@@ -0,0 +1,147 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected] "f"
28 [email protected]
29 [email protected] "("
30 [email protected] ")"
31 [email protected] ";"
32 [email protected] "\n "
33 [email protected]
34 [email protected] "let"
35 [email protected] " "
36 [email protected]
37 [email protected] "_"
38 [email protected] " "
39 [email protected] "="
40 [email protected] " "
41 [email protected]
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected] "f"
49 [email protected]
50 [email protected] "("
51 [email protected] ")"
52 [email protected]
53 [email protected] "("
54 [email protected]
55 [email protected] "1"
56 [email protected] ")"
57 [email protected]
58 [email protected] "("
59 [email protected]
60 [email protected] "1"
61 [email protected] ","
62 [email protected] " "
63 [email protected]
64 [email protected] "2"
65 [email protected] ","
66 [email protected] ")"
67 [email protected] ";"
68 [email protected] "\n "
69 [email protected]
70 [email protected] "let"
71 [email protected] " "
72 [email protected]
73 [email protected] "_"
74 [email protected] " "
75 [email protected] "="
76 [email protected] " "
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "f"
83 [email protected]
84 [email protected] "("
85 [email protected]
86 [email protected]
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected] "<"
91 [email protected]
92 [email protected]
93 [email protected]
94 [email protected]
95 [email protected] "Foo"
96 [email protected] ">"
97 [email protected] "::"
98 [email protected]
99 [email protected]
100 [email protected] "func"
101 [email protected]
102 [email protected] "("
103 [email protected] ")"
104 [email protected] ")"
105 [email protected] ";"
106 [email protected] "\n "
107 [email protected]
108 [email protected]
109 [email protected]
110 [email protected]
111 [email protected]
112 [email protected]
113 [email protected] "f"
114 [email protected]
115 [email protected] "("
116 [email protected]
117 [email protected]
118 [email protected]
119 [email protected]
120 [email protected]
121 [email protected] "<"
122 [email protected]
123 [email protected]
124 [email protected]
125 [email protected]
126 [email protected] "Foo"
127 [email protected] " "
128 [email protected] "as"
129 [email protected] " "
130 [email protected]
131 [email protected]
132 [email protected]
133 [email protected]
134 [email protected] "Trait"
135 [email protected] ">"
136 [email protected] "::"
137 [email protected]
138 [email protected]
139 [email protected] "func"
140 [email protected]
141 [email protected] "("
142 [email protected] ")"
143 [email protected] ")"
144 [email protected] ";"
145 [email protected] "\n"
146 [email protected] "}"
147 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rs b/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rs
new file mode 100644
index 000000000..ffbf46d6d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0042_call_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 let _ = f();
3 let _ = f()(1)(1, 2,);
4 let _ = f(<Foo>::func());
5 f(<Foo as Trait>::func());
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rast b/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rast
new file mode 100644
index 000000000..60b517230
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rast
@@ -0,0 +1,138 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected]
10 [email protected] "some"
11 [email protected] "::"
12 [email protected]
13 [email protected]
14 [email protected] "path"
15 [email protected] " "
16 [email protected]
17 [email protected] "as"
18 [email protected] " "
19 [email protected]
20 [email protected] "some_name"
21 [email protected] ";"
22 [email protected] "\n"
23 [email protected]
24 [email protected] "use"
25 [email protected] " "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "some"
31 [email protected] "::"
32 [email protected]
33 [email protected] "{"
34 [email protected] "\n "
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "other"
41 [email protected] "::"
42 [email protected]
43 [email protected]
44 [email protected] "path"
45 [email protected] " "
46 [email protected]
47 [email protected] "as"
48 [email protected] " "
49 [email protected]
50 [email protected] "some_other_name"
51 [email protected] ","
52 [email protected] "\n "
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected] "different"
59 [email protected] "::"
60 [email protected]
61 [email protected]
62 [email protected] "path"
63 [email protected] " "
64 [email protected]
65 [email protected] "as"
66 [email protected] " "
67 [email protected]
68 [email protected] "different_name"
69 [email protected] ","
70 [email protected] "\n "
71 [email protected]
72 [email protected]
73 [email protected]
74 [email protected]
75 [email protected]
76 [email protected]
77 [email protected] "yet"
78 [email protected] "::"
79 [email protected]
80 [email protected]
81 [email protected] "another"
82 [email protected] "::"
83 [email protected]
84 [email protected]
85 [email protected] "path"
86 [email protected] ","
87 [email protected] "\n "
88 [email protected]
89 [email protected]
90 [email protected]
91 [email protected]
92 [email protected]
93 [email protected]
94 [email protected]
95 [email protected]
96 [email protected]
97 [email protected] "running"
98 [email protected] "::"
99 [email protected]
100 [email protected]
101 [email protected] "out"
102 [email protected] "::"
103 [email protected]
104 [email protected]
105 [email protected] "of"
106 [email protected] "::"
107 [email protected]
108 [email protected]
109 [email protected] "synonyms"
110 [email protected] "::"
111 [email protected]
112 [email protected]
113 [email protected] "for_"
114 [email protected] "::"
115 [email protected]
116 [email protected]
117 [email protected] "different"
118 [email protected] "::"
119 [email protected] "*"
120 [email protected] "\n"
121 [email protected] "}"
122 [email protected] ";"
123 [email protected] "\n"
124 [email protected]
125 [email protected] "use"
126 [email protected] " "
127 [email protected]
128 [email protected]
129 [email protected]
130 [email protected]
131 [email protected] "Trait"
132 [email protected] " "
133 [email protected]
134 [email protected] "as"
135 [email protected] " "
136 [email protected] "_"
137 [email protected] ";"
138 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rs b/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rs
new file mode 100644
index 000000000..9be50f877
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0043_use_alias.rs
@@ -0,0 +1,8 @@
1use some::path as some_name;
2use some::{
3 other::path as some_other_name,
4 different::path as different_name,
5 yet::another::path,
6 running::out::of::synonyms::for_::different::*
7};
8use Trait as _;
diff --git a/crates/syntax/test_data/parser/inline/ok/0044_block_items.rast b/crates/syntax/test_data/parser/inline/ok/0044_block_items.rast
new file mode 100644
index 000000000..1fd3cd0e7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0044_block_items.rast
@@ -0,0 +1,28 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "a"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected] "fn"
16 [email protected] " "
17 [email protected]
18 [email protected] "b"
19 [email protected]
20 [email protected] "("
21 [email protected] ")"
22 [email protected] " "
23 [email protected]
24 [email protected] "{"
25 [email protected] "}"
26 [email protected] " "
27 [email protected] "}"
28 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0044_block_items.rs b/crates/syntax/test_data/parser/inline/ok/0044_block_items.rs
new file mode 100644
index 000000000..d9868718c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0044_block_items.rs
@@ -0,0 +1 @@
fn a() { fn b() {} }
diff --git a/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rast b/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rast
new file mode 100644
index 000000000..6baea6e3c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rast
@@ -0,0 +1,46 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "F"
12 [email protected] ":"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "FnMut"
21 [email protected]
22 [email protected] "("
23 [email protected]
24 [email protected]
25 [email protected] "&"
26 [email protected] "mut"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "Foo"
33 [email protected]
34 [email protected] "<"
35 [email protected]
36 [email protected] "\'a"
37 [email protected] ">"
38 [email protected] ")"
39 [email protected] ">"
40 [email protected]
41 [email protected] "("
42 [email protected] ")"
43 [email protected]
44 [email protected] "{"
45 [email protected] "}"
46 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rs b/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rs
new file mode 100644
index 000000000..9b93442c0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0045_param_list_opt_patterns.rs
@@ -0,0 +1 @@
fn foo<F: FnMut(&mut Foo<'a>)>(){}
diff --git a/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rast b/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rast
new file mode 100644
index 000000000..e89284c14
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rast
@@ -0,0 +1,20 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "("
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected] "i32"
17 [email protected] ","
18 [email protected] ")"
19 [email protected] ";"
20 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rs b/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rs
new file mode 100644
index 000000000..cb66bad24
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0046_singleton_tuple_type.rs
@@ -0,0 +1 @@
type T = (i32,);
diff --git a/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rast b/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rast
new file mode 100644
index 000000000..4d8404e7c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rast
@@ -0,0 +1,81 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "->"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "Box"
19 [email protected]
20 [email protected] "<"
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "T"
30 [email protected] " "
31 [email protected] "+"
32 [email protected] " "
33 [email protected]
34 [email protected] "\'f"
35 [email protected] ">"
36 [email protected] " "
37 [email protected]
38 [email protected] "{"
39 [email protected] "}"
40 [email protected] "\n"
41 [email protected]
42 [email protected] "fn"
43 [email protected] " "
44 [email protected]
45 [email protected] "foo"
46 [email protected]
47 [email protected] "("
48 [email protected] ")"
49 [email protected] " "
50 [email protected]
51 [email protected] "->"
52 [email protected] " "
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected]
57 [email protected] "Box"
58 [email protected]
59 [email protected] "<"
60 [email protected]
61 [email protected]
62 [email protected] "dyn"
63 [email protected] " "
64 [email protected]
65 [email protected]
66 [email protected]
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected] "T"
71 [email protected] " "
72 [email protected] "+"
73 [email protected] " "
74 [email protected]
75 [email protected] "\'f"
76 [email protected] ">"
77 [email protected] " "
78 [email protected]
79 [email protected] "{"
80 [email protected] "}"
81 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rs b/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rs
new file mode 100644
index 000000000..4bb0f63b7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0048_path_type_with_bounds.rs
@@ -0,0 +1,2 @@
1fn foo() -> Box<T + 'f> {}
2fn foo() -> Box<dyn T + 'f> {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rast b/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rast
new file mode 100644
index 000000000..a5bf55131
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rast
@@ -0,0 +1,22 @@
1[email protected]
2 [email protected]
3 [email protected] "trait"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] " "
11 [email protected]
12 [email protected] "fn"
13 [email protected] " "
14 [email protected]
15 [email protected] "foo"
16 [email protected]
17 [email protected] "("
18 [email protected] ")"
19 [email protected] ";"
20 [email protected] " "
21 [email protected] "}"
22 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rs b/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rs
new file mode 100644
index 000000000..c9f74f7f5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0050_fn_decl.rs
@@ -0,0 +1 @@
trait T { fn foo(); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rast b/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rast
new file mode 100644
index 000000000..6330dbf9e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rast
@@ -0,0 +1,14 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "("
12 [email protected] ")"
13 [email protected] ";"
14 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rs b/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rs
new file mode 100644
index 000000000..c039cf7d3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0051_unit_type.rs
@@ -0,0 +1 @@
type T = ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0052_path_type.rast b/crates/syntax/test_data/parser/inline/ok/0052_path_type.rast
new file mode 100644
index 000000000..9bc36bea7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0052_path_type.rast
@@ -0,0 +1,70 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "Foo"
15 [email protected] ";"
16 [email protected] "\n"
17 [email protected]
18 [email protected] "type"
19 [email protected] " "
20 [email protected]
21 [email protected] "B"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected] "::"
29 [email protected]
30 [email protected] "Foo"
31 [email protected] ";"
32 [email protected] "\n"
33 [email protected]
34 [email protected] "type"
35 [email protected] " "
36 [email protected]
37 [email protected] "C"
38 [email protected] " "
39 [email protected] "="
40 [email protected] " "
41 [email protected]
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected] "self"
46 [email protected] "::"
47 [email protected]
48 [email protected]
49 [email protected] "Foo"
50 [email protected] ";"
51 [email protected] "\n"
52 [email protected]
53 [email protected] "type"
54 [email protected] " "
55 [email protected]
56 [email protected] "D"
57 [email protected] " "
58 [email protected] "="
59 [email protected] " "
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected] "super"
65 [email protected] "::"
66 [email protected]
67 [email protected]
68 [email protected] "Foo"
69 [email protected] ";"
70 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0052_path_type.rs b/crates/syntax/test_data/parser/inline/ok/0052_path_type.rs
new file mode 100644
index 000000000..bf94f32e1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0052_path_type.rs
@@ -0,0 +1,4 @@
1type A = Foo;
2type B = ::Foo;
3type C = self::Foo;
4type D = super::Foo;
diff --git a/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rast b/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rast
new file mode 100644
index 000000000..c34cfeb31
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rast
@@ -0,0 +1,95 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected] "a"
27 [email protected] ";"
28 [email protected] "\n "
29 [email protected]
30 [email protected] "let"
31 [email protected] " "
32 [email protected]
33 [email protected] "_"
34 [email protected] " "
35 [email protected] "="
36 [email protected] " "
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "a"
43 [email protected] "::"
44 [email protected]
45 [email protected]
46 [email protected] "b"
47 [email protected] ";"
48 [email protected] "\n "
49 [email protected]
50 [email protected] "let"
51 [email protected] " "
52 [email protected]
53 [email protected] "_"
54 [email protected] " "
55 [email protected] "="
56 [email protected] " "
57 [email protected]
58 [email protected]
59 [email protected]
60 [email protected] "::"
61 [email protected]
62 [email protected] "a"
63 [email protected]
64 [email protected] "::"
65 [email protected] "<"
66 [email protected]
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected] "b"
72 [email protected] ">"
73 [email protected] ";"
74 [email protected] "\n "
75 [email protected]
76 [email protected] "let"
77 [email protected] " "
78 [email protected]
79 [email protected] "_"
80 [email protected] " "
81 [email protected] "="
82 [email protected] " "
83 [email protected]
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected] "format"
88 [email protected] "!"
89 [email protected]
90 [email protected] "("
91 [email protected] ")"
92 [email protected] ";"
93 [email protected] "\n"
94 [email protected] "}"
95 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rs b/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rs
new file mode 100644
index 000000000..333ebabef
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0053_path_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 let _ = a;
3 let _ = a::b;
4 let _ = ::a::<b>;
5 let _ = format!();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rast b/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rast
new file mode 100644
index 000000000..9ae271817
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rast
@@ -0,0 +1,44 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "S"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] "\n "
11 [email protected]
12 [email protected]
13 [email protected] "#"
14 [email protected] "["
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "serde"
19 [email protected]
20 [email protected] "("
21 [email protected] "with"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected] "\"url_serde\""
26 [email protected] ")"
27 [email protected] "]"
28 [email protected] "\n "
29 [email protected]
30 [email protected] "pub"
31 [email protected] " "
32 [email protected]
33 [email protected] "uri"
34 [email protected] ":"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "Uri"
41 [email protected] ","
42 [email protected] "\n"
43 [email protected] "}"
44 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rs b/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rs
new file mode 100644
index 000000000..4744d8ac0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0054_record_field_attrs.rs
@@ -0,0 +1,4 @@
1struct S {
2 #[serde(with = "url_serde")]
3 pub uri: Uri,
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rast b/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rast
new file mode 100644
index 000000000..68bb43852
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rast
@@ -0,0 +1,76 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "-"
27 [email protected]
28 [email protected] "1"
29 [email protected] " "
30 [email protected] "=>"
31 [email protected] " "
32 [email protected]
33 [email protected] "("
34 [email protected] ")"
35 [email protected] ","
36 [email protected] "\n "
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "92"
41 [email protected] " "
42 [email protected] "=>"
43 [email protected] " "
44 [email protected]
45 [email protected] "("
46 [email protected] ")"
47 [email protected] ","
48 [email protected] "\n "
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected] "\'c\'"
53 [email protected] " "
54 [email protected] "=>"
55 [email protected] " "
56 [email protected]
57 [email protected] "("
58 [email protected] ")"
59 [email protected] ","
60 [email protected] "\n "
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected] "\"hello\""
65 [email protected] " "
66 [email protected] "=>"
67 [email protected] " "
68 [email protected]
69 [email protected] "("
70 [email protected] ")"
71 [email protected] ","
72 [email protected] "\n "
73 [email protected] "}"
74 [email protected] "\n"
75 [email protected] "}"
76 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rs b/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rs
new file mode 100644
index 000000000..6dfd67b4c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0055_literal_pattern.rs
@@ -0,0 +1,8 @@
1fn main() {
2 match () {
3 -1 => (),
4 92 => (),
5 'c' => (),
6 "hello" => (),
7 }
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rast b/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rast
new file mode 100644
index 000000000..28129c50c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rast
@@ -0,0 +1,110 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] "\n"
11 [email protected]
12 [email protected] "where"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "\'a"
16 [email protected] ":"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "\'b"
21 [email protected] " "
22 [email protected] "+"
23 [email protected] " "
24 [email protected]
25 [email protected] "\'c"
26 [email protected] ","
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected] "T"
34 [email protected] ":"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "Clone"
43 [email protected] " "
44 [email protected] "+"
45 [email protected] " "
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected] "Copy"
52 [email protected] " "
53 [email protected] "+"
54 [email protected] " "
55 [email protected]
56 [email protected] "\'static"
57 [email protected] ","
58 [email protected] "\n "
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected]
65 [email protected] "Iterator"
66 [email protected] "::"
67 [email protected]
68 [email protected]
69 [email protected] "Item"
70 [email protected] ":"
71 [email protected] " "
72 [email protected]
73 [email protected]
74 [email protected] "\'a"
75 [email protected] ","
76 [email protected] "\n "
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "<"
83 [email protected]
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected] "T"
88 [email protected] " "
89 [email protected] "as"
90 [email protected] " "
91 [email protected]
92 [email protected]
93 [email protected]
94 [email protected]
95 [email protected] "Iterator"
96 [email protected] ">"
97 [email protected] "::"
98 [email protected]
99 [email protected]
100 [email protected] "Item"
101 [email protected] ":"
102 [email protected] " "
103 [email protected]
104 [email protected]
105 [email protected] "\'a"
106 [email protected] "\n"
107 [email protected]
108 [email protected] "{"
109 [email protected] "}"
110 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rs b/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rs
new file mode 100644
index 000000000..19d7e571b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0056_where_clause.rs
@@ -0,0 +1,7 @@
1fn foo()
2where
3 'a: 'b + 'c,
4 T: Clone + Copy + 'static,
5 Iterator::Item: 'a,
6 <T as Iterator>::Item: 'a
7{}
diff --git a/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rast b/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rast
new file mode 100644
index 000000000..3e72f9671
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rast
@@ -0,0 +1,82 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "92"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] "\n "
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected] "0"
28 [email protected] " "
29 [email protected] "..."
30 [email protected] " "
31 [email protected]
32 [email protected]
33 [email protected] "100"
34 [email protected] " "
35 [email protected] "=>"
36 [email protected] " "
37 [email protected]
38 [email protected] "("
39 [email protected] ")"
40 [email protected] ","
41 [email protected] "\n "
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected] "101"
47 [email protected] " "
48 [email protected] "..="
49 [email protected] " "
50 [email protected]
51 [email protected]
52 [email protected] "200"
53 [email protected] " "
54 [email protected] "=>"
55 [email protected] " "
56 [email protected]
57 [email protected] "("
58 [email protected] ")"
59 [email protected] ","
60 [email protected] "\n "
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected]
65 [email protected] "200"
66 [email protected] " "
67 [email protected] ".."
68 [email protected] " "
69 [email protected]
70 [email protected]
71 [email protected] "301"
72 [email protected] "=>"
73 [email protected] " "
74 [email protected]
75 [email protected] "("
76 [email protected] ")"
77 [email protected] ","
78 [email protected] "\n "
79 [email protected] "}"
80 [email protected] "\n"
81 [email protected] "}"
82 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rs b/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rs
new file mode 100644
index 000000000..c12ab6fce
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0058_range_pat.rs
@@ -0,0 +1,7 @@
1fn main() {
2 match 92 {
3 0 ... 100 => (),
4 101 ..= 200 => (),
5 200 .. 301=> (),
6 }
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rast b/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rast
new file mode 100644
index 000000000..984829317
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rast
@@ -0,0 +1,58 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "_"
27 [email protected] " "
28 [email protected] "=>"
29 [email protected] " "
30 [email protected]
31 [email protected] "("
32 [email protected] ")"
33 [email protected] ","
34 [email protected] "\n "
35 [email protected]
36 [email protected]
37 [email protected] "_"
38 [email protected] " "
39 [email protected] "=>"
40 [email protected] " "
41 [email protected]
42 [email protected] "{"
43 [email protected] "}"
44 [email protected] "\n "
45 [email protected]
46 [email protected]
47 [email protected] "_"
48 [email protected] " "
49 [email protected] "=>"
50 [email protected] " "
51 [email protected]
52 [email protected] "("
53 [email protected] ")"
54 [email protected] "\n "
55 [email protected] "}"
56 [email protected] "\n"
57 [email protected] "}"
58 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rs b/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rs
new file mode 100644
index 000000000..1f25d577a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0059_match_arms_commas.rs
@@ -0,0 +1,7 @@
1fn foo() {
2 match () {
3 _ => (),
4 _ => {}
5 _ => ()
6 }
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rast b/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rast
new file mode 100644
index 000000000..25e1777d1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rast
@@ -0,0 +1,10 @@
1[email protected]
2 [email protected]
3 [email protected] "extern"
4 [email protected] " "
5 [email protected] "crate"
6 [email protected] " "
7 [email protected]
8 [email protected] "foo"
9 [email protected] ";"
10 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rs b/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rs
new file mode 100644
index 000000000..49af74e1b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0060_extern_crate.rs
@@ -0,0 +1 @@
extern crate foo;
diff --git a/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rast b/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rast
new file mode 100644
index 000000000..a9ae1aa59
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rast
@@ -0,0 +1,124 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "S"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "}"
24 [email protected] ";"
25 [email protected] "\n "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected] "S"
32 [email protected] " "
33 [email protected]
34 [email protected] "{"
35 [email protected] " "
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "x"
42 [email protected] ","
43 [email protected] " "
44 [email protected]
45 [email protected]
46 [email protected] "y"
47 [email protected] ":"
48 [email protected] " "
49 [email protected]
50 [email protected] "32"
51 [email protected] ","
52 [email protected] " "
53 [email protected] "}"
54 [email protected] ";"
55 [email protected] "\n "
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected] "S"
62 [email protected] " "
63 [email protected]
64 [email protected] "{"
65 [email protected] " "
66 [email protected]
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected] "x"
72 [email protected] ","
73 [email protected] " "
74 [email protected]
75 [email protected]
76 [email protected] "y"
77 [email protected] ":"
78 [email protected] " "
79 [email protected]
80 [email protected] "32"
81 [email protected] ","
82 [email protected] " "
83 [email protected] ".."
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected] "Default"
91 [email protected] "::"
92 [email protected]
93 [email protected]
94 [email protected] "default"
95 [email protected]
96 [email protected] "("
97 [email protected] ")"
98 [email protected] " "
99 [email protected] "}"
100 [email protected] ";"
101 [email protected] "\n "
102 [email protected]
103 [email protected]
104 [email protected]
105 [email protected]
106 [email protected]
107 [email protected] "TupleStruct"
108 [email protected] " "
109 [email protected]
110 [email protected] "{"
111 [email protected] " "
112 [email protected]
113 [email protected]
114 [email protected] "0"
115 [email protected] ":"
116 [email protected] " "
117 [email protected]
118 [email protected] "1"
119 [email protected] " "
120 [email protected] "}"
121 [email protected] ";"
122 [email protected] "\n"
123 [email protected] "}"
124 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rs b/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rs
new file mode 100644
index 000000000..6285e5549
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0061_record_lit.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 S {};
3 S { x, y: 32, };
4 S { x, y: 32, ..Default::default() };
5 TupleStruct { 0: 1 };
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rast b/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rast
new file mode 100644
index 000000000..de8217064
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rast
@@ -0,0 +1,66 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "macro_rules"
20 [email protected] "!"
21 [email protected] " "
22 [email protected]
23 [email protected] "foo"
24 [email protected] " "
25 [email protected]
26 [email protected] "{"
27 [email protected] "}"
28 [email protected] "\n"
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "foo"
35 [email protected] "::"
36 [email protected]
37 [email protected]
38 [email protected] "bar"
39 [email protected] "!"
40 [email protected]
41 [email protected] "("
42 [email protected] ")"
43 [email protected] ";"
44 [email protected] "\n"
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "super"
50 [email protected] "::"
51 [email protected]
52 [email protected]
53 [email protected] "baz"
54 [email protected] "!"
55 [email protected] " "
56 [email protected]
57 [email protected] "{"
58 [email protected] "}"
59 [email protected] "\n"
60 [email protected]
61 [email protected] "struct"
62 [email protected] " "
63 [email protected]
64 [email protected] "S"
65 [email protected] ";"
66 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rs b/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rs
new file mode 100644
index 000000000..24a15c5c5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0062_mod_contents.rs
@@ -0,0 +1,5 @@
1fn foo() {}
2macro_rules! foo {}
3foo::bar!();
4super::baz! {}
5struct S;
diff --git a/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast b/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast
new file mode 100644
index 000000000..4368930cc
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rast
@@ -0,0 +1,23 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected] "!"
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected]
10 [email protected] "Send"
11 [email protected] " "
12 [email protected] "for"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "X"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] "}"
23 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs b/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs
new file mode 100644
index 000000000..b7527c870
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0063_impl_def_neg.rs
@@ -0,0 +1 @@
impl !Send for X {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rast b/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rast
new file mode 100644
index 000000000..587160003
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rast
@@ -0,0 +1,121 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "if"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "true"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] ";"
26 [email protected] "\n "
27 [email protected]
28 [email protected]
29 [email protected] "if"
30 [email protected] " "
31 [email protected]
32 [email protected]
33 [email protected] "true"
34 [email protected] " "
35 [email protected]
36 [email protected] "{"
37 [email protected] "}"
38 [email protected] " "
39 [email protected] "else"
40 [email protected] " "
41 [email protected]
42 [email protected] "{"
43 [email protected] "}"
44 [email protected] ";"
45 [email protected] "\n "
46 [email protected]
47 [email protected]
48 [email protected] "if"
49 [email protected] " "
50 [email protected]
51 [email protected]
52 [email protected] "true"
53 [email protected] " "
54 [email protected]
55 [email protected] "{"
56 [email protected] "}"
57 [email protected] " "
58 [email protected] "else"
59 [email protected] " "
60 [email protected]
61 [email protected] "if"
62 [email protected] " "
63 [email protected]
64 [email protected]
65 [email protected] "false"
66 [email protected] " "
67 [email protected]
68 [email protected] "{"
69 [email protected] "}"
70 [email protected] " "
71 [email protected] "else"
72 [email protected] " "
73 [email protected]
74 [email protected] "{"
75 [email protected] "}"
76 [email protected] ";"
77 [email protected] "\n "
78 [email protected]
79 [email protected]
80 [email protected] "if"
81 [email protected] " "
82 [email protected]
83 [email protected]
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected] "S"
88 [email protected] " "
89 [email protected]
90 [email protected] "{"
91 [email protected] "}"
92 [email protected] ";"
93 [email protected] "\n "
94 [email protected]
95 [email protected]
96 [email protected] "if"
97 [email protected] " "
98 [email protected]
99 [email protected]
100 [email protected] "{"
101 [email protected] " "
102 [email protected]
103 [email protected] "true"
104 [email protected] " "
105 [email protected] "}"
106 [email protected] " "
107 [email protected]
108 [email protected] "{"
109 [email protected] " "
110 [email protected] "}"
111 [email protected] " "
112 [email protected] "else"
113 [email protected] " "
114 [email protected]
115 [email protected] "{"
116 [email protected] " "
117 [email protected] "}"
118 [email protected] ";"
119 [email protected] "\n"
120 [email protected] "}"
121 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rs b/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rs
new file mode 100644
index 000000000..40f227ba3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0064_if_expr.rs
@@ -0,0 +1,7 @@
1fn foo() {
2 if true {};
3 if true {} else {};
4 if true {} else if false {} else {};
5 if S {};
6 if { true } { } else { };
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rast b/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rast
new file mode 100644
index 000000000..3a7fcfe24
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rast
@@ -0,0 +1,43 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "dyn"
12 [email protected] " "
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "Iterator"
20 [email protected]
21 [email protected] "<"
22 [email protected]
23 [email protected]
24 [email protected] "Item"
25 [email protected] "="
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "Foo"
31 [email protected]
32 [email protected] "<"
33 [email protected]
34 [email protected] "\'a"
35 [email protected] ">"
36 [email protected] ">"
37 [email protected] " "
38 [email protected] "+"
39 [email protected] " "
40 [email protected]
41 [email protected] "\'a"
42 [email protected] ";"
43 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rs b/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rs
new file mode 100644
index 000000000..c3ecabb99
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0065_dyn_trait_type.rs
@@ -0,0 +1 @@
type A = dyn Iterator<Item=Foo<'a>> + 'a;
diff --git a/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rast b/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rast
new file mode 100644
index 000000000..57d0661a5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rast
@@ -0,0 +1,151 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "match"
17 [email protected] " "
18 [email protected]
19 [email protected] "("
20 [email protected] ")"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected] "_"
28 [email protected] " "
29 [email protected] "=>"
30 [email protected] " "
31 [email protected]
32 [email protected] "("
33 [email protected] ")"
34 [email protected] ","
35 [email protected] "\n "
36 [email protected]
37 [email protected]
38 [email protected] "_"
39 [email protected] " "
40 [email protected]
41 [email protected] "if"
42 [email protected] " "
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected] "Test"
49 [email protected] " "
50 [email protected] ">"
51 [email protected] " "
52 [email protected]
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected] "Test"
57 [email protected]
58 [email protected] "{"
59 [email protected]
60 [email protected]
61 [email protected] "field"
62 [email protected] ":"
63 [email protected] " "
64 [email protected]
65 [email protected] "0"
66 [email protected] "}"
67 [email protected] " "
68 [email protected] "=>"
69 [email protected] " "
70 [email protected]
71 [email protected] "("
72 [email protected] ")"
73 [email protected] ","
74 [email protected] "\n "
75 [email protected]
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected] "X"
80 [email protected] " "
81 [email protected] "|"
82 [email protected] " "
83 [email protected]
84 [email protected]
85 [email protected] "Y"
86 [email protected] " "
87 [email protected]
88 [email protected] "if"
89 [email protected] " "
90 [email protected]
91 [email protected]
92 [email protected]
93 [email protected]
94 [email protected] "Z"
95 [email protected] " "
96 [email protected] "=>"
97 [email protected] " "
98 [email protected]
99 [email protected] "("
100 [email protected] ")"
101 [email protected] ","
102 [email protected] "\n "
103 [email protected]
104 [email protected] "|"
105 [email protected] " "
106 [email protected]
107 [email protected]
108 [email protected]
109 [email protected] "X"
110 [email protected] " "
111 [email protected] "|"
112 [email protected] " "
113 [email protected]
114 [email protected]
115 [email protected] "Y"
116 [email protected] " "
117 [email protected]
118 [email protected] "if"
119 [email protected] " "
120 [email protected]
121 [email protected]
122 [email protected]
123 [email protected]
124 [email protected] "Z"
125 [email protected] " "
126 [email protected] "=>"
127 [email protected] " "
128 [email protected]
129 [email protected] "("
130 [email protected] ")"
131 [email protected] ","
132 [email protected] "\n "
133 [email protected]
134 [email protected] "|"
135 [email protected] " "
136 [email protected]
137 [email protected]
138 [email protected] "X"
139 [email protected] " "
140 [email protected] "=>"
141 [email protected] " "
142 [email protected]
143 [email protected] "("
144 [email protected] ")"
145 [email protected] ","
146 [email protected] "\n "
147 [email protected] "}"
148 [email protected] ";"
149 [email protected] "\n"
150 [email protected] "}"
151 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rs b/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rs
new file mode 100644
index 000000000..9e009e24f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0066_match_arm.rs
@@ -0,0 +1,9 @@
1fn foo() {
2 match () {
3 _ => (),
4 _ if Test > Test{field: 0} => (),
5 X | Y if Z => (),
6 | X | Y if Z => (),
7 | X => (),
8 };
9}
diff --git a/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rast b/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rast
new file mode 100644
index 000000000..702f2e0b0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rast
@@ -0,0 +1,15 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "crate"
10 [email protected] "::"
11 [email protected]
12 [email protected]
13 [email protected] "foo"
14 [email protected] ";"
15 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rs b/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rs
new file mode 100644
index 000000000..1bbb5930b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0067_crate_path.rs
@@ -0,0 +1 @@
use crate::foo;
diff --git a/crates/syntax/test_data/parser/inline/ok/0068_union_items.rast b/crates/syntax/test_data/parser/inline/ok/0068_union_items.rast
new file mode 100644
index 000000000..6589e4795
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0068_union_items.rast
@@ -0,0 +1,46 @@
1[email protected]
2 [email protected]
3 [email protected] "union"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] "}"
11 [email protected] "\n"
12 [email protected]
13 [email protected] "union"
14 [email protected] " "
15 [email protected]
16 [email protected] "Foo"
17 [email protected] " "
18 [email protected]
19 [email protected] "{"
20 [email protected] "\n "
21 [email protected]
22 [email protected]
23 [email protected] "a"
24 [email protected] ":"
25 [email protected] " "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "i32"
31 [email protected] ","
32 [email protected] "\n "
33 [email protected]
34 [email protected]
35 [email protected] "b"
36 [email protected] ":"
37 [email protected] " "
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "f32"
43 [email protected] ","
44 [email protected] "\n"
45 [email protected] "}"
46 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0068_union_items.rs b/crates/syntax/test_data/parser/inline/ok/0068_union_items.rs
new file mode 100644
index 000000000..b7dd610d8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0068_union_items.rs
@@ -0,0 +1,5 @@
1union Foo {}
2union Foo {
3 a: i32,
4 b: f32,
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rast b/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rast
new file mode 100644
index 000000000..c4c5bc51e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rast
@@ -0,0 +1,37 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected] "crate"
9 [email protected] "::"
10 [email protected]
11 [email protected] "{"
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected] "Item"
17 [email protected] "}"
18 [email protected] ";"
19 [email protected] "\n"
20 [email protected]
21 [email protected] "use"
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected]
26 [email protected] "self"
27 [email protected] "::"
28 [email protected]
29 [email protected] "{"
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "Item"
35 [email protected] "}"
36 [email protected] ";"
37 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rs b/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rs
new file mode 100644
index 000000000..c0a3d634e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0069_use_tree_list_after_path.rs
@@ -0,0 +1,2 @@
1use crate::{Item};
2use self::{Item};
diff --git a/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rast b/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rast
new file mode 100644
index 000000000..36c9cd5bb
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rast
@@ -0,0 +1,50 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected]
24 [email protected] "{"
25 [email protected]
26 [email protected] "1"
27 [email protected] "}"
28 [email protected] " "
29 [email protected] "&"
30 [email protected] " "
31 [email protected]
32 [email protected] "2"
33 [email protected] ";"
34 [email protected] "\n "
35 [email protected]
36 [email protected]
37 [email protected] "{"
38 [email protected]
39 [email protected] "1"
40 [email protected] "}"
41 [email protected] " "
42 [email protected]
43 [email protected]
44 [email protected] "&"
45 [email protected]
46 [email protected] "2"
47 [email protected] ";"
48 [email protected] "\n"
49 [email protected] "}"
50 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs b/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs
new file mode 100644
index 000000000..37b843742
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0070_stmt_bin_expr_ambiguity.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 let _ = {1} & 2;
3 {1} &2;
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rast b/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rast
new file mode 100644
index 000000000..d34d98ced
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rast
@@ -0,0 +1,93 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "match"
17 [email protected] " "
18 [email protected]
19 [email protected] "("
20 [email protected] ")"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] " "
25 [email protected] "}"
26 [email protected] ";"
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected] "match"
31 [email protected] " "
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "S"
37 [email protected] " "
38 [email protected]
39 [email protected] "{"
40 [email protected] "}"
41 [email protected] ";"
42 [email protected] "\n "
43 [email protected]
44 [email protected]
45 [email protected] "match"
46 [email protected] " "
47 [email protected]
48 [email protected] "{"
49 [email protected] " "
50 [email protected] "}"
51 [email protected] " "
52 [email protected]
53 [email protected] "{"
54 [email protected] " "
55 [email protected]
56 [email protected]
57 [email protected] "_"
58 [email protected] " "
59 [email protected] "=>"
60 [email protected] " "
61 [email protected]
62 [email protected] "("
63 [email protected] ")"
64 [email protected] " "
65 [email protected] "}"
66 [email protected] ";"
67 [email protected] "\n "
68 [email protected]
69 [email protected]
70 [email protected] "match"
71 [email protected] " "
72 [email protected]
73 [email protected] "{"
74 [email protected] " "
75 [email protected]
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected] "S"
80 [email protected] " "
81 [email protected]
82 [email protected] "{"
83 [email protected] "}"
84 [email protected] " "
85 [email protected] "}"
86 [email protected] " "
87 [email protected]
88 [email protected] "{"
89 [email protected] "}"
90 [email protected] ";"
91 [email protected] "\n"
92 [email protected] "}"
93 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rs b/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rs
new file mode 100644
index 000000000..c4021dc10
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0071_match_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 match () { };
3 match S {};
4 match { } { _ => () };
5 match { S {} } {};
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rast b/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rast
new file mode 100644
index 000000000..437d7ac04
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rast
@@ -0,0 +1,28 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "return"
17 [email protected] ";"
18 [email protected] "\n "
19 [email protected]
20 [email protected]
21 [email protected] "return"
22 [email protected] " "
23 [email protected]
24 [email protected] "92"
25 [email protected] ";"
26 [email protected] "\n"
27 [email protected] "}"
28 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rs b/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rs
new file mode 100644
index 000000000..5733666b6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0072_return_expr.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 return;
3 return 92;
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rast b/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rast
new file mode 100644
index 000000000..00cce69e6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rast
@@ -0,0 +1,20 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Result"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ">"
13 [email protected] " "
14 [email protected] "="
15 [email protected] " "
16 [email protected]
17 [email protected] "("
18 [email protected] ")"
19 [email protected] ";"
20 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rs b/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rs
new file mode 100644
index 000000000..defd110c4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0073_type_item_type_params.rs
@@ -0,0 +1 @@
type Result<T> = ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rast b/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rast
new file mode 100644
index 000000000..3a789b9f5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rast
@@ -0,0 +1,59 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "_"
27 [email protected] " "
28 [email protected] "=>"
29 [email protected] " "
30 [email protected]
31 [email protected] "{"
32 [email protected] "}"
33 [email protected] "\n "
34 [email protected]
35 [email protected]
36 [email protected] "("
37 [email protected] ")"
38 [email protected] " "
39 [email protected] "=>"
40 [email protected] " "
41 [email protected]
42 [email protected] "{"
43 [email protected] "}"
44 [email protected] "\n "
45 [email protected]
46 [email protected]
47 [email protected] "["
48 [email protected] "]"
49 [email protected] " "
50 [email protected] "=>"
51 [email protected] " "
52 [email protected]
53 [email protected] "{"
54 [email protected] "}"
55 [email protected] "\n "
56 [email protected] "}"
57 [email protected] "\n"
58 [email protected] "}"
59 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs b/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs
new file mode 100644
index 000000000..2edd578f9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0074_stmt_postfix_expr_ambiguity.rs
@@ -0,0 +1,7 @@
1fn foo() {
2 match () {
3 _ => {}
4 () => {}
5 [] => {}
6 }
7}
diff --git a/crates/syntax/test_data/parser/inline/ok/0075_block.rast b/crates/syntax/test_data/parser/inline/ok/0075_block.rast
new file mode 100644
index 000000000..e847ce9b2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0075_block.rast
@@ -0,0 +1,86 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "a"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
15 [email protected]
16 [email protected] "fn"
17 [email protected] " "
18 [email protected]
19 [email protected] "b"
20 [email protected]
21 [email protected] "("
22 [email protected] ")"
23 [email protected] " "
24 [email protected]
25 [email protected] "{"
26 [email protected] " "
27 [email protected]
28 [email protected] "let"
29 [email protected] " "
30 [email protected]
31 [email protected] "_"
32 [email protected] " "
33 [email protected] "="
34 [email protected] " "
35 [email protected]
36 [email protected] "1"
37 [email protected] ";"
38 [email protected] " "
39 [email protected] "}"
40 [email protected] "\n"
41 [email protected]
42 [email protected] "fn"
43 [email protected] " "
44 [email protected]
45 [email protected] "c"
46 [email protected]
47 [email protected] "("
48 [email protected] ")"
49 [email protected] " "
50 [email protected]
51 [email protected] "{"
52 [email protected] " "
53 [email protected]
54 [email protected]
55 [email protected] "1"
56 [email protected] ";"
57 [email protected] " "
58 [email protected]
59 [email protected]
60 [email protected] "2"
61 [email protected] ";"
62 [email protected] " "
63 [email protected] "}"
64 [email protected] "\n"
65 [email protected]
66 [email protected] "fn"
67 [email protected] " "
68 [email protected]
69 [email protected] "d"
70 [email protected]
71 [email protected] "("
72 [email protected] ")"
73 [email protected] " "
74 [email protected]
75 [email protected] "{"
76 [email protected] " "
77 [email protected]
78 [email protected]
79 [email protected] "1"
80 [email protected] ";"
81 [email protected] " "
82 [email protected]
83 [email protected] "2"
84 [email protected] " "
85 [email protected] "}"
86 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0075_block.rs b/crates/syntax/test_data/parser/inline/ok/0075_block.rs
new file mode 100644
index 000000000..81f44c533
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0075_block.rs
@@ -0,0 +1,4 @@
1fn a() {}
2fn b() { let _ = 1; }
3fn c() { 1; 2; }
4fn d() { 1; 2 }
diff --git a/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rast b/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rast
new file mode 100644
index 000000000..96217a7fd
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rast
@@ -0,0 +1,39 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ">"
13 [email protected]
14 [email protected] "("
15 [email protected] ")"
16 [email protected] " "
17 [email protected]
18 [email protected] "where"
19 [email protected] " "
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "T"
26 [email protected] ":"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "Copy"
35 [email protected] " "
36 [email protected]
37 [email protected] "{"
38 [email protected] "}"
39 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rs b/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rs
new file mode 100644
index 000000000..f0920b2a8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0076_function_where_clause.rs
@@ -0,0 +1 @@
fn foo<T>() where T: Copy {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rast b/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rast
new file mode 100644
index 000000000..33e6fb93f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rast
@@ -0,0 +1,25 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "x"
21 [email protected] "?"
22 [email protected] ";"
23 [email protected] "\n"
24 [email protected] "}"
25 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rs b/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rs
new file mode 100644
index 000000000..8b74f7bc8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0077_try_expr.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 x?;
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0078_type_item.rast b/crates/syntax/test_data/parser/inline/ok/0078_type_item.rast
new file mode 100644
index 000000000..2befc8388
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0078_type_item.rast
@@ -0,0 +1,16 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "Bar"
15 [email protected] ";"
16 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0078_type_item.rs b/crates/syntax/test_data/parser/inline/ok/0078_type_item.rs
new file mode 100644
index 000000000..04c0344fa
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0078_type_item.rs
@@ -0,0 +1 @@
type Foo = Bar;
diff --git a/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rast b/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rast
new file mode 100644
index 000000000..209711fc4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rast
@@ -0,0 +1,14 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "Foo"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rs b/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rs
new file mode 100644
index 000000000..d6337f6b3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0079_impl_def.rs
@@ -0,0 +1 @@
impl Foo {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rast b/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rast
new file mode 100644
index 000000000..b3003577c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rast
@@ -0,0 +1,95 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "x"
20 [email protected] " "
21 [email protected] "="
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected] "1"
26 [email protected] ".."
27 [email protected] ";"
28 [email protected] "\n "
29 [email protected]
30 [email protected]
31 [email protected] "match"
32 [email protected] " "
33 [email protected]
34 [email protected]
35 [email protected] "1"
36 [email protected] ".."
37 [email protected] " "
38 [email protected]
39 [email protected] "{"
40 [email protected] " "
41 [email protected]
42 [email protected]
43 [email protected] "_"
44 [email protected] " "
45 [email protected] "=>"
46 [email protected] " "
47 [email protected]
48 [email protected] "("
49 [email protected] ")"
50 [email protected] " "
51 [email protected] "}"
52 [email protected] ";"
53 [email protected] "\n "
54 [email protected]
55 [email protected]
56 [email protected] "match"
57 [email protected] " "
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected]
64 [email protected] "a"
65 [email protected] "."
66 [email protected]
67 [email protected] "b"
68 [email protected]
69 [email protected] "("
70 [email protected] ")"
71 [email protected] ".."
72 [email protected]
73 [email protected]
74 [email protected]
75 [email protected]
76 [email protected] "S"
77 [email protected] " "
78 [email protected]
79 [email protected] "{"
80 [email protected] " "
81 [email protected]
82 [email protected]
83 [email protected] "_"
84 [email protected] " "
85 [email protected] "=>"
86 [email protected] " "
87 [email protected]
88 [email protected] "("
89 [email protected] ")"
90 [email protected] " "
91 [email protected] "}"
92 [email protected] ";"
93 [email protected] "\n"
94 [email protected] "}"
95 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rs b/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rs
new file mode 100644
index 000000000..e7b7cfc6b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0080_postfix_range.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 let x = 1..;
3 match 1.. { _ => () };
4 match a.b()..S { _ => () };
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0081_for_type.rast b/crates/syntax/test_data/parser/inline/ok/0081_for_type.rast
new file mode 100644
index 000000000..f319d5141
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0081_for_type.rast
@@ -0,0 +1,112 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "for"
12 [email protected]
13 [email protected] "<"
14 [email protected]
15 [email protected] "\'a"
16 [email protected] ">"
17 [email protected] " "
18 [email protected]
19 [email protected] "fn"
20 [email protected]
21 [email protected] "("
22 [email protected] ")"
23 [email protected] " "
24 [email protected]
25 [email protected] "->"
26 [email protected] " "
27 [email protected]
28 [email protected] "("
29 [email protected] ")"
30 [email protected] ";"
31 [email protected] "\n"
32 [email protected]
33 [email protected] "type"
34 [email protected] " "
35 [email protected]
36 [email protected] "B"
37 [email protected] " "
38 [email protected] "="
39 [email protected] " "
40 [email protected]
41 [email protected] "for"
42 [email protected]
43 [email protected] "<"
44 [email protected]
45 [email protected] "\'a"
46 [email protected] ">"
47 [email protected] " "
48 [email protected]
49 [email protected] "unsafe"
50 [email protected] " "
51 [email protected]
52 [email protected] "extern"
53 [email protected] " "
54 [email protected] "\"C\""
55 [email protected] " "
56 [email protected] "fn"
57 [email protected]
58 [email protected] "("
59 [email protected]
60 [email protected]
61 [email protected] "&"
62 [email protected] "\'a"
63 [email protected] " "
64 [email protected]
65 [email protected] "("
66 [email protected] ")"
67 [email protected] ")"
68 [email protected] " "
69 [email protected]
70 [email protected] "->"
71 [email protected] " "
72 [email protected]
73 [email protected] "("
74 [email protected] ")"
75 [email protected] ";"
76 [email protected] "\n"
77 [email protected]
78 [email protected] "type"
79 [email protected] " "
80 [email protected]
81 [email protected] "Obj"
82 [email protected] " "
83 [email protected] "="
84 [email protected] " "
85 [email protected]
86 [email protected] "for"
87 [email protected]
88 [email protected] "<"
89 [email protected]
90 [email protected] "\'a"
91 [email protected] ">"
92 [email protected] " "
93 [email protected]
94 [email protected]
95 [email protected]
96 [email protected]
97 [email protected] "PartialEq"
98 [email protected]
99 [email protected] "<"
100 [email protected]
101 [email protected]
102 [email protected] "&"
103 [email protected] "\'a"
104 [email protected] " "
105 [email protected]
106 [email protected]
107 [email protected]
108 [email protected]
109 [email protected] "i32"
110 [email protected] ">"
111 [email protected] ";"
112 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0081_for_type.rs b/crates/syntax/test_data/parser/inline/ok/0081_for_type.rs
new file mode 100644
index 000000000..8ac7b9e10
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0081_for_type.rs
@@ -0,0 +1,3 @@
1type A = for<'a> fn() -> ();
2type B = for<'a> unsafe extern "C" fn(&'a ()) -> ();
3type Obj = for<'a> PartialEq<&'a i32>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rast b/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rast
new file mode 100644
index 000000000..70b975c0b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rast
@@ -0,0 +1,138 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected] "// reference operator"
15 [email protected] "\n "
16 [email protected]
17 [email protected] "let"
18 [email protected] " "
19 [email protected]
20 [email protected] "_"
21 [email protected] " "
22 [email protected] "="
23 [email protected] " "
24 [email protected]
25 [email protected] "&"
26 [email protected]
27 [email protected] "1"
28 [email protected] ";"
29 [email protected] "\n "
30 [email protected]
31 [email protected] "let"
32 [email protected] " "
33 [email protected]
34 [email protected] "_"
35 [email protected] " "
36 [email protected] "="
37 [email protected] " "
38 [email protected]
39 [email protected] "&"
40 [email protected] "mut"
41 [email protected] " "
42 [email protected]
43 [email protected] "&"
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "f"
50 [email protected]
51 [email protected] "("
52 [email protected] ")"
53 [email protected] ";"
54 [email protected] "\n "
55 [email protected]
56 [email protected] "let"
57 [email protected] " "
58 [email protected]
59 [email protected] "_"
60 [email protected] " "
61 [email protected] "="
62 [email protected] " "
63 [email protected]
64 [email protected] "&"
65 [email protected]
66 [email protected]
67 [email protected]
68 [email protected]
69 [email protected] "raw"
70 [email protected] ";"
71 [email protected] "\n "
72 [email protected]
73 [email protected] "let"
74 [email protected] " "
75 [email protected]
76 [email protected] "_"
77 [email protected] " "
78 [email protected] "="
79 [email protected] " "
80 [email protected]
81 [email protected] "&"
82 [email protected]
83 [email protected]
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected] "raw"
88 [email protected] "."
89 [email protected]
90 [email protected] "0"
91 [email protected] ";"
92 [email protected] "\n "
93 [email protected] "// raw reference oper ..."
94 [email protected] "\n "
95 [email protected]
96 [email protected] "let"
97 [email protected] " "
98 [email protected]
99 [email protected] "_"
100 [email protected] " "
101 [email protected] "="
102 [email protected] " "
103 [email protected]
104 [email protected] "&"
105 [email protected] "raw"
106 [email protected] " "
107 [email protected] "mut"
108 [email protected] " "
109 [email protected]
110 [email protected]
111 [email protected]
112 [email protected]
113 [email protected] "foo"
114 [email protected] ";"
115 [email protected] "\n "
116 [email protected]
117 [email protected] "let"
118 [email protected] " "
119 [email protected]
120 [email protected] "_"
121 [email protected] " "
122 [email protected] "="
123 [email protected] " "
124 [email protected]
125 [email protected] "&"
126 [email protected] "raw"
127 [email protected] " "
128 [email protected] "const"
129 [email protected] " "
130 [email protected]
131 [email protected]
132 [email protected]
133 [email protected]
134 [email protected] "foo"
135 [email protected] ";"
136 [email protected] "\n"
137 [email protected] "}"
138 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rs b/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rs
new file mode 100644
index 000000000..c5262f446
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0082_ref_expr.rs
@@ -0,0 +1,10 @@
1fn foo() {
2 // reference operator
3 let _ = &1;
4 let _ = &mut &f();
5 let _ = &raw;
6 let _ = &raw.0;
7 // raw reference operator
8 let _ = &raw mut foo;
9 let _ = &raw const foo;
10}
diff --git a/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rast b/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rast
new file mode 100644
index 000000000..cdbc40fe0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rast
@@ -0,0 +1,87 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] ";"
8 [email protected] "\n"
9 [email protected]
10 [email protected] "struct"
11 [email protected] " "
12 [email protected]
13 [email protected] "Foo"
14 [email protected] " "
15 [email protected]
16 [email protected] "{"
17 [email protected] "}"
18 [email protected] "\n"
19 [email protected]
20 [email protected] "struct"
21 [email protected] " "
22 [email protected]
23 [email protected] "Foo"
24 [email protected]
25 [email protected] "("
26 [email protected] ")"
27 [email protected] ";"
28 [email protected] "\n"
29 [email protected]
30 [email protected] "struct"
31 [email protected] " "
32 [email protected]
33 [email protected] "Foo"
34 [email protected]
35 [email protected] "("
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "String"
42 [email protected] ","
43 [email protected] " "
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "usize"
50 [email protected] ")"
51 [email protected] ";"
52 [email protected] "\n"
53 [email protected]
54 [email protected] "struct"
55 [email protected] " "
56 [email protected]
57 [email protected] "Foo"
58 [email protected] " "
59 [email protected]
60 [email protected] "{"
61 [email protected] "\n "
62 [email protected]
63 [email protected]
64 [email protected] "a"
65 [email protected] ":"
66 [email protected] " "
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected] "i32"
72 [email protected] ","
73 [email protected] "\n "
74 [email protected]
75 [email protected]
76 [email protected] "b"
77 [email protected] ":"
78 [email protected] " "
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected]
83 [email protected] "f32"
84 [email protected] ","
85 [email protected] "\n"
86 [email protected] "}"
87 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rs b/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rs
new file mode 100644
index 000000000..693e3f3ee
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0083_struct_items.rs
@@ -0,0 +1,8 @@
1struct Foo;
2struct Foo {}
3struct Foo();
4struct Foo(String, usize);
5struct Foo {
6 a: i32,
7 b: f32,
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rast b/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rast
new file mode 100644
index 000000000..ee8894966
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rast
@@ -0,0 +1,19 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "("
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected] "i32"
17 [email protected] ")"
18 [email protected] ";"
19 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rs b/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rs
new file mode 100644
index 000000000..6e1b25101
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0084_paren_type.rs
@@ -0,0 +1 @@
type T = (i32);
diff --git a/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rast b/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rast
new file mode 100644
index 000000000..9a87b5b93
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rast
@@ -0,0 +1,135 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected] "true"
24 [email protected] ";"
25 [email protected] "\n "
26 [email protected]
27 [email protected] "let"
28 [email protected] " "
29 [email protected]
30 [email protected] "_"
31 [email protected] " "
32 [email protected] "="
33 [email protected] " "
34 [email protected]
35 [email protected] "false"
36 [email protected] ";"
37 [email protected] "\n "
38 [email protected]
39 [email protected] "let"
40 [email protected] " "
41 [email protected]
42 [email protected] "_"
43 [email protected] " "
44 [email protected] "="
45 [email protected] " "
46 [email protected]
47 [email protected] "1"
48 [email protected] ";"
49 [email protected] "\n "
50 [email protected]
51 [email protected] "let"
52 [email protected] " "
53 [email protected]
54 [email protected] "_"
55 [email protected] " "
56 [email protected] "="
57 [email protected] " "
58 [email protected]
59 [email protected] "2.0"
60 [email protected] ";"
61 [email protected] "\n "
62 [email protected]
63 [email protected] "let"
64 [email protected] " "
65 [email protected]
66 [email protected] "_"
67 [email protected] " "
68 [email protected] "="
69 [email protected] " "
70 [email protected]
71 [email protected] "b\'a\'"
72 [email protected] ";"
73 [email protected] "\n "
74 [email protected]
75 [email protected] "let"
76 [email protected] " "
77 [email protected]
78 [email protected] "_"
79 [email protected] " "
80 [email protected] "="
81 [email protected] " "
82 [email protected]
83 [email protected] "\'b\'"
84 [email protected] ";"
85 [email protected] "\n "
86 [email protected]
87 [email protected] "let"
88 [email protected] " "
89 [email protected]
90 [email protected] "_"
91 [email protected] " "
92 [email protected] "="
93 [email protected] " "
94 [email protected]
95 [email protected] "\"c\""
96 [email protected] ";"
97 [email protected] "\n "
98 [email protected]
99 [email protected] "let"
100 [email protected] " "
101 [email protected]
102 [email protected] "_"
103 [email protected] " "
104 [email protected] "="
105 [email protected] " "
106 [email protected]
107 [email protected] "r\"d\""
108 [email protected] ";"
109 [email protected] "\n "
110 [email protected]
111 [email protected] "let"
112 [email protected] " "
113 [email protected]
114 [email protected] "_"
115 [email protected] " "
116 [email protected] "="
117 [email protected] " "
118 [email protected]
119 [email protected] "b\"e\""
120 [email protected] ";"
121 [email protected] "\n "
122 [email protected]
123 [email protected] "let"
124 [email protected] " "
125 [email protected]
126 [email protected] "_"
127 [email protected] " "
128 [email protected] "="
129 [email protected] " "
130 [email protected]
131 [email protected] "br\"f\""
132 [email protected] ";"
133 [email protected] "\n"
134 [email protected] "}"
135 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rs b/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rs
new file mode 100644
index 000000000..2e11a5a6e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0085_expr_literals.rs
@@ -0,0 +1,12 @@
1fn foo() {
2 let _ = true;
3 let _ = false;
4 let _ = 1;
5 let _ = 2.0;
6 let _ = b'a';
7 let _ = 'b';
8 let _ = "c";
9 let _ = r"d";
10 let _ = b"e";
11 let _ = br"f";
12}
diff --git a/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rast b/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rast
new file mode 100644
index 000000000..70e05a859
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rast
@@ -0,0 +1,34 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
15 [email protected]
16 [email protected] "fn"
17 [email protected] " "
18 [email protected]
19 [email protected] "bar"
20 [email protected]
21 [email protected] "("
22 [email protected] ")"
23 [email protected] " "
24 [email protected]
25 [email protected] "->"
26 [email protected] " "
27 [email protected]
28 [email protected] "("
29 [email protected] ")"
30 [email protected] " "
31 [email protected]
32 [email protected] "{"
33 [email protected] "}"
34 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rs b/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rs
new file mode 100644
index 000000000..d22d8cada
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0086_function_ret_type.rs
@@ -0,0 +1,2 @@
1fn foo() {}
2fn bar() -> () {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rast b/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rast
new file mode 100644
index 000000000..f7b839303
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rast
@@ -0,0 +1,65 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected]
11 [email protected] "{"
12 [email protected] "\n "
13 [email protected]
14 [email protected]
15 [email protected] "if"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "break"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "}"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected] "while"
28 [email protected] " "
29 [email protected]
30 [email protected]
31 [email protected] "break"
32 [email protected] " "
33 [email protected]
34 [email protected] "{"
35 [email protected] "}"
36 [email protected] "\n "
37 [email protected]
38 [email protected]
39 [email protected] "for"
40 [email protected] " "
41 [email protected]
42 [email protected]
43 [email protected] "i"
44 [email protected] " "
45 [email protected] "in"
46 [email protected] " "
47 [email protected]
48 [email protected] "break"
49 [email protected] " "
50 [email protected]
51 [email protected] "{"
52 [email protected] "}"
53 [email protected] "\n "
54 [email protected]
55 [email protected] "match"
56 [email protected] " "
57 [email protected]
58 [email protected] "break"
59 [email protected] " "
60 [email protected]
61 [email protected] "{"
62 [email protected] "}"
63 [email protected] "\n"
64 [email protected] "}"
65 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rs b/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rs
new file mode 100644
index 000000000..560eb05b9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0088_break_ambiguity.rs
@@ -0,0 +1,6 @@
1fn foo(){
2 if break {}
3 while break {}
4 for i in break {}
5 match break {}
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rast b/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rast
new file mode 100644
index 000000000..2ef026e37
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rast
@@ -0,0 +1,22 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "S"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] " "
13 [email protected] "="
14 [email protected] " "
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "i32"
20 [email protected] ">"
21 [email protected] ";"
22 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rs b/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rs
new file mode 100644
index 000000000..540eacb02
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0090_type_param_default.rs
@@ -0,0 +1 @@
struct S<T = i32>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rast b/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rast
new file mode 100644
index 000000000..f80326465
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rast
@@ -0,0 +1,23 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "F"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "fn"
12 [email protected]
13 [email protected] "("
14 [email protected] ")"
15 [email protected] " "
16 [email protected]
17 [email protected] "->"
18 [email protected] " "
19 [email protected]
20 [email protected] "("
21 [email protected] ")"
22 [email protected] ";"
23 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs b/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs
new file mode 100644
index 000000000..e3ba5e87f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0092_fn_pointer_type_with_ret.rs
@@ -0,0 +1 @@
type F = fn() -> ();
diff --git a/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rast b/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rast
new file mode 100644
index 000000000..82f03f9c1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rast
@@ -0,0 +1,33 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "x"
22 [email protected] "["
23 [email protected]
24 [email protected] "1"
25 [email protected] "]"
26 [email protected] "["
27 [email protected]
28 [email protected] "2"
29 [email protected] "]"
30 [email protected] ";"
31 [email protected] "\n"
32 [email protected] "}"
33 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rs b/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rs
new file mode 100644
index 000000000..b9ba78a6c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0093_index_expr.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 x[1][2];
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rast b/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rast
new file mode 100644
index 000000000..c1fdc6e25
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rast
@@ -0,0 +1,28 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected] "("
24 [email protected] ")"
25 [email protected] ";"
26 [email protected] " "
27 [email protected] "}"
28 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rs b/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rs
new file mode 100644
index 000000000..4d719c433
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0095_placeholder_pat.rs
@@ -0,0 +1 @@
fn main() { let _ = (); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rast b/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rast
new file mode 100644
index 000000000..e757249f0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rast
@@ -0,0 +1,123 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "if"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "true"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] "\n "
26 [email protected]
27 [email protected]
28 [email protected] "loop"
29 [email protected] " "
30 [email protected]
31 [email protected] "{"
32 [email protected] "}"
33 [email protected] "\n "
34 [email protected]
35 [email protected]
36 [email protected] "match"
37 [email protected] " "
38 [email protected]
39 [email protected] "("
40 [email protected] ")"
41 [email protected] " "
42 [email protected]
43 [email protected] "{"
44 [email protected] "}"
45 [email protected] "\n "
46 [email protected]
47 [email protected]
48 [email protected] "while"
49 [email protected] " "
50 [email protected]
51 [email protected]
52 [email protected] "true"
53 [email protected] " "
54 [email protected]
55 [email protected] "{"
56 [email protected] "}"
57 [email protected] "\n "
58 [email protected]
59 [email protected]
60 [email protected] "for"
61 [email protected] " "
62 [email protected]
63 [email protected] "_"
64 [email protected] " "
65 [email protected] "in"
66 [email protected] " "
67 [email protected]
68 [email protected] "("
69 [email protected] ")"
70 [email protected] " "
71 [email protected]
72 [email protected] "{"
73 [email protected] "}"
74 [email protected] "\n "
75 [email protected]
76 [email protected]
77 [email protected] "{"
78 [email protected] "}"
79 [email protected] "\n "
80 [email protected]
81 [email protected]
82 [email protected] "{"
83 [email protected] "}"
84 [email protected] "\n "
85 [email protected]
86 [email protected]
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected] "macro_rules"
91 [email protected] "!"
92 [email protected] " "
93 [email protected]
94 [email protected] "test"
95 [email protected] " "
96 [email protected]
97 [email protected] "{"
98 [email protected] "\n "
99 [email protected]
100 [email protected] "("
101 [email protected] ")"
102 [email protected] " "
103 [email protected] "="
104 [email protected] ">"
105 [email protected] " "
106 [email protected]
107 [email protected] "{"
108 [email protected] "}"
109 [email protected] "\n "
110 [email protected] "}"
111 [email protected] "\n "
112 [email protected]
113 [email protected]
114 [email protected]
115 [email protected]
116 [email protected] "test"
117 [email protected] "!"
118 [email protected]
119 [email protected] "{"
120 [email protected] "}"
121 [email protected] "\n"
122 [email protected] "}"
123 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rs b/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rs
new file mode 100644
index 000000000..4919665cb
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0096_no_semi_after_block.rs
@@ -0,0 +1,13 @@
1fn foo() {
2 if true {}
3 loop {}
4 match () {}
5 while true {}
6 for _ in () {}
7 {}
8 {}
9 macro_rules! test {
10 () => {}
11 }
12 test!{}
13}
diff --git a/crates/syntax/test_data/parser/inline/ok/0099_param_list.rast b/crates/syntax/test_data/parser/inline/ok/0099_param_list.rast
new file mode 100644
index 000000000..f19e9fd52
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0099_param_list.rast
@@ -0,0 +1,99 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "a"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
15 [email protected]
16 [email protected] "fn"
17 [email protected] " "
18 [email protected]
19 [email protected] "b"
20 [email protected]
21 [email protected] "("
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "x"
26 [email protected] ":"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "i32"
33 [email protected] ")"
34 [email protected] " "
35 [email protected]
36 [email protected] "{"
37 [email protected] "}"
38 [email protected] "\n"
39 [email protected]
40 [email protected] "fn"
41 [email protected] " "
42 [email protected]
43 [email protected] "c"
44 [email protected]
45 [email protected] "("
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "x"
50 [email protected] ":"
51 [email protected] " "
52 [email protected]
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected] "i32"
57 [email protected] ","
58 [email protected] " "
59 [email protected] ")"
60 [email protected] " "
61 [email protected]
62 [email protected] "{"
63 [email protected] "}"
64 [email protected] "\n"
65 [email protected]
66 [email protected] "fn"
67 [email protected] " "
68 [email protected]
69 [email protected] "d"
70 [email protected]
71 [email protected] "("
72 [email protected]
73 [email protected]
74 [email protected]
75 [email protected] "x"
76 [email protected] ":"
77 [email protected] " "
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "i32"
83 [email protected] ","
84 [email protected] " "
85 [email protected]
86 [email protected]
87 [email protected]
88 [email protected] "y"
89 [email protected] ":"
90 [email protected] " "
91 [email protected]
92 [email protected] "("
93 [email protected] ")"
94 [email protected] ")"
95 [email protected] " "
96 [email protected]
97 [email protected] "{"
98 [email protected] "}"
99 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0099_param_list.rs b/crates/syntax/test_data/parser/inline/ok/0099_param_list.rs
new file mode 100644
index 000000000..9d55bedbb
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0099_param_list.rs
@@ -0,0 +1,4 @@
1fn a() {}
2fn b(x: i32) {}
3fn c(x: i32, ) {}
4fn d(x: i32, y: ()) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rast b/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rast
new file mode 100644
index 000000000..5c4055e44
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rast
@@ -0,0 +1,34 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "for"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "x"
21 [email protected] " "
22 [email protected] "in"
23 [email protected] " "
24 [email protected]
25 [email protected] "["
26 [email protected] "]"
27 [email protected] " "
28 [email protected]
29 [email protected] "{"
30 [email protected] "}"
31 [email protected] ";"
32 [email protected] "\n"
33 [email protected] "}"
34 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rs b/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rs
new file mode 100644
index 000000000..972197d2a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0100_for_expr.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 for x in [] {};
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rast b/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rast
new file mode 100644
index 000000000..866e60ed8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rast
@@ -0,0 +1,132 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "S"
22 [email protected] " "
23 [email protected]
24 [email protected] "{"
25 [email protected] "}"
26 [email protected] " "
27 [email protected] "="
28 [email protected] " "
29 [email protected]
30 [email protected] "("
31 [email protected] ")"
32 [email protected] ";"
33 [email protected] "\n "
34 [email protected]
35 [email protected] "let"
36 [email protected] " "
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "S"
42 [email protected] " "
43 [email protected]
44 [email protected] "{"
45 [email protected] " "
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "f"
50 [email protected] ","
51 [email protected] " "
52 [email protected]
53 [email protected]
54 [email protected] "ref"
55 [email protected] " "
56 [email protected] "mut"
57 [email protected] " "
58 [email protected]
59 [email protected] "g"
60 [email protected] " "
61 [email protected] "}"
62 [email protected] " "
63 [email protected] "="
64 [email protected] " "
65 [email protected]
66 [email protected] "("
67 [email protected] ")"
68 [email protected] ";"
69 [email protected] "\n "
70 [email protected]
71 [email protected] "let"
72 [email protected] " "
73 [email protected]
74 [email protected]
75 [email protected]
76 [email protected]
77 [email protected] "S"
78 [email protected] " "
79 [email protected]
80 [email protected] "{"
81 [email protected] " "
82 [email protected]
83 [email protected]
84 [email protected] "h"
85 [email protected] ":"
86 [email protected] " "
87 [email protected]
88 [email protected] "_"
89 [email protected] ","
90 [email protected] " "
91 [email protected] ".."
92 [email protected] "}"
93 [email protected] " "
94 [email protected] "="
95 [email protected] " "
96 [email protected]
97 [email protected] "("
98 [email protected] ")"
99 [email protected] ";"
100 [email protected] "\n "
101 [email protected]
102 [email protected] "let"
103 [email protected] " "
104 [email protected]
105 [email protected]
106 [email protected]
107 [email protected]
108 [email protected] "S"
109 [email protected] " "
110 [email protected]
111 [email protected] "{"
112 [email protected] " "
113 [email protected]
114 [email protected]
115 [email protected] "h"
116 [email protected] ":"
117 [email protected] " "
118 [email protected]
119 [email protected] "_"
120 [email protected] ","
121 [email protected] " "
122 [email protected] "}"
123 [email protected] " "
124 [email protected] "="
125 [email protected] " "
126 [email protected]
127 [email protected] "("
128 [email protected] ")"
129 [email protected] ";"
130 [email protected] "\n"
131 [email protected] "}"
132 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rs b/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rs
new file mode 100644
index 000000000..da3412fa8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0102_record_field_pat_list.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 let S {} = ();
3 let S { f, ref mut g } = ();
4 let S { h: _, ..} = ();
5 let S { h: _, } = ();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rast b/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rast
new file mode 100644
index 000000000..c4c0a0568
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rast
@@ -0,0 +1,54 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "["
17 [email protected] "]"
18 [email protected] ";"
19 [email protected] "\n "
20 [email protected]
21 [email protected]
22 [email protected] "["
23 [email protected]
24 [email protected] "1"
25 [email protected] "]"
26 [email protected] ";"
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected] "["
31 [email protected]
32 [email protected] "1"
33 [email protected] ","
34 [email protected] " "
35 [email protected]
36 [email protected] "2"
37 [email protected] ","
38 [email protected] "]"
39 [email protected] ";"
40 [email protected] "\n "
41 [email protected]
42 [email protected]
43 [email protected] "["
44 [email protected]
45 [email protected] "1"
46 [email protected] ";"
47 [email protected] " "
48 [email protected]
49 [email protected] "2"
50 [email protected] "]"
51 [email protected] ";"
52 [email protected] "\n"
53 [email protected] "}"
54 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rs b/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rs
new file mode 100644
index 000000000..4dc1999d1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0103_array_expr.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 [];
3 [1];
4 [1, 2,];
5 [1; 2];
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rast b/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rast
new file mode 100644
index 000000000..1244a5031
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rast
@@ -0,0 +1,41 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "F"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "Box"
15 [email protected]
16 [email protected] "<"
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "Fn"
23 [email protected]
24 [email protected] "("
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "i32"
31 [email protected] ")"
32 [email protected] " "
33 [email protected]
34 [email protected] "->"
35 [email protected] " "
36 [email protected]
37 [email protected] "("
38 [email protected] ")"
39 [email protected] ">"
40 [email protected] ";"
41 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rs b/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rs
new file mode 100644
index 000000000..17ed20e5b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0104_path_fn_trait_args.rs
@@ -0,0 +1 @@
type F = Box<Fn(i32) -> ()>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rast b/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rast
new file mode 100644
index 000000000..9b8381619
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rast
@@ -0,0 +1,135 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "|"
18 [email protected] "|"
19 [email protected] " "
20 [email protected]
21 [email protected] "("
22 [email protected] ")"
23 [email protected] ";"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected] "|"
29 [email protected] "|"
30 [email protected] " "
31 [email protected]
32 [email protected] "->"
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected] "i32"
39 [email protected] " "
40 [email protected]
41 [email protected] "{"
42 [email protected] " "
43 [email protected]
44 [email protected] "92"
45 [email protected] " "
46 [email protected] "}"
47 [email protected] ";"
48 [email protected] "\n "
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected] "|"
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected] "x"
57 [email protected] "|"
58 [email protected] " "
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected]
63 [email protected] "x"
64 [email protected] ";"
65 [email protected] "\n "
66 [email protected]
67 [email protected]
68 [email protected] "move"
69 [email protected] " "
70 [email protected]
71 [email protected] "|"
72 [email protected]
73 [email protected]
74 [email protected]
75 [email protected] "x"
76 [email protected] ":"
77 [email protected] " "
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "i32"
83 [email protected] ","
84 [email protected] "|"
85 [email protected] " "
86 [email protected]
87 [email protected]
88 [email protected]
89 [email protected]
90 [email protected] "x"
91 [email protected] ";"
92 [email protected] "\n "
93 [email protected]
94 [email protected]
95 [email protected] "async"
96 [email protected] " "
97 [email protected]
98 [email protected] "|"
99 [email protected] "|"
100 [email protected] " "
101 [email protected]
102 [email protected] "{"
103 [email protected] "}"
104 [email protected] ";"
105 [email protected] "\n "
106 [email protected]
107 [email protected]
108 [email protected] "move"
109 [email protected] " "
110 [email protected]
111 [email protected] "|"
112 [email protected] "|"
113 [email protected] " "
114 [email protected]
115 [email protected] "{"
116 [email protected] "}"
117 [email protected] ";"
118 [email protected] "\n "
119 [email protected]
120 [email protected]
121 [email protected] "async"
122 [email protected] " "
123 [email protected] "move"
124 [email protected] " "
125 [email protected]
126 [email protected] "|"
127 [email protected] "|"
128 [email protected] " "
129 [email protected]
130 [email protected] "{"
131 [email protected] "}"
132 [email protected] ";"
133 [email protected] "\n"
134 [email protected] "}"
135 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rs b/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rs
new file mode 100644
index 000000000..075717823
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0106_lambda_expr.rs
@@ -0,0 +1,9 @@
1fn foo() {
2 || ();
3 || -> i32 { 92 };
4 |x| x;
5 move |x: i32,| x;
6 async || {};
7 move || {};
8 async move || {};
9}
diff --git a/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rast b/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rast
new file mode 100644
index 000000000..be8365e05
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rast
@@ -0,0 +1,62 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "x"
21 [email protected] "."
22 [email protected]
23 [email protected] "foo"
24 [email protected]
25 [email protected] "("
26 [email protected] ")"
27 [email protected] ";"
28 [email protected] "\n "
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected] "y"
36 [email protected] "."
37 [email protected]
38 [email protected] "bar"
39 [email protected]
40 [email protected] "::"
41 [email protected] "<"
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected] "T"
48 [email protected] ">"
49 [email protected]
50 [email protected] "("
51 [email protected]
52 [email protected] "1"
53 [email protected] ","
54 [email protected] " "
55 [email protected]
56 [email protected] "2"
57 [email protected] ","
58 [email protected] ")"
59 [email protected] ";"
60 [email protected] "\n"
61 [email protected] "}"
62 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rs b/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rs
new file mode 100644
index 000000000..1a3aa35ae
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0107_method_call_expr.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 x.foo();
3 y.bar::<T>(1, 2,);
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rast b/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rast
new file mode 100644
index 000000000..ca7e4a5c3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rast
@@ -0,0 +1,38 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "("
17 [email protected] ")"
18 [email protected] ";"
19 [email protected] "\n "
20 [email protected]
21 [email protected]
22 [email protected] "("
23 [email protected]
24 [email protected] "1"
25 [email protected] ")"
26 [email protected] ";"
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected] "("
31 [email protected]
32 [email protected] "1"
33 [email protected] ","
34 [email protected] ")"
35 [email protected] ";"
36 [email protected] "\n"
37 [email protected] "}"
38 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rs b/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rs
new file mode 100644
index 000000000..e4f774280
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0108_tuple_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 ();
3 (1);
4 (1,);
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0109_label.rast b/crates/syntax/test_data/parser/inline/ok/0109_label.rast
new file mode 100644
index 000000000..c9588025c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0109_label.rast
@@ -0,0 +1,64 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "\'a"
18 [email protected] ":"
19 [email protected] " "
20 [email protected] "loop"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] "\n "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "\'b"
30 [email protected] ":"
31 [email protected] " "
32 [email protected] "while"
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected] "true"
37 [email protected] " "
38 [email protected]
39 [email protected] "{"
40 [email protected] "}"
41 [email protected] "\n "
42 [email protected]
43 [email protected]
44 [email protected] "\'c"
45 [email protected] ":"
46 [email protected] " "
47 [email protected] "for"
48 [email protected] " "
49 [email protected]
50 [email protected]
51 [email protected] "x"
52 [email protected] " "
53 [email protected] "in"
54 [email protected] " "
55 [email protected]
56 [email protected] "("
57 [email protected] ")"
58 [email protected] " "
59 [email protected]
60 [email protected] "{"
61 [email protected] "}"
62 [email protected] "\n"
63 [email protected] "}"
64 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0109_label.rs b/crates/syntax/test_data/parser/inline/ok/0109_label.rs
new file mode 100644
index 000000000..48e83f263
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0109_label.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 'a: loop {}
3 'b: while true {}
4 'c: for x in () {}
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0110_use_path.rast b/crates/syntax/test_data/parser/inline/ok/0110_use_path.rast
new file mode 100644
index 000000000..82028096f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0110_use_path.rast
@@ -0,0 +1,38 @@
1[email protected]
2 [email protected]
3 [email protected] "use"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected] "::"
9 [email protected]
10 [email protected] "crate_name"
11 [email protected] ";"
12 [email protected] " "
13 [email protected] "// Rust 2018 - All fl ..."
14 [email protected] "\n"
15 [email protected]
16 [email protected] "use"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "crate_name"
23 [email protected] ";"
24 [email protected] " "
25 [email protected] "// Rust 2018 - Anchor ..."
26 [email protected] "\n"
27 [email protected]
28 [email protected] "use"
29 [email protected] " "
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "item_in_scope_or_crat ..."
35 [email protected] ";"
36 [email protected] " "
37 [email protected] "// Rust 2018 - Unifor ..."
38 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0110_use_path.rs b/crates/syntax/test_data/parser/inline/ok/0110_use_path.rs
new file mode 100644
index 000000000..328e94736
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0110_use_path.rs
@@ -0,0 +1,3 @@
1use ::crate_name; // Rust 2018 - All flavours
2use crate_name; // Rust 2018 - Anchored paths
3use item_in_scope_or_crate_name; // Rust 2018 - Uniform Paths
diff --git a/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rast b/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rast
new file mode 100644
index 000000000..b82ed0230
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rast
@@ -0,0 +1,89 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected]
20 [email protected]
21 [email protected] "a"
22 [email protected] ","
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected] "b"
27 [email protected] ","
28 [email protected] " "
29 [email protected]
30 [email protected] ".."
31 [email protected] ")"
32 [email protected] " "
33 [email protected] "="
34 [email protected] " "
35 [email protected]
36 [email protected] "("
37 [email protected] ")"
38 [email protected] ";"
39 [email protected] "\n "
40 [email protected]
41 [email protected] "let"
42 [email protected] " "
43 [email protected]
44 [email protected] "("
45 [email protected]
46 [email protected]
47 [email protected] "a"
48 [email protected] ","
49 [email protected] ")"
50 [email protected] " "
51 [email protected] "="
52 [email protected] " "
53 [email protected]
54 [email protected] "("
55 [email protected] ")"
56 [email protected] ";"
57 [email protected] "\n "
58 [email protected]
59 [email protected] "let"
60 [email protected] " "
61 [email protected]
62 [email protected] "("
63 [email protected]
64 [email protected] ".."
65 [email protected] ")"
66 [email protected] " "
67 [email protected] "="
68 [email protected] " "
69 [email protected]
70 [email protected] "("
71 [email protected] ")"
72 [email protected] ";"
73 [email protected] "\n "
74 [email protected]
75 [email protected] "let"
76 [email protected] " "
77 [email protected]
78 [email protected] "("
79 [email protected] ")"
80 [email protected] " "
81 [email protected] "="
82 [email protected] " "
83 [email protected]
84 [email protected] "("
85 [email protected] ")"
86 [email protected] ";"
87 [email protected] "\n"
88 [email protected] "}"
89 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rs b/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rs
new file mode 100644
index 000000000..ba719879d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0111_tuple_pat.rs
@@ -0,0 +1,6 @@
1fn main() {
2 let (a, b, ..) = ();
3 let (a,) = ();
4 let (..) = ();
5 let () = ();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rast b/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rast
new file mode 100644
index 000000000..7b9a498c8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rast
@@ -0,0 +1,127 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "a"
20 [email protected] " "
21 [email protected] "="
22 [email protected] " "
23 [email protected]
24 [email protected] "("
25 [email protected] ")"
26 [email protected] ";"
27 [email protected] "\n "
28 [email protected]
29 [email protected] "let"
30 [email protected] " "
31 [email protected]
32 [email protected] "mut"
33 [email protected] " "
34 [email protected]
35 [email protected] "b"
36 [email protected] " "
37 [email protected] "="
38 [email protected] " "
39 [email protected]
40 [email protected] "("
41 [email protected] ")"
42 [email protected] ";"
43 [email protected] "\n "
44 [email protected]
45 [email protected] "let"
46 [email protected] " "
47 [email protected]
48 [email protected] "ref"
49 [email protected] " "
50 [email protected]
51 [email protected] "c"
52 [email protected] " "
53 [email protected] "="
54 [email protected] " "
55 [email protected]
56 [email protected] "("
57 [email protected] ")"
58 [email protected] ";"
59 [email protected] "\n "
60 [email protected]
61 [email protected] "let"
62 [email protected] " "
63 [email protected]
64 [email protected] "ref"
65 [email protected] " "
66 [email protected] "mut"
67 [email protected] " "
68 [email protected]
69 [email protected] "d"
70 [email protected] " "
71 [email protected] "="
72 [email protected] " "
73 [email protected]
74 [email protected] "("
75 [email protected] ")"
76 [email protected] ";"
77 [email protected] "\n "
78 [email protected]
79 [email protected] "let"
80 [email protected] " "
81 [email protected]
82 [email protected]
83 [email protected] "e"
84 [email protected] " "
85 [email protected] "@"
86 [email protected] " "
87 [email protected]
88 [email protected] "_"
89 [email protected] " "
90 [email protected] "="
91 [email protected] " "
92 [email protected]
93 [email protected] "("
94 [email protected] ")"
95 [email protected] ";"
96 [email protected] "\n "
97 [email protected]
98 [email protected] "let"
99 [email protected] " "
100 [email protected]
101 [email protected] "ref"
102 [email protected] " "
103 [email protected] "mut"
104 [email protected] " "
105 [email protected]
106 [email protected] "f"
107 [email protected] " "
108 [email protected] "@"
109 [email protected] " "
110 [email protected]
111 [email protected]
112 [email protected] "g"
113 [email protected] " "
114 [email protected] "@"
115 [email protected] " "
116 [email protected]
117 [email protected] "_"
118 [email protected] " "
119 [email protected] "="
120 [email protected] " "
121 [email protected]
122 [email protected] "("
123 [email protected] ")"
124 [email protected] ";"
125 [email protected] "\n"
126 [email protected] "}"
127 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rs b/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rs
new file mode 100644
index 000000000..820a9e72c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0112_bind_pat.rs
@@ -0,0 +1,8 @@
1fn main() {
2 let a = ();
3 let mut b = ();
4 let ref c = ();
5 let ref mut d = ();
6 let e @ _ = ();
7 let ref mut f @ g @ _ = ();
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rast b/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rast
new file mode 100644
index 000000000..d761c1c68
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rast
@@ -0,0 +1,55 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected]
11 [email protected] "{"
12 [email protected] "\n "
13 [email protected] ";"
14 [email protected] ";"
15 [email protected] ";"
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "some_expr"
23 [email protected]
24 [email protected] "("
25 [email protected] ")"
26 [email protected] ";"
27 [email protected] ";"
28 [email protected] ";"
29 [email protected] ";"
30 [email protected]
31 [email protected]
32 [email protected] "{"
33 [email protected] ";"
34 [email protected] ";"
35 [email protected] ";"
36 [email protected] "}"
37 [email protected] ";"
38 [email protected] ";"
39 [email protected] ";"
40 [email protected] ";"
41 [email protected]
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected] "Ok"
47 [email protected]
48 [email protected] "("
49 [email protected]
50 [email protected] "("
51 [email protected] ")"
52 [email protected] ")"
53 [email protected] "\n"
54 [email protected] "}"
55 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rs b/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rs
new file mode 100644
index 000000000..bbf09e367
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0113_nocontentexpr.rs
@@ -0,0 +1,3 @@
1fn foo(){
2 ;;;some_expr();;;;{;;;};;;;Ok(())
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rast b/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rast
new file mode 100644
index 000000000..0e1594dc4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rast
@@ -0,0 +1,64 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "Test"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ">"
13 [email protected]
14 [email protected] "("
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "T"
21 [email protected] ")"
22 [email protected] " "
23 [email protected]
24 [email protected] "where"
25 [email protected] " "
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected] "T"
32 [email protected] ":"
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected] "Clone"
41 [email protected] ";"
42 [email protected] "\n"
43 [email protected]
44 [email protected] "struct"
45 [email protected] " "
46 [email protected]
47 [email protected] "Test"
48 [email protected]
49 [email protected] "<"
50 [email protected]
51 [email protected]
52 [email protected] "T"
53 [email protected] ">"
54 [email protected]
55 [email protected] "("
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected] "T"
62 [email protected] ")"
63 [email protected] ";"
64 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rs b/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rs
new file mode 100644
index 000000000..ddd59016d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0114_tuple_struct_where.rs
@@ -0,0 +1,2 @@
1struct Test<T>(T) where T: Clone;
2struct Test<T>(T);
diff --git a/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rast b/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rast
new file mode 100644
index 000000000..4d09c9f50
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rast
@@ -0,0 +1,41 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "S"
7 [email protected] " "
8 [email protected]
9 [email protected] "("
10 [email protected] "\n "
11 [email protected]
12 [email protected]
13 [email protected] "#"
14 [email protected] "["
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "serde"
19 [email protected]
20 [email protected] "("
21 [email protected] "with"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected] "\"url_serde\""
26 [email protected] ")"
27 [email protected] "]"
28 [email protected] "\n "
29 [email protected]
30 [email protected] "pub"
31 [email protected] " "
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "Uri"
37 [email protected] ","
38 [email protected] "\n"
39 [email protected] ")"
40 [email protected] ";"
41 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rs b/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rs
new file mode 100644
index 000000000..635b9ac21
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0115_tuple_field_attrs.rs
@@ -0,0 +1,4 @@
1struct S (
2 #[serde(with = "url_serde")]
3 pub Uri,
4);
diff --git a/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rast b/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rast
new file mode 100644
index 000000000..f3d4ad72c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rast
@@ -0,0 +1,43 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected] "foo"
15 [email protected] "!"
16 [email protected]
17 [email protected] "("
18 [email protected] ")"
19 [email protected] ";"
20 [email protected] "\n"
21 [email protected]
22 [email protected] "type"
23 [email protected] " "
24 [email protected]
25 [email protected] "B"
26 [email protected] " "
27 [email protected] "="
28 [email protected] " "
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected] "crate"
34 [email protected] "::"
35 [email protected]
36 [email protected]
37 [email protected] "foo"
38 [email protected] "!"
39 [email protected]
40 [email protected] "("
41 [email protected] ")"
42 [email protected] ";"
43 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rs b/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rs
new file mode 100644
index 000000000..edb470c89
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0117_macro_call_type.rs
@@ -0,0 +1,2 @@
1type A = foo!();
2type B = crate::foo!();
diff --git a/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast b/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast
new file mode 100644
index 000000000..141a7b203
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rast
@@ -0,0 +1,40 @@
1[email protected]
2 [email protected]
3 [email protected] "enum"
4 [email protected] " "
5 [email protected]
6 [email protected] "F"
7 [email protected]
8 [email protected] "{"
9 [email protected] "}"
10 [email protected] "\n"
11 [email protected]
12 [email protected] "impl"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "F"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] "\n "
23 [email protected] "//! This is a doc com ..."
24 [email protected] "\n "
25 [email protected]
26 [email protected] "#"
27 [email protected] "!"
28 [email protected] "["
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "doc"
33 [email protected]
34 [email protected] "("
35 [email protected] "\"This is also a doc c ..."
36 [email protected] ")"
37 [email protected] "]"
38 [email protected] "\n"
39 [email protected] "}"
40 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rs b/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rs
new file mode 100644
index 000000000..4d68cceb7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0118_impl_inner_attributes.rs
@@ -0,0 +1,5 @@
1enum F{}
2impl F {
3 //! This is a doc comment
4 #![doc("This is also a doc comment")]
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rast b/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rast
new file mode 100644
index 000000000..0cf4eb0a5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rast
@@ -0,0 +1,47 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "_"
27 [email protected] " "
28 [email protected]
29 [email protected] "if"
30 [email protected] " "
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected] "foo"
36 [email protected] " "
37 [email protected] "=>"
38 [email protected] " "
39 [email protected]
40 [email protected] "("
41 [email protected] ")"
42 [email protected] ","
43 [email protected] "\n "
44 [email protected] "}"
45 [email protected] "\n"
46 [email protected] "}"
47 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rs b/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rs
new file mode 100644
index 000000000..f1bd72fc4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0118_match_guard.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 match () {
3 _ if foo => (),
4 }
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rast b/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rast
new file mode 100644
index 000000000..ec7a00f1d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rast
@@ -0,0 +1,80 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected] "#"
26 [email protected] "!"
27 [email protected] "["
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected] "doc"
32 [email protected]
33 [email protected] "("
34 [email protected] "\"Inner attribute\""
35 [email protected] ")"
36 [email protected] "]"
37 [email protected] "\n "
38 [email protected]
39 [email protected] "#"
40 [email protected] "!"
41 [email protected] "["
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected] "doc"
46 [email protected]
47 [email protected] "("
48 [email protected] "\"Can be\""
49 [email protected] ")"
50 [email protected] "]"
51 [email protected] "\n "
52 [email protected]
53 [email protected] "#"
54 [email protected] "!"
55 [email protected] "["
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected] "doc"
60 [email protected]
61 [email protected] "("
62 [email protected] "\"Stacked\""
63 [email protected] ")"
64 [email protected] "]"
65 [email protected] "\n "
66 [email protected]
67 [email protected]
68 [email protected] "_"
69 [email protected] " "
70 [email protected] "=>"
71 [email protected] " "
72 [email protected]
73 [email protected] "("
74 [email protected] ")"
75 [email protected] ","
76 [email protected] "\n "
77 [email protected] "}"
78 [email protected] "\n"
79 [email protected] "}"
80 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rs b/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rs
new file mode 100644
index 000000000..54a67c9d7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0120_match_arms_inner_attribute.rs
@@ -0,0 +1,8 @@
1fn foo() {
2 match () {
3 #![doc("Inner attribute")]
4 #![doc("Can be")]
5 #![doc("Stacked")]
6 _ => (),
7 }
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rast b/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rast
new file mode 100644
index 000000000..97924da05
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rast
@@ -0,0 +1,145 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "#"
27 [email protected] "["
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected] "cfg"
32 [email protected]
33 [email protected] "("
34 [email protected] "feature"
35 [email protected] " "
36 [email protected] "="
37 [email protected] " "
38 [email protected] "\"some\""
39 [email protected] ")"
40 [email protected] "]"
41 [email protected] "\n "
42 [email protected]
43 [email protected] "_"
44 [email protected] " "
45 [email protected] "=>"
46 [email protected] " "
47 [email protected]
48 [email protected] "("
49 [email protected] ")"
50 [email protected] ","
51 [email protected] "\n "
52 [email protected]
53 [email protected]
54 [email protected] "#"
55 [email protected] "["
56 [email protected]
57 [email protected]
58 [email protected]
59 [email protected] "cfg"
60 [email protected]
61 [email protected] "("
62 [email protected] "feature"
63 [email protected] " "
64 [email protected] "="
65 [email protected] " "
66 [email protected] "\"other\""
67 [email protected] ")"
68 [email protected] "]"
69 [email protected] "\n "
70 [email protected]
71 [email protected] "_"
72 [email protected] " "
73 [email protected] "=>"
74 [email protected] " "
75 [email protected]
76 [email protected] "("
77 [email protected] ")"
78 [email protected] ","
79 [email protected] "\n "
80 [email protected]
81 [email protected]
82 [email protected] "#"
83 [email protected] "["
84 [email protected]
85 [email protected]
86 [email protected]
87 [email protected] "cfg"
88 [email protected]
89 [email protected] "("
90 [email protected] "feature"
91 [email protected] " "
92 [email protected] "="
93 [email protected] " "
94 [email protected] "\"many\""
95 [email protected] ")"
96 [email protected] "]"
97 [email protected] "\n "
98 [email protected]
99 [email protected] "#"
100 [email protected] "["
101 [email protected]
102 [email protected]
103 [email protected]
104 [email protected] "cfg"
105 [email protected]
106 [email protected] "("
107 [email protected] "feature"
108 [email protected] " "
109 [email protected] "="
110 [email protected] " "
111 [email protected] "\"attributes\""
112 [email protected] ")"
113 [email protected] "]"
114 [email protected] "\n "
115 [email protected]
116 [email protected] "#"
117 [email protected] "["
118 [email protected]
119 [email protected]
120 [email protected]
121 [email protected] "cfg"
122 [email protected]
123 [email protected] "("
124 [email protected] "feature"
125 [email protected] " "
126 [email protected] "="
127 [email protected] " "
128 [email protected] "\"before\""
129 [email protected] ")"
130 [email protected] "]"
131 [email protected] "\n "
132 [email protected]
133 [email protected] "_"
134 [email protected] " "
135 [email protected] "=>"
136 [email protected] " "
137 [email protected]
138 [email protected] "("
139 [email protected] ")"
140 [email protected] ","
141 [email protected] "\n "
142 [email protected] "}"
143 [email protected] "\n"
144 [email protected] "}"
145 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rs b/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rs
new file mode 100644
index 000000000..676db42d1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0121_match_arms_outer_attributes.rs
@@ -0,0 +1,12 @@
1fn foo() {
2 match () {
3 #[cfg(feature = "some")]
4 _ => (),
5 #[cfg(feature = "other")]
6 _ => (),
7 #[cfg(feature = "many")]
8 #[cfg(feature = "attributes")]
9 #[cfg(feature = "before")]
10 _ => (),
11 }
12}
diff --git a/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rast b/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rast
new file mode 100644
index 000000000..570b95205
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rast
@@ -0,0 +1,65 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "#"
12 [email protected] "["
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected] "derive"
17 [email protected]
18 [email protected] "("
19 [email protected] "Lifetime"
20 [email protected] ")"
21 [email protected] "]"
22 [email protected] " "
23 [email protected] "\'a"
24 [email protected] ","
25 [email protected] " "
26 [email protected]
27 [email protected]
28 [email protected] "#"
29 [email protected] "["
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected] "derive"
34 [email protected]
35 [email protected] "("
36 [email protected] "Type"
37 [email protected] ")"
38 [email protected] "]"
39 [email protected] " "
40 [email protected]
41 [email protected] "T"
42 [email protected] ">"
43 [email protected]
44 [email protected] "("
45 [email protected]
46 [email protected]
47 [email protected] "_"
48 [email protected] ":"
49 [email protected] " "
50 [email protected]
51 [email protected] "&"
52 [email protected] "\'a"
53 [email protected] " "
54 [email protected]
55 [email protected]
56 [email protected]
57 [email protected]
58 [email protected] "T"
59 [email protected] ")"
60 [email protected] " "
61 [email protected]
62 [email protected] "{"
63 [email protected] "\n"
64 [email protected] "}"
65 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rs b/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rs
new file mode 100644
index 000000000..e8fdf741f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0122_generic_lifetime_type_attribute.rs
@@ -0,0 +1,2 @@
1fn foo<#[derive(Lifetime)] 'a, #[derive(Type)] T>(_: &'a T) {
2}
diff --git a/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rast b/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rast
new file mode 100644
index 000000000..7cdec6634
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rast
@@ -0,0 +1,50 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected] "extern"
5 [email protected] " "
6 [email protected] "\"C\""
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] " "
11 [email protected]
12 [email protected] "fn"
13 [email protected] " "
14 [email protected]
15 [email protected] "printf"
16 [email protected]
17 [email protected] "("
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "format"
22 [email protected] ":"
23 [email protected] " "
24 [email protected]
25 [email protected] "*"
26 [email protected] "const"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "i8"
33 [email protected] ","
34 [email protected] " "
35 [email protected]
36 [email protected] "..."
37 [email protected] ")"
38 [email protected] " "
39 [email protected]
40 [email protected] "->"
41 [email protected] " "
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected] "i32"
47 [email protected] ";"
48 [email protected] " "
49 [email protected] "}"
50 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rs b/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rs
new file mode 100644
index 000000000..c59addaf4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0123_param_list_vararg.rs
@@ -0,0 +1 @@
extern "C" { fn printf(format: *const i8, ...) -> i32; }
diff --git a/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rast b/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rast
new file mode 100644
index 000000000..aa4d7a784
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rast
@@ -0,0 +1,31 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "crate"
21 [email protected] "::"
22 [email protected]
23 [email protected]
24 [email protected] "foo"
25 [email protected]
26 [email protected] "("
27 [email protected] ")"
28 [email protected] ";"
29 [email protected] " "
30 [email protected] "}"
31 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rs b/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rs
new file mode 100644
index 000000000..0f454d121
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0125_crate_keyword_path.rs
@@ -0,0 +1 @@
fn foo() { crate::foo(); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rast b/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rast
new file mode 100644
index 000000000..54ea2c7c6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rast
@@ -0,0 +1,47 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "S"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected] "#"
26 [email protected] "["
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "cfg"
31 [email protected]
32 [email protected] "("
33 [email protected] "test"
34 [email protected] ")"
35 [email protected] "]"
36 [email protected] " "
37 [email protected]
38 [email protected] "field"
39 [email protected] ":"
40 [email protected] " "
41 [email protected]
42 [email protected] "1"
43 [email protected] " "
44 [email protected] "}"
45 [email protected] "\n"
46 [email protected] "}"
47 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rs b/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rs
new file mode 100644
index 000000000..a6c7760c7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0125_record_literal_field_with_attr.rs
@@ -0,0 +1,3 @@
1fn main() {
2 S { #[cfg(test)] field: 1 }
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rast b/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rast
new file mode 100644
index 000000000..0342e64f3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rast
@@ -0,0 +1,97 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "#"
17 [email protected] "["
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "A"
22 [email protected] "]"
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "foo"
30 [email protected]
31 [email protected] "("
32 [email protected] ")"
33 [email protected] ";"
34 [email protected] "\n "
35 [email protected]
36 [email protected]
37 [email protected] "#"
38 [email protected] "["
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "B"
43 [email protected] "]"
44 [email protected] " "
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "bar"
50 [email protected] "!"
51 [email protected]
52 [email protected] "{"
53 [email protected] "}"
54 [email protected] "\n "
55 [email protected]
56 [email protected]
57 [email protected] "#"
58 [email protected] "["
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected] "C"
63 [email protected] "]"
64 [email protected] " "
65 [email protected]
66 [email protected] "#"
67 [email protected] "["
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected] "D"
72 [email protected] "]"
73 [email protected] " "
74 [email protected]
75 [email protected] "{"
76 [email protected] "}"
77 [email protected] "\n "
78 [email protected]
79 [email protected]
80 [email protected] "#"
81 [email protected] "["
82 [email protected]
83 [email protected]
84 [email protected]
85 [email protected] "D"
86 [email protected] "]"
87 [email protected] " "
88 [email protected]
89 [email protected] "return"
90 [email protected] " "
91 [email protected]
92 [email protected] "("
93 [email protected] ")"
94 [email protected] ";"
95 [email protected] "\n"
96 [email protected] "}"
97 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rs b/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rs
new file mode 100644
index 000000000..b28c078f9
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0126_attr_on_expr_stmt.rs
@@ -0,0 +1,6 @@
1fn foo() {
2 #[A] foo();
3 #[B] bar!{}
4 #[C] #[D] {}
5 #[D] return ();
6}
diff --git a/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rast b/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rast
new file mode 100644
index 000000000..3b46e5b47
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rast
@@ -0,0 +1,57 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected] "{"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected] "#"
21 [email protected] "["
22 [email protected]
23 [email protected]
24 [email protected]
25 [email protected] "A"
26 [email protected] "]"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "bar"
33 [email protected] "!"
34 [email protected]
35 [email protected] "("
36 [email protected] ")"
37 [email protected] "?"
38 [email protected] " "
39 [email protected] "}"
40 [email protected] "\n "
41 [email protected]
42 [email protected]
43 [email protected] "#"
44 [email protected] "["
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected] "B"
49 [email protected] "]"
50 [email protected] " "
51 [email protected] "&"
52 [email protected]
53 [email protected] "("
54 [email protected] ")"
55 [email protected] "\n"
56 [email protected] "}"
57 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rs b/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rs
new file mode 100644
index 000000000..9c5c8eb36
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0127_attr_on_last_expr_in_block.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 { #[A] bar!()? }
3 #[B] &()
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rast b/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rast
new file mode 100644
index 000000000..e283966ca
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rast
@@ -0,0 +1,36 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "m"
23 [email protected] "!"
24 [email protected]
25 [email protected] "("
26 [email protected] "x"
27 [email protected] ")"
28 [email protected] " "
29 [email protected] "="
30 [email protected] " "
31 [email protected]
32 [email protected] "0"
33 [email protected] ";"
34 [email protected] "\n"
35 [email protected] "}"
36 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rs b/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rs
new file mode 100644
index 000000000..811181d9b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0129_marco_pat.rs
@@ -0,0 +1,3 @@
1fn main() {
2 let m!(x) = 0;
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rast b/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rast
new file mode 100644
index 000000000..4c07cefa6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rast
@@ -0,0 +1,126 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "a"
20 [email protected] ";"
21 [email protected] "\n "
22 [email protected]
23 [email protected] "let"
24 [email protected] " "
25 [email protected]
26 [email protected]
27 [email protected] "b"
28 [email protected] ":"
29 [email protected] " "
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "i32"
35 [email protected] ";"
36 [email protected] "\n "
37 [email protected]
38 [email protected] "let"
39 [email protected] " "
40 [email protected]
41 [email protected]
42 [email protected] "c"
43 [email protected] " "
44 [email protected] "="
45 [email protected] " "
46 [email protected]
47 [email protected] "92"
48 [email protected] ";"
49 [email protected] "\n "
50 [email protected]
51 [email protected] "let"
52 [email protected] " "
53 [email protected]
54 [email protected]
55 [email protected] "d"
56 [email protected] ":"
57 [email protected] " "
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected] "i32"
63 [email protected] " "
64 [email protected] "="
65 [email protected] " "
66 [email protected]
67 [email protected] "92"
68 [email protected] ";"
69 [email protected] "\n "
70 [email protected]
71 [email protected] "let"
72 [email protected] " "
73 [email protected]
74 [email protected]
75 [email protected] "e"
76 [email protected] ":"
77 [email protected] " "
78 [email protected]
79 [email protected] "!"
80 [email protected] ";"
81 [email protected] "\n "
82 [email protected]
83 [email protected] "let"
84 [email protected] " "
85 [email protected]
86 [email protected] "_"
87 [email protected] ":"
88 [email protected] " "
89 [email protected]
90 [email protected] "!"
91 [email protected] " "
92 [email protected] "="
93 [email protected] " "
94 [email protected]
95 [email protected] "{"
96 [email protected] "}"
97 [email protected] ";"
98 [email protected] "\n "
99 [email protected]
100 [email protected] "let"
101 [email protected] " "
102 [email protected]
103 [email protected]
104 [email protected] "f"
105 [email protected] " "
106 [email protected] "="
107 [email protected] " "
108 [email protected]
109 [email protected]
110 [email protected] "#"
111 [email protected] "["
112 [email protected]
113 [email protected]
114 [email protected]
115 [email protected] "attr"
116 [email protected] "]"
117 [email protected]
118 [email protected] "|"
119 [email protected] "|"
120 [email protected]
121 [email protected] "{"
122 [email protected] "}"
123 [email protected] ";"
124 [email protected] "\n"
125 [email protected] "}"
126 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rs b/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rs
new file mode 100644
index 000000000..fa8ee49a2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0130_let_stmt.rs
@@ -0,0 +1,9 @@
1fn foo() {
2 let a;
3 let b: i32;
4 let c = 92;
5 let d: i32 = 92;
6 let e: !;
7 let _: ! = {};
8 let f = #[attr]||{};
9}
diff --git a/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rast b/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rast
new file mode 100644
index 000000000..ffdffe2f8
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rast
@@ -0,0 +1,31 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected] "try"
24 [email protected] " "
25 [email protected]
26 [email protected] "{"
27 [email protected] "}"
28 [email protected] ";"
29 [email protected] "\n"
30 [email protected] "}"
31 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rs b/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rs
new file mode 100644
index 000000000..0f1b41eb6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0130_try_block_expr.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 let _ = try {};
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rast b/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rast
new file mode 100644
index 000000000..d47071a91
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rast
@@ -0,0 +1,31 @@
1[email protected]
2 [email protected]
3 [email protected] "existential"
4 [email protected] " "
5 [email protected] "type"
6 [email protected] " "
7 [email protected]
8 [email protected] "Foo"
9 [email protected] ":"
10 [email protected] " "
11 [email protected]
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "Fn"
18 [email protected]
19 [email protected] "("
20 [email protected] ")"
21 [email protected] " "
22 [email protected]
23 [email protected] "->"
24 [email protected] " "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "usize"
30 [email protected] ";"
31 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rs b/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rs
new file mode 100644
index 000000000..23baf7145
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0131_existential_type.rs
@@ -0,0 +1 @@
existential type Foo: Fn() -> usize;
diff --git a/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rast b/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rast
new file mode 100644
index 000000000..c55038247
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rast
@@ -0,0 +1,89 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "x"
20 [email protected] " "
21 [email protected] "="
22 [email protected] " "
23 [email protected]
24 [email protected] "box"
25 [email protected] " "
26 [email protected]
27 [email protected] "1i32"
28 [email protected] ";"
29 [email protected] "\n "
30 [email protected]
31 [email protected] "let"
32 [email protected] " "
33 [email protected]
34 [email protected]
35 [email protected] "y"
36 [email protected] " "
37 [email protected] "="
38 [email protected] " "
39 [email protected]
40 [email protected] "("
41 [email protected]
42 [email protected] "box"
43 [email protected] " "
44 [email protected]
45 [email protected] "1i32"
46 [email protected] ","
47 [email protected] " "
48 [email protected]
49 [email protected] "box"
50 [email protected] " "
51 [email protected]
52 [email protected] "2i32"
53 [email protected] ")"
54 [email protected] ";"
55 [email protected] "\n "
56 [email protected]
57 [email protected] "let"
58 [email protected] " "
59 [email protected]
60 [email protected]
61 [email protected] "z"
62 [email protected] " "
63 [email protected] "="
64 [email protected] " "
65 [email protected]
66 [email protected]
67 [email protected]
68 [email protected]
69 [email protected]
70 [email protected] "Foo"
71 [email protected]
72 [email protected] "("
73 [email protected]
74 [email protected] "box"
75 [email protected] " "
76 [email protected]
77 [email protected] "1i32"
78 [email protected] ","
79 [email protected] " "
80 [email protected]
81 [email protected] "box"
82 [email protected] " "
83 [email protected]
84 [email protected] "2i32"
85 [email protected] ")"
86 [email protected] ";"
87 [email protected] "\n"
88 [email protected] "}"
89 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rs b/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rs
new file mode 100644
index 000000000..fc9923b71
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0132_box_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 let x = box 1i32;
3 let y = (box 1i32, box 2i32);
4 let z = Foo(box 1i32, box 2i32);
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rast b/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rast
new file mode 100644
index 000000000..429a0506e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rast
@@ -0,0 +1,62 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "simple_function"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "enum"
16 [email protected] " "
17 [email protected]
18 [email protected] "LocalEnum"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] "\n "
23 [email protected]
24 [email protected]
25 [email protected] "One"
26 [email protected] ","
27 [email protected] "\n "
28 [email protected]
29 [email protected]
30 [email protected] "Two"
31 [email protected] ","
32 [email protected] "\n "
33 [email protected] "}"
34 [email protected] ";"
35 [email protected] "\n "
36 [email protected]
37 [email protected] "fn"
38 [email protected] " "
39 [email protected]
40 [email protected] "f"
41 [email protected]
42 [email protected] "("
43 [email protected] ")"
44 [email protected] " "
45 [email protected]
46 [email protected] "{"
47 [email protected] "}"
48 [email protected] ";"
49 [email protected] "\n "
50 [email protected]
51 [email protected] "struct"
52 [email protected] " "
53 [email protected]
54 [email protected] "S"
55 [email protected] " "
56 [email protected]
57 [email protected] "{"
58 [email protected] "}"
59 [email protected] ";"
60 [email protected] "\n"
61 [email protected] "}"
62 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rs b/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rs
new file mode 100644
index 000000000..eadc7fffb
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0134_nocontentexpr_after_item.rs
@@ -0,0 +1,8 @@
1fn simple_function() {
2 enum LocalEnum {
3 One,
4 Two,
5 };
6 fn f() {};
7 struct S {};
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rast b/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rast
new file mode 100644
index 000000000..923effe38
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rast
@@ -0,0 +1,69 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "x"
21 [email protected] "."
22 [email protected] "await"
23 [email protected] ";"
24 [email protected] "\n "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "x"
33 [email protected] "."
34 [email protected]
35 [email protected] "0"
36 [email protected] "."
37 [email protected] "await"
38 [email protected] ";"
39 [email protected] "\n "
40 [email protected]
41 [email protected]
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected] "x"
51 [email protected] "."
52 [email protected]
53 [email protected] "0"
54 [email protected]
55 [email protected] "("
56 [email protected] ")"
57 [email protected] "."
58 [email protected] "await"
59 [email protected] "?"
60 [email protected] "."
61 [email protected]
62 [email protected] "hello"
63 [email protected]
64 [email protected] "("
65 [email protected] ")"
66 [email protected] ";"
67 [email protected] "\n"
68 [email protected] "}"
69 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rs b/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rs
new file mode 100644
index 000000000..d2ba89ca6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0137_await_expr.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 x.await;
3 x.0.await;
4 x.0().await?.hello();
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rast b/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rast
new file mode 100644
index 000000000..3870ec135
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rast
@@ -0,0 +1,55 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "print_all"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] ":"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "Iterator"
21 [email protected]
22 [email protected] "<"
23 [email protected]
24 [email protected]
25 [email protected] "Item"
26 [email protected] ":"
27 [email protected] " "
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected]
33 [email protected]
34 [email protected] "Display"
35 [email protected] ">"
36 [email protected] ">"
37 [email protected]
38 [email protected] "("
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "printables"
43 [email protected] ":"
44 [email protected] " "
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected] "T"
50 [email protected] ")"
51 [email protected] " "
52 [email protected]
53 [email protected] "{"
54 [email protected] "}"
55 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rs b/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rs
new file mode 100644
index 000000000..eb21a657b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_associated_type_bounds.rs
@@ -0,0 +1 @@
fn print_all<T: Iterator<Item: Display>>(printables: T) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rast b/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rast
new file mode 100644
index 000000000..f7c0e0ab0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rast
@@ -0,0 +1,64 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "mut"
19 [email protected] " "
20 [email protected]
21 [email protected] "p"
22 [email protected] " "
23 [email protected] "="
24 [email protected] " "
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "F"
30 [email protected]
31 [email protected] "{"
32 [email protected]
33 [email protected]
34 [email protected] "x"
35 [email protected] ":"
36 [email protected] " "
37 [email protected]
38 [email protected] "5"
39 [email protected] "}"
40 [email protected] ";"
41 [email protected] "\n "
42 [email protected]
43 [email protected]
44 [email protected]
45 [email protected]
46 [email protected] "{"
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected] "p"
52 [email protected] "}"
53 [email protected] "."
54 [email protected]
55 [email protected] "x"
56 [email protected] " "
57 [email protected] "="
58 [email protected] " "
59 [email protected]
60 [email protected] "10"
61 [email protected] ";"
62 [email protected] "\n"
63 [email protected] "}"
64 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rs b/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rs
new file mode 100644
index 000000000..76007e3ee
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_expression_after_block.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 let mut p = F{x: 5};
3 {p}.x = 10;
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rast b/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rast
new file mode 100644
index 000000000..6403ff8d5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rast
@@ -0,0 +1,25 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "f"
7 [email protected]
8 [email protected] "("
9 [email protected]
10 [email protected] "#"
11 [email protected] "["
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected] "must_use"
16 [email protected] "]"
17 [email protected] " "
18 [email protected]
19 [email protected] "self"
20 [email protected] ")"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rs b/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rs
new file mode 100644
index 000000000..35155057a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0138_self_param_outer_attr.rs
@@ -0,0 +1 @@
fn f(#[must_use] self) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rast b/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rast
new file mode 100644
index 000000000..495e4c51b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rast
@@ -0,0 +1,34 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "f"
7 [email protected]
8 [email protected] "("
9 [email protected]
10 [email protected] "#"
11 [email protected] "["
12 [email protected]
13 [email protected]
14 [email protected]
15 [email protected] "attr1"
16 [email protected] "]"
17 [email protected] " "
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "pat"
22 [email protected] ":"
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected] "Type"
29 [email protected] ")"
30 [email protected] " "
31 [email protected]
32 [email protected] "{"
33 [email protected] "}"
34 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rs b/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rs
new file mode 100644
index 000000000..c238be791
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0139_param_outer_arg.rs
@@ -0,0 +1 @@
fn f(#[attr1] pat: Type) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rast b/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rast
new file mode 100644
index 000000000..36e448c94
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rast
@@ -0,0 +1,40 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "for"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "x"
20 [email protected] " "
21 [email protected] "in"
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected] "0"
26 [email protected] " "
27 [email protected] ".."
28 [email protected] " "
29 [email protected]
30 [email protected] "{"
31 [email protected] "\n "
32 [email protected]
33 [email protected]
34 [email protected] "break"
35 [email protected] ";"
36 [email protected] "\n "
37 [email protected] "}"
38 [email protected] "\n"
39 [email protected] "}"
40 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rs b/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rs
new file mode 100644
index 000000000..af0d40a7a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0142_for_range_from.rs
@@ -0,0 +1,5 @@
1fn foo() {
2 for x in 0 .. {
3 break;
4 }
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rast b/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rast
new file mode 100644
index 000000000..65887b962
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rast
@@ -0,0 +1,110 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "box"
19 [email protected] " "
20 [email protected]
21 [email protected]
22 [email protected] "i"
23 [email protected] " "
24 [email protected] "="
25 [email protected] " "
26 [email protected]
27 [email protected] "("
28 [email protected] ")"
29 [email protected] ";"
30 [email protected] "\n "
31 [email protected]
32 [email protected] "let"
33 [email protected] " "
34 [email protected]
35 [email protected] "box"
36 [email protected] " "
37 [email protected]
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected] "Outer"
42 [email protected] " "
43 [email protected]
44 [email protected] "{"
45 [email protected] " "
46 [email protected]
47 [email protected]
48 [email protected] "box"
49 [email protected] " "
50 [email protected]
51 [email protected]
52 [email protected] "i"
53 [email protected] ","
54 [email protected] " "
55 [email protected]
56 [email protected]
57 [email protected] "j"
58 [email protected] ":"
59 [email protected] " "
60 [email protected]
61 [email protected] "box"
62 [email protected] " "
63 [email protected]
64 [email protected]
65 [email protected]
66 [email protected]
67 [email protected] "Inner"
68 [email protected] "("
69 [email protected]
70 [email protected] "box"
71 [email protected] " "
72 [email protected]
73 [email protected] "&"
74 [email protected]
75 [email protected]
76 [email protected] "x"
77 [email protected] ")"
78 [email protected] " "
79 [email protected] "}"
80 [email protected] " "
81 [email protected] "="
82 [email protected] " "
83 [email protected]
84 [email protected] "("
85 [email protected] ")"
86 [email protected] ";"
87 [email protected] "\n "
88 [email protected]
89 [email protected] "let"
90 [email protected] " "
91 [email protected]
92 [email protected] "box"
93 [email protected] " "
94 [email protected]
95 [email protected] "ref"
96 [email protected] " "
97 [email protected] "mut"
98 [email protected] " "
99 [email protected]
100 [email protected] "i"
101 [email protected] " "
102 [email protected] "="
103 [email protected] " "
104 [email protected]
105 [email protected] "("
106 [email protected] ")"
107 [email protected] ";"
108 [email protected] "\n"
109 [email protected] "}"
110 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rs b/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rs
new file mode 100644
index 000000000..9d458aa1e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0143_box_pat.rs
@@ -0,0 +1,5 @@
1fn main() {
2 let box i = ();
3 let box Outer { box i, j: box Inner(box &x) } = ();
4 let box ref mut i = ();
5}
diff --git a/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rast b/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rast
new file mode 100644
index 000000000..8a5bde0b6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rast
@@ -0,0 +1,455 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] ".."
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected] "("
24 [email protected] ")"
25 [email protected] ";"
26 [email protected] "\n "
27 [email protected] "//"
28 [email protected] "\n "
29 [email protected] "// Tuples"
30 [email protected] "\n "
31 [email protected] "//"
32 [email protected] "\n "
33 [email protected]
34 [email protected] "let"
35 [email protected] " "
36 [email protected]
37 [email protected] "("
38 [email protected]
39 [email protected]
40 [email protected] "a"
41 [email protected] ","
42 [email protected] " "
43 [email protected]
44 [email protected] ".."
45 [email protected] ")"
46 [email protected] " "
47 [email protected] "="
48 [email protected] " "
49 [email protected]
50 [email protected] "("
51 [email protected] ")"
52 [email protected] ";"
53 [email protected] "\n "
54 [email protected]
55 [email protected] "let"
56 [email protected] " "
57 [email protected]
58 [email protected] "("
59 [email protected]
60 [email protected]
61 [email protected] "a"
62 [email protected] ","
63 [email protected] " "
64 [email protected]
65 [email protected] ".."
66 [email protected] ","
67 [email protected] ")"
68 [email protected] " "
69 [email protected] "="
70 [email protected] " "
71 [email protected]
72 [email protected] "("
73 [email protected] ")"
74 [email protected] ";"
75 [email protected] "\n "
76 [email protected]
77 [email protected] "let"
78 [email protected] " "
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected]
83 [email protected] "Tuple"
84 [email protected] "("
85 [email protected]
86 [email protected]
87 [email protected] "a"
88 [email protected] ","
89 [email protected] " "
90 [email protected]
91 [email protected] ".."
92 [email protected] ")"
93 [email protected] " "
94 [email protected] "="
95 [email protected] " "
96 [email protected]
97 [email protected] "("
98 [email protected] ")"
99 [email protected] ";"
100 [email protected] "\n "
101 [email protected]
102 [email protected] "let"
103 [email protected] " "
104 [email protected]
105 [email protected]
106 [email protected]
107 [email protected]
108 [email protected] "Tuple"
109 [email protected] "("
110 [email protected]
111 [email protected]
112 [email protected] "a"
113 [email protected] ","
114 [email protected] " "
115 [email protected]
116 [email protected] ".."
117 [email protected] ","
118 [email protected] ")"
119 [email protected] " "
120 [email protected] "="
121 [email protected] " "
122 [email protected]
123 [email protected] "("
124 [email protected] ")"
125 [email protected] ";"
126 [email protected] "\n "
127 [email protected]
128 [email protected] "let"
129 [email protected] " "
130 [email protected]
131 [email protected] "("
132 [email protected]
133 [email protected] ".."
134 [email protected] ","
135 [email protected] " "
136 [email protected]
137 [email protected] ".."
138 [email protected] ")"
139 [email protected] " "
140 [email protected] "="
141 [email protected] " "
142 [email protected]
143 [email protected] "("
144 [email protected] ")"
145 [email protected] ";"
146 [email protected] "\n "
147 [email protected]
148 [email protected] "let"
149 [email protected] " "
150 [email protected]
151 [email protected]
152 [email protected]
153 [email protected]
154 [email protected] "Tuple"
155 [email protected] "("
156 [email protected]
157 [email protected] ".."
158 [email protected] ","
159 [email protected] " "
160 [email protected]
161 [email protected] ".."
162 [email protected] ")"
163 [email protected] " "
164 [email protected] "="
165 [email protected] " "
166 [email protected]
167 [email protected] "("
168 [email protected] ")"
169 [email protected] ";"
170 [email protected] "\n "
171 [email protected]
172 [email protected] "let"
173 [email protected] " "
174 [email protected]
175 [email protected] "("
176 [email protected]
177 [email protected] ".."
178 [email protected] ","
179 [email protected] " "
180 [email protected]
181 [email protected]
182 [email protected] "a"
183 [email protected] ","
184 [email protected] " "
185 [email protected]
186 [email protected] ".."
187 [email protected] ")"
188 [email protected] " "
189 [email protected] "="
190 [email protected] " "
191 [email protected]
192 [email protected] "("
193 [email protected] ")"
194 [email protected] ";"
195 [email protected] "\n "
196 [email protected]
197 [email protected] "let"
198 [email protected] " "
199 [email protected]
200 [email protected]
201 [email protected]
202 [email protected]
203 [email protected] "Tuple"
204 [email protected] "("
205 [email protected]
206 [email protected] ".."
207 [email protected] ","
208 [email protected] " "
209 [email protected]
210 [email protected]
211 [email protected] "a"
212 [email protected] ","
213 [email protected] " "
214 [email protected]
215 [email protected] ".."
216 [email protected] ")"
217 [email protected] " "
218 [email protected] "="
219 [email protected] " "
220 [email protected]
221 [email protected] "("
222 [email protected] ")"
223 [email protected] ";"
224 [email protected] "\n "
225 [email protected] "//"
226 [email protected] "\n "
227 [email protected] "// Slices"
228 [email protected] "\n "
229 [email protected] "//"
230 [email protected] "\n "
231 [email protected]
232 [email protected] "let"
233 [email protected] " "
234 [email protected]
235 [email protected] "["
236 [email protected]
237 [email protected] ".."
238 [email protected] "]"
239 [email protected] " "
240 [email protected] "="
241 [email protected] " "
242 [email protected]
243 [email protected] "("
244 [email protected] ")"
245 [email protected] ";"
246 [email protected] "\n "
247 [email protected]
248 [email protected] "let"
249 [email protected] " "
250 [email protected]
251 [email protected] "["
252 [email protected]
253 [email protected]
254 [email protected] "head"
255 [email protected] ","
256 [email protected] " "
257 [email protected]
258 [email protected] ".."
259 [email protected] "]"
260 [email protected] " "
261 [email protected] "="
262 [email protected] " "
263 [email protected]
264 [email protected] "("
265 [email protected] ")"
266 [email protected] ";"
267 [email protected] "\n "
268 [email protected]
269 [email protected] "let"
270 [email protected] " "
271 [email protected]
272 [email protected] "["
273 [email protected]
274 [email protected]
275 [email protected] "head"
276 [email protected] ","
277 [email protected] " "
278 [email protected]
279 [email protected]
280 [email protected] "tail"
281 [email protected] " "
282 [email protected] "@"
283 [email protected] " "
284 [email protected]
285 [email protected] ".."
286 [email protected] "]"
287 [email protected] " "
288 [email protected] "="
289 [email protected] " "
290 [email protected]
291 [email protected] "("
292 [email protected] ")"
293 [email protected] ";"
294 [email protected] "\n "
295 [email protected]
296 [email protected] "let"
297 [email protected] " "
298 [email protected]
299 [email protected] "["
300 [email protected]
301 [email protected]
302 [email protected] "head"
303 [email protected] ","
304 [email protected] " "
305 [email protected]
306 [email protected] ".."
307 [email protected] ","
308 [email protected] " "
309 [email protected]
310 [email protected]
311 [email protected] "cons"
312 [email protected] "]"
313 [email protected] " "
314 [email protected] "="
315 [email protected] " "
316 [email protected]
317 [email protected] "("
318 [email protected] ")"
319 [email protected] ";"
320 [email protected] "\n "
321 [email protected]
322 [email protected] "let"
323 [email protected] " "
324 [email protected]
325 [email protected] "["
326 [email protected]
327 [email protected]
328 [email protected] "head"
329 [email protected] ","
330 [email protected] " "
331 [email protected]
332 [email protected]
333 [email protected] "mid"
334 [email protected] " "
335 [email protected] "@"
336 [email protected] " "
337 [email protected]
338 [email protected] ".."
339 [email protected] ","
340 [email protected] " "
341 [email protected]
342 [email protected]
343 [email protected] "cons"
344 [email protected] "]"
345 [email protected] " "
346 [email protected] "="
347 [email protected] " "
348 [email protected]
349 [email protected] "("
350 [email protected] ")"
351 [email protected] ";"
352 [email protected] "\n "
353 [email protected]
354 [email protected] "let"
355 [email protected] " "
356 [email protected]
357 [email protected] "["
358 [email protected]
359 [email protected]
360 [email protected] "head"
361 [email protected] ","
362 [email protected] " "
363 [email protected]
364 [email protected] ".."
365 [email protected] ","
366 [email protected] " "
367 [email protected]
368 [email protected] ".."
369 [email protected] ","
370 [email protected] " "
371 [email protected]
372 [email protected]
373 [email protected] "cons"
374 [email protected] "]"
375 [email protected] " "
376 [email protected] "="
377 [email protected] " "
378 [email protected]
379 [email protected] "("
380 [email protected] ")"
381 [email protected] ";"
382 [email protected] "\n "
383 [email protected]
384 [email protected] "let"
385 [email protected] " "
386 [email protected]
387 [email protected] "["
388 [email protected]
389 [email protected]
390 [email protected] "head"
391 [email protected] ","
392 [email protected] " "
393 [email protected]
394 [email protected] ".."
395 [email protected] ","
396 [email protected] " "
397 [email protected]
398 [email protected]
399 [email protected] "mid"
400 [email protected] ","
401 [email protected] " "
402 [email protected]
403 [email protected]
404 [email protected] "tail"
405 [email protected] " "
406 [email protected] "@"
407 [email protected] " "
408 [email protected]
409 [email protected] ".."
410 [email protected] "]"
411 [email protected] " "
412 [email protected] "="
413 [email protected] " "
414 [email protected]
415 [email protected] "("
416 [email protected] ")"
417 [email protected] ";"
418 [email protected] "\n "
419 [email protected]
420 [email protected] "let"
421 [email protected] " "
422 [email protected]
423 [email protected] "["
424 [email protected]
425 [email protected]
426 [email protected] "head"
427 [email protected] ","
428 [email protected] " "
429 [email protected]
430 [email protected] ".."
431 [email protected] ","
432 [email protected] " "
433 [email protected]
434 [email protected]
435 [email protected] "mid"
436 [email protected] ","
437 [email protected] " "
438 [email protected]
439 [email protected] ".."
440 [email protected] ","
441 [email protected] " "
442 [email protected]
443 [email protected]
444 [email protected] "cons"
445 [email protected] "]"
446 [email protected] " "
447 [email protected] "="
448 [email protected] " "
449 [email protected]
450 [email protected] "("
451 [email protected] ")"
452 [email protected] ";"
453 [email protected] "\n"
454 [email protected] "}"
455 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rs b/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rs
new file mode 100644
index 000000000..3262f27e1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0144_dot_dot_pat.rs
@@ -0,0 +1,25 @@
1fn main() {
2 let .. = ();
3 //
4 // Tuples
5 //
6 let (a, ..) = ();
7 let (a, ..,) = ();
8 let Tuple(a, ..) = ();
9 let Tuple(a, ..,) = ();
10 let (.., ..) = ();
11 let Tuple(.., ..) = ();
12 let (.., a, ..) = ();
13 let Tuple(.., a, ..) = ();
14 //
15 // Slices
16 //
17 let [..] = ();
18 let [head, ..] = ();
19 let [head, tail @ ..] = ();
20 let [head, .., cons] = ();
21 let [head, mid @ .., cons] = ();
22 let [head, .., .., cons] = ();
23 let [head, .., mid, tail @ ..] = ();
24 let [head, .., mid, .., cons] = ();
25}
diff --git a/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rast b/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rast
new file mode 100644
index 000000000..925409bdf
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rast
@@ -0,0 +1,75 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "S"
22 [email protected] " "
23 [email protected]
24 [email protected] "{"
25 [email protected] " "
26 [email protected]
27 [email protected]
28 [email protected] "0"
29 [email protected] ":"
30 [email protected] " "
31 [email protected]
32 [email protected]
33 [email protected] "1"
34 [email protected] " "
35 [email protected] "}"
36 [email protected] " "
37 [email protected] "="
38 [email protected] " "
39 [email protected]
40 [email protected] "("
41 [email protected] ")"
42 [email protected] ";"
43 [email protected] "\n "
44 [email protected]
45 [email protected] "let"
46 [email protected] " "
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected] "S"
52 [email protected] " "
53 [email protected]
54 [email protected] "{"
55 [email protected] " "
56 [email protected]
57 [email protected]
58 [email protected] "x"
59 [email protected] ":"
60 [email protected] " "
61 [email protected]
62 [email protected]
63 [email protected] "1"
64 [email protected] " "
65 [email protected] "}"
66 [email protected] " "
67 [email protected] "="
68 [email protected] " "
69 [email protected]
70 [email protected] "("
71 [email protected] ")"
72 [email protected] ";"
73 [email protected] "\n"
74 [email protected] "}"
75 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rs b/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rs
new file mode 100644
index 000000000..26b1d5f89
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0145_record_field_pat.rs
@@ -0,0 +1,4 @@
1fn foo() {
2 let S { 0: 1 } = ();
3 let S { x: 1 } = ();
4}
diff --git a/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rast b/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rast
new file mode 100644
index 000000000..a36cc8dab
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rast
@@ -0,0 +1,42 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected] "_"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected]
24 [email protected] "&"
25 [email protected]
26 [email protected] "1"
27 [email protected] " "
28 [email protected] "as"
29 [email protected] " "
30 [email protected]
31 [email protected] "*"
32 [email protected] "const"
33 [email protected] " "
34 [email protected]
35 [email protected]
36 [email protected]
37 [email protected]
38 [email protected] "i32"
39 [email protected] ";"
40 [email protected] "\n"
41 [email protected] "}"
42 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rs b/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rs
new file mode 100644
index 000000000..a06dec1fa
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0146_as_precedence.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 let _ = &1 as *const i32;
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0147_const_param.rast b/crates/syntax/test_data/parser/inline/ok/0147_const_param.rast
new file mode 100644
index 000000000..9312eab65
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0147_const_param.rast
@@ -0,0 +1,23 @@
1[email protected]
2 [email protected]
3 [email protected] "struct"
4 [email protected] " "
5 [email protected]
6 [email protected] "S"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected] "const"
11 [email protected] " "
12 [email protected]
13 [email protected] "N"
14 [email protected] ":"
15 [email protected] " "
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "u32"
21 [email protected] ">"
22 [email protected] ";"
23 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0147_const_param.rs b/crates/syntax/test_data/parser/inline/ok/0147_const_param.rs
new file mode 100644
index 000000000..8cdb3b703
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0147_const_param.rs
@@ -0,0 +1 @@
struct S<const N: u32>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rast b/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rast
new file mode 100644
index 000000000..6655aeab1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rast
@@ -0,0 +1,45 @@
1[email protected]
2 [email protected]
3 [email protected] "macro"
4 [email protected] " "
5 [email protected]
6 [email protected] "m"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] " "
11 [email protected]
12 [email protected] "("
13 [email protected] "$"
14 [email protected] "i"
15 [email protected] ":"
16 [email protected] "ident"
17 [email protected] ")"
18 [email protected] " "
19 [email protected] "="
20 [email protected] ">"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] " "
26 [email protected] "}"
27 [email protected] "\n"
28 [email protected]
29 [email protected] "macro"
30 [email protected] " "
31 [email protected]
32 [email protected] "m"
33 [email protected]
34 [email protected]
35 [email protected] "("
36 [email protected] "$"
37 [email protected] "i"
38 [email protected] ":"
39 [email protected] "ident"
40 [email protected] ")"
41 [email protected] " "
42 [email protected]
43 [email protected] "{"
44 [email protected] "}"
45 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rs b/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rs
new file mode 100644
index 000000000..319a4e2aa
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0147_macro_def.rs
@@ -0,0 +1,2 @@
1macro m { ($i:ident) => {} }
2macro m($i:ident) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rast b/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rast
new file mode 100644
index 000000000..1c527f60b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rast
@@ -0,0 +1,21 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected] "pub"
5 [email protected] " "
6 [email protected] "macro"
7 [email protected] " "
8 [email protected]
9 [email protected] "m"
10 [email protected]
11 [email protected]
12 [email protected] "("
13 [email protected] "$"
14 [email protected] ":"
15 [email protected] "ident"
16 [email protected] ")"
17 [email protected] " "
18 [email protected]
19 [email protected] "{"
20 [email protected] "}"
21 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rs b/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rs
new file mode 100644
index 000000000..3b2be597f
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0148_pub_macro_def.rs
@@ -0,0 +1 @@
pub macro m($:ident) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rast b/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rast
new file mode 100644
index 000000000..f284aafcd
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rast
@@ -0,0 +1,47 @@
1[email protected]
2 [email protected]
3 [email protected] "const"
4 [email protected] " "
5 [email protected]
6 [email protected] "A"
7 [email protected] ":"
8 [email protected] " "
9 [email protected]
10 [email protected] "&"
11 [email protected]
12 [email protected] "["
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "i64"
18 [email protected] "]"
19 [email protected] " "
20 [email protected] "="
21 [email protected] " "
22 [email protected]
23 [email protected] "&"
24 [email protected]
25 [email protected] "["
26 [email protected]
27 [email protected] "1"
28 [email protected] ","
29 [email protected] " "
30 [email protected]
31 [email protected]
32 [email protected] "#"
33 [email protected] "["
34 [email protected]
35 [email protected]
36 [email protected]
37 [email protected] "cfg"
38 [email protected]
39 [email protected] "("
40 [email protected] "test"
41 [email protected] ")"
42 [email protected] "]"
43 [email protected] " "
44 [email protected] "2"
45 [email protected] "]"
46 [email protected] ";"
47 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rs b/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rs
new file mode 100644
index 000000000..2ac310924
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0150_array_attrs.rs
@@ -0,0 +1 @@
const A: &[i64] = &[1, #[cfg(test)] 2];
diff --git a/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rast b/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rast
new file mode 100644
index 000000000..12194abda
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rast
@@ -0,0 +1,38 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected]
5 [email protected] "<"
6 [email protected]
7 [email protected] "const"
8 [email protected] " "
9 [email protected]
10 [email protected] "N"
11 [email protected] ":"
12 [email protected] " "
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "u32"
18 [email protected] ">"
19 [email protected] " "
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected]
24 [email protected] "Bar"
25 [email protected]
26 [email protected] "<"
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected]
31 [email protected]
32 [email protected] "N"
33 [email protected] ">"
34 [email protected] " "
35 [email protected]
36 [email protected] "{"
37 [email protected] "}"
38 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rs b/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rs
new file mode 100644
index 000000000..cb0a105c2
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0150_impl_type_params.rs
@@ -0,0 +1 @@
impl<const N: u32> Bar<N> {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0151_fn.rast b/crates/syntax/test_data/parser/inline/ok/0151_fn.rast
new file mode 100644
index 000000000..23c4269b3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0151_fn.rast
@@ -0,0 +1,14 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "}"
14 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0151_fn.rs b/crates/syntax/test_data/parser/inline/ok/0151_fn.rs
new file mode 100644
index 000000000..8f3b7ef11
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0151_fn.rs
@@ -0,0 +1 @@
fn foo() {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rast b/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rast
new file mode 100644
index 000000000..dac50410e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rast
@@ -0,0 +1,128 @@
1[email protected]
2 [email protected]
3 [email protected] "trait"
4 [email protected] " "
5 [email protected]
6 [email protected] "Z"
7 [email protected]
8 [email protected] "<"
9 [email protected]
10 [email protected]
11 [email protected] "U"
12 [email protected] ">"
13 [email protected] " "
14 [email protected] "="
15 [email protected] " "
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected] "T"
23 [email protected]
24 [email protected] "<"
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected]
30 [email protected] "U"
31 [email protected] ">"
32 [email protected] ";"
33 [email protected] "\n"
34 [email protected]
35 [email protected] "trait"
36 [email protected] " "
37 [email protected]
38 [email protected] "Z"
39 [email protected]
40 [email protected] "<"
41 [email protected]
42 [email protected]
43 [email protected] "U"
44 [email protected] ">"
45 [email protected] " "
46 [email protected] "="
47 [email protected] " "
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected]
52 [email protected]
53 [email protected]
54 [email protected] "T"
55 [email protected]
56 [email protected] "<"
57 [email protected]
58 [email protected]
59 [email protected]
60 [email protected]
61 [email protected]
62 [email protected] "U"
63 [email protected] ">"
64 [email protected] " "
65 [email protected]
66 [email protected] "where"
67 [email protected] " "
68 [email protected]
69 [email protected]
70 [email protected]
71 [email protected]
72 [email protected]
73 [email protected] "U"
74 [email protected] ":"
75 [email protected] " "
76 [email protected]
77 [email protected]
78 [email protected]
79 [email protected]
80 [email protected]
81 [email protected]
82 [email protected] "Copy"
83 [email protected] ";"
84 [email protected] "\n"
85 [email protected]
86 [email protected] "trait"
87 [email protected] " "
88 [email protected]
89 [email protected] "Z"
90 [email protected]
91 [email protected] "<"
92 [email protected]
93 [email protected]
94 [email protected] "U"
95 [email protected] ">"
96 [email protected] " "
97 [email protected] "="
98 [email protected] " "
99 [email protected]
100 [email protected]
101 [email protected] "where"
102 [email protected] " "
103 [email protected]
104 [email protected]
105 [email protected]
106 [email protected]
107 [email protected]
108 [email protected] "Self"
109 [email protected] ":"
110 [email protected] " "
111 [email protected]
112 [email protected]
113 [email protected]
114 [email protected]
115 [email protected]
116 [email protected]
117 [email protected] "T"
118 [email protected]
119 [email protected] "<"
120 [email protected]
121 [email protected]
122 [email protected]
123 [email protected]
124 [email protected]
125 [email protected] "U"
126 [email protected] ">"
127 [email protected] ";"
128 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rs b/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rs
new file mode 100644
index 000000000..4bd428ee4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0151_trait_alias.rs
@@ -0,0 +1,3 @@
1trait Z<U> = T<U>;
2trait Z<U> = T<U> where U: Copy;
3trait Z<U> = where Self: T<U>;
diff --git a/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rast b/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rast
new file mode 100644
index 000000000..2905c5f1a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rast
@@ -0,0 +1,36 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "foo"
20 [email protected]
21 [email protected] "("
22 [email protected]
23 [email protected]
24 [email protected] "#"
25 [email protected] "["
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "attr"
30 [email protected] "]"
31 [email protected] " "
32 [email protected] "92"
33 [email protected] ")"
34 [email protected] "\n"
35 [email protected] "}"
36 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rs b/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rs
new file mode 100644
index 000000000..5daf1d7b0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0152_arg_with_attr.rs
@@ -0,0 +1,3 @@
1fn main() {
2 foo(#[attr] 92)
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0152_impl.rast b/crates/syntax/test_data/parser/inline/ok/0152_impl.rast
new file mode 100644
index 000000000..7968cf9ff
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0152_impl.rast
@@ -0,0 +1,22 @@
1[email protected]
2 [email protected]
3 [email protected] "impl"
4 [email protected] " "
5 [email protected]
6 [email protected]
7 [email protected]
8 [email protected]
9 [email protected] "T"
10 [email protected] " "
11 [email protected] "for"
12 [email protected] " "
13 [email protected]
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "S"
18 [email protected] " "
19 [email protected]
20 [email protected] "{"
21 [email protected] "}"
22 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0152_impl.rs b/crates/syntax/test_data/parser/inline/ok/0152_impl.rs
new file mode 100644
index 000000000..a1a550d8a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0152_impl.rs
@@ -0,0 +1 @@
impl T for S {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0153_trait.rast b/crates/syntax/test_data/parser/inline/ok/0153_trait.rast
new file mode 100644
index 000000000..9881e5048
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0153_trait.rast
@@ -0,0 +1,11 @@
1[email protected]
2 [email protected]
3 [email protected] "trait"
4 [email protected] " "
5 [email protected]
6 [email protected] "T"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] "}"
11 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0153_trait.rs b/crates/syntax/test_data/parser/inline/ok/0153_trait.rs
new file mode 100644
index 000000000..8d183dbb5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0153_trait.rs
@@ -0,0 +1 @@
trait T {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rast b/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rast
new file mode 100644
index 000000000..e6aff7b37
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rast
@@ -0,0 +1,58 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "fn"
12 [email protected]
13 [email protected] "("
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "Bar"
21 [email protected] "::"
22 [email protected]
23 [email protected]
24 [email protected] "Baz"
25 [email protected] ")"
26 [email protected] ";"
27 [email protected] "\n"
28 [email protected]
29 [email protected] "type"
30 [email protected] " "
31 [email protected]
32 [email protected] "Qux"
33 [email protected] " "
34 [email protected] "="
35 [email protected] " "
36 [email protected]
37 [email protected] "fn"
38 [email protected]
39 [email protected] "("
40 [email protected]
41 [email protected]
42 [email protected]
43 [email protected] "baz"
44 [email protected] ":"
45 [email protected] " "
46 [email protected]
47 [email protected]
48 [email protected]
49 [email protected]
50 [email protected]
51 [email protected] "Bar"
52 [email protected] "::"
53 [email protected]
54 [email protected]
55 [email protected] "Baz"
56 [email protected] ")"
57 [email protected] ";"
58 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rs b/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rs
new file mode 100644
index 000000000..80a1701fd
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0154_fn_pointer_param_ident_path.rs
@@ -0,0 +1,2 @@
1type Foo = fn(Bar::Baz);
2type Qux = fn(baz: Bar::Baz);
diff --git a/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rast b/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rast
new file mode 100644
index 000000000..31671b420
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rast
@@ -0,0 +1,69 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "foo"
20 [email protected] " "
21 [email protected] "="
22 [email protected] " "
23 [email protected]
24 [email protected]
25 [email protected] "|"
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "bar"
30 [email protected] ","
31 [email protected] " "
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected] "baz"
36 [email protected] ":"
37 [email protected] " "
38 [email protected]
39 [email protected]
40 [email protected]
41 [email protected]
42 [email protected] "Baz"
43 [email protected] ","
44 [email protected] " "
45 [email protected]
46 [email protected]
47 [email protected]
48 [email protected] "qux"
49 [email protected] ":"
50 [email protected] " "
51 [email protected]
52 [email protected]
53 [email protected]
54 [email protected]
55 [email protected]
56 [email protected] "Qux"
57 [email protected] "::"
58 [email protected]
59 [email protected]
60 [email protected] "Quux"
61 [email protected] "|"
62 [email protected] " "
63 [email protected]
64 [email protected] "("
65 [email protected] ")"
66 [email protected] ";"
67 [email protected] "\n"
68 [email protected] "}"
69 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rs b/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rs
new file mode 100644
index 000000000..6ca8dd2d6
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0155_closure_params.rs
@@ -0,0 +1,3 @@
1fn main() {
2 let foo = |bar, baz: Baz, qux: Qux::Quux| ();
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rast b/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rast
new file mode 100644
index 000000000..508b4aca7
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rast
@@ -0,0 +1,43 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected]
10 [email protected]
11 [email protected] "("
12 [email protected]
13 [email protected]
14 [email protected] "x"
15 [email protected] ","
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected] "y"
20 [email protected] ")"
21 [email protected] ":"
22 [email protected] " "
23 [email protected]
24 [email protected] "("
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected]
29 [email protected] "i32"
30 [email protected] ","
31 [email protected] " "
32 [email protected]
33 [email protected]
34 [email protected]
35 [email protected]
36 [email protected] "i32"
37 [email protected] ")"
38 [email protected] ")"
39 [email protected] " "
40 [email protected]
41 [email protected] "{"
42 [email protected] "}"
43 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rs b/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rs
new file mode 100644
index 000000000..7b277c16b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0156_fn_def_param.rs
@@ -0,0 +1 @@
fn foo((x, y): (i32, i32)) {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rast b/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rast
new file mode 100644
index 000000000..88a513cee
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rast
@@ -0,0 +1,111 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected] "match"
16 [email protected] " "
17 [email protected]
18 [email protected] "("
19 [email protected] ")"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "\n "
24 [email protected]
25 [email protected]
26 [email protected] "("
27 [email protected]
28 [email protected]
29 [email protected] "_"
30 [email protected] " "
31 [email protected] "|"
32 [email protected] " "
33 [email protected]
34 [email protected] "_"
35 [email protected] ")"
36 [email protected] " "
37 [email protected] "=>"
38 [email protected] " "
39 [email protected]
40 [email protected] "("
41 [email protected] ")"
42 [email protected] ","
43 [email protected] "\n "
44 [email protected]
45 [email protected]
46 [email protected] "&"
47 [email protected]
48 [email protected] "("
49 [email protected]
50 [email protected]
51 [email protected] "_"
52 [email protected] " "
53 [email protected] "|"
54 [email protected] " "
55 [email protected]
56 [email protected] "_"
57 [email protected] ")"
58 [email protected] " "
59 [email protected] "=>"
60 [email protected] " "
61 [email protected]
62 [email protected] "("
63 [email protected] ")"
64 [email protected] ","
65 [email protected] "\n "
66 [email protected]
67 [email protected]
68 [email protected] "("
69 [email protected]
70 [email protected]
71 [email protected] "_"
72 [email protected] " "
73 [email protected] "|"
74 [email protected] " "
75 [email protected]
76 [email protected] "_"
77 [email protected] ","
78 [email protected] ")"
79 [email protected] " "
80 [email protected] "=>"
81 [email protected] " "
82 [email protected]
83 [email protected] "("
84 [email protected] ")"
85 [email protected] ","
86 [email protected] "\n "
87 [email protected]
88 [email protected]
89 [email protected] "["
90 [email protected]
91 [email protected]
92 [email protected] "_"
93 [email protected] " "
94 [email protected] "|"
95 [email protected] " "
96 [email protected]
97 [email protected] "_"
98 [email protected] ","
99 [email protected] "]"
100 [email protected] " "
101 [email protected] "=>"
102 [email protected] " "
103 [email protected]
104 [email protected] "("
105 [email protected] ")"
106 [email protected] ","
107 [email protected] "\n "
108 [email protected] "}"
109 [email protected] "\n"
110 [email protected] "}"
111 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rs b/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rs
new file mode 100644
index 000000000..a26316605
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0156_or_pattern.rs
@@ -0,0 +1,8 @@
1fn main() {
2 match () {
3 (_ | _) => (),
4 &(_ | _) => (),
5 (_ | _,) => (),
6 [_ | _,] => (),
7 }
8}
diff --git a/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rast b/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rast
new file mode 100644
index 000000000..6abb4fe5a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rast
@@ -0,0 +1,26 @@
1[email protected]
2 [email protected]
3 [email protected] "type"
4 [email protected] " "
5 [email protected]
6 [email protected] "Foo"
7 [email protected] " "
8 [email protected] "="
9 [email protected] " "
10 [email protected]
11 [email protected] "fn"
12 [email protected]
13 [email protected] "("
14 [email protected]
15 [email protected]
16 [email protected] "_"
17 [email protected] ":"
18 [email protected] " "
19 [email protected]
20 [email protected]
21 [email protected]
22 [email protected]
23 [email protected] "bar"
24 [email protected] ")"
25 [email protected] ";"
26 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rs b/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rs
new file mode 100644
index 000000000..1ebbe5b03
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0157_fn_pointer_unnamed_arg.rs
@@ -0,0 +1 @@
type Foo = fn(_: bar);
diff --git a/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rast b/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rast
new file mode 100644
index 000000000..a2e05eb2e
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rast
@@ -0,0 +1,30 @@
1[email protected]
2 [email protected]
3 [email protected] "enum"
4 [email protected] " "
5 [email protected]
6 [email protected] "E"
7 [email protected] " "
8 [email protected]
9 [email protected] "{"
10 [email protected] " "
11 [email protected]
12 [email protected]
13 [email protected] "X"
14 [email protected]
15 [email protected] "("
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "i32"
22 [email protected] ")"
23 [email protected] " "
24 [email protected] "="
25 [email protected] " "
26 [email protected]
27 [email protected] "10"
28 [email protected] " "
29 [email protected] "}"
30 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rs b/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rs
new file mode 100644
index 000000000..c8c5c0f17
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0157_variant_discriminant.rs
@@ -0,0 +1 @@
enum E { X(i32) = 10 }
diff --git a/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rast b/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rast
new file mode 100644
index 000000000..8ae24b9c1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rast
@@ -0,0 +1,36 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] "\n "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected] "v"
21 [email protected] " "
22 [email protected] "="
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected] "{"
27 [email protected]
28 [email protected] "1"
29 [email protected] "}"
30 [email protected] "&"
31 [email protected]
32 [email protected] "2"
33 [email protected] ";"
34 [email protected] "\n"
35 [email protected] "}"
36 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rs b/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rs
new file mode 100644
index 000000000..05acc30f1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0158_binop_resets_statementness.rs
@@ -0,0 +1,3 @@
1fn foo() {
2 v = {1}&2;
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rast b/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rast
new file mode 100644
index 000000000..aa4099a92
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rast
@@ -0,0 +1,43 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected] "|"
19 [email protected] "|"
20 [email protected] " "
21 [email protected]
22 [email protected] "->"
23 [email protected] " "
24 [email protected]
25 [email protected]
26 [email protected]
27 [email protected]
28 [email protected] "i32"
29 [email protected] " "
30 [email protected]
31 [email protected] "{"
32 [email protected] " "
33 [email protected]
34 [email protected] "92"
35 [email protected] " "
36 [email protected] "}"
37 [email protected]
38 [email protected] "("
39 [email protected] ")"
40 [email protected] ";"
41 [email protected] " "
42 [email protected] "}"
43 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rs b/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rs
new file mode 100644
index 000000000..061118d3a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0158_lambda_ret_block.rs
@@ -0,0 +1 @@
fn main() { || -> i32 { 92 }(); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rast b/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rast
new file mode 100644
index 000000000..fb46d4ce4
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rast
@@ -0,0 +1,34 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "foo"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "try"
20 [email protected] "!"
21 [email protected]
22 [email protected] "("
23 [email protected] "Ok"
24 [email protected]
25 [email protected] "("
26 [email protected]
27 [email protected] "("
28 [email protected] ")"
29 [email protected] ")"
30 [email protected] ")"
31 [email protected] ";"
32 [email protected] " "
33 [email protected] "}"
34 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rs b/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rs
new file mode 100644
index 000000000..61a6b46a0
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0159_try_macro_fallback.rs
@@ -0,0 +1 @@
fn foo() { try!(Ok(())); }
diff --git a/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rast b/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rast
new file mode 100644
index 000000000..05b89d1c3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rast
@@ -0,0 +1,27 @@
1[email protected]
2 [email protected]
3 [email protected]
4 [email protected]
5 [email protected]
6 [email protected] "macro_rules"
7 [email protected] "!"
8 [email protected] " "
9 [email protected]
10 [email protected] "try"
11 [email protected] " "
12 [email protected]
13 [email protected] "{"
14 [email protected] " "
15 [email protected]
16 [email protected] "("
17 [email protected] ")"
18 [email protected] " "
19 [email protected] "="
20 [email protected] ">"
21 [email protected] " "
22 [email protected]
23 [email protected] "{"
24 [email protected] "}"
25 [email protected] " "
26 [email protected] "}"
27 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rs b/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rs
new file mode 100644
index 000000000..2e2ab6e60
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0160_try_macro_rules.rs
@@ -0,0 +1 @@
macro_rules! try { () => {} }
diff --git a/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rast b/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rast
new file mode 100644
index 000000000..9e9a5f9c5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rast
@@ -0,0 +1,26 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "f"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected]
16 [email protected]
17 [email protected] "\'label"
18 [email protected] ":"
19 [email protected] " "
20 [email protected]
21 [email protected] "{"
22 [email protected] "}"
23 [email protected] ";"
24 [email protected] " "
25 [email protected] "}"
26 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rs b/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rs
new file mode 100644
index 000000000..18b4ff4b1
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0161_labeled_block.rs
@@ -0,0 +1 @@
fn f() { 'label: {}; }
diff --git a/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rast b/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rast
new file mode 100644
index 000000000..ca9a1183d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rast
@@ -0,0 +1,23 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "f"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected] "unsafe"
16 [email protected] " "
17 [email protected]
18 [email protected] "{"
19 [email protected] " "
20 [email protected] "}"
21 [email protected] " "
22 [email protected] "}"
23 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rs b/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rs
new file mode 100644
index 000000000..dfb9b2a1c
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0162_unsafe_block.rs
@@ -0,0 +1 @@
fn f() { unsafe { } }
diff --git a/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rast b/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rast
new file mode 100644
index 000000000..f2e201460
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rast
@@ -0,0 +1,44 @@
1[email protected]
2 [email protected]
3 [email protected] "default"
4 [email protected] " "
5 [email protected] "unsafe"
6 [email protected] " "
7 [email protected] "impl"
8 [email protected] " "
9 [email protected]
10 [email protected]
11 [email protected]
12 [email protected]
13 [email protected] "T"
14 [email protected] " "
15 [email protected] "for"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "Foo"
22 [email protected] " "
23 [email protected]
24 [email protected] "{"
25 [email protected] "\n "
26 [email protected]
27 [email protected] "default"
28 [email protected] " "
29 [email protected] "unsafe"
30 [email protected] " "
31 [email protected] "fn"
32 [email protected] " "
33 [email protected]
34 [email protected] "foo"
35 [email protected]
36 [email protected] "("
37 [email protected] ")"
38 [email protected] " "
39 [email protected]
40 [email protected] "{"
41 [email protected] "}"
42 [email protected] "\n"
43 [email protected] "}"
44 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rs b/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rs
new file mode 100644
index 000000000..96340f84a
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0163_default_unsafe_item.rs
@@ -0,0 +1,3 @@
1default unsafe impl T for Foo {
2 default unsafe fn foo() {}
3}
diff --git a/crates/syntax/test_data/parser/inline/ok/0164_default_item.rast b/crates/syntax/test_data/parser/inline/ok/0164_default_item.rast
new file mode 100644
index 000000000..9282772f3
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0164_default_item.rast
@@ -0,0 +1,24 @@
1[email protected]
2 [email protected]
3 [email protected] "default"
4 [email protected] " "
5 [email protected] "impl"
6 [email protected] " "
7 [email protected]
8 [email protected]
9 [email protected]
10 [email protected]
11 [email protected] "T"
12 [email protected] " "
13 [email protected] "for"
14 [email protected] " "
15 [email protected]
16 [email protected]
17 [email protected]
18 [email protected]
19 [email protected] "Foo"
20 [email protected] " "
21 [email protected]
22 [email protected] "{"
23 [email protected] "}"
24 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0164_default_item.rs b/crates/syntax/test_data/parser/inline/ok/0164_default_item.rs
new file mode 100644
index 000000000..a6836cbd5
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0164_default_item.rs
@@ -0,0 +1 @@
default impl T for Foo {}
diff --git a/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rast b/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rast
new file mode 100644
index 000000000..f8910677b
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rast
@@ -0,0 +1,38 @@
1[email protected]
2 [email protected]
3 [email protected] "fn"
4 [email protected] " "
5 [email protected]
6 [email protected] "main"
7 [email protected]
8 [email protected] "("
9 [email protected] ")"
10 [email protected] " "
11 [email protected]
12 [email protected] "{"
13 [email protected] " "
14 [email protected]
15 [email protected] "let"
16 [email protected] " "
17 [email protected]
18 [email protected]
19 [email protected]
20 [email protected]
21 [email protected] "<"
22 [email protected]
23 [email protected] "_"
24 [email protected] ">"
25 [email protected] "::"
26 [email protected]
27 [email protected]
28 [email protected] "Foo"
29 [email protected] " "
30 [email protected] "="
31 [email protected] " "
32 [email protected]
33 [email protected] "("
34 [email protected] ")"
35 [email protected] ";"
36 [email protected] " "
37 [email protected] "}"
38 [email protected] "\n"
diff --git a/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rs b/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rs
new file mode 100644
index 000000000..ebe26834d
--- /dev/null
+++ b/crates/syntax/test_data/parser/inline/ok/0164_type_path_in_pattern.rs
@@ -0,0 +1 @@
fn main() { let <_>::Foo = (); }