From b9d3d9a3dfe6467b6d03fabbd8b56058bb435d43 Mon Sep 17 00:00:00 2001 From: Jon Ross-Perkins Date: Thu, 6 Oct 2022 12:25:23 -0700 Subject: [PATCH] Unify lit.cfg.py approach (#2249) On #2224 @zygoloid pointed out we needed --implicit-check-not to ensure we were correctly matching output. This is the standard way we're writing explorer tests, so I was looking at unifying our lit approaches. This is one take on it, making more use of substitutions to bring various testing into alignment, as well as symlinks to avoid config skew (maybe I'll eventually figure out a better solution than symlinks). Makes a couple small fixes in explorer to remove end-of-line whitespace on output. --- bazel/testing/lit.cfg.py | 56 +++++++++++++++++++ explorer/README.md | 8 +-- explorer/interpreter/type_checker.cpp | 2 +- explorer/testdata/addr/fail_method_let.carbon | 8 +-- .../addr/fail_method_me_misspelled.carbon | 8 +-- .../testdata/addr/fail_method_me_type.carbon | 8 +-- explorer/testdata/addr/method.carbon | 8 +-- explorer/testdata/addr/nested_method.carbon | 8 +-- explorer/testdata/alias/class_alias.carbon | 14 ++--- .../alias/fail_alias_expression.carbon | 8 +-- explorer/testdata/alias/fail_alias_var.carbon | 8 +-- .../testdata/alias/fail_self_alias.carbon | 8 +-- explorer/testdata/alias/function_alias.carbon | 8 +-- .../testdata/alias/interface_alias.carbon | 8 +-- .../testdata/alias/member_name_alias.carbon | 8 +-- explorer/testdata/alias/struct_alias.carbon | 16 +++--- explorer/testdata/alias/type_alias.carbon | 8 +-- explorer/testdata/array/fail_index.carbon | 8 +-- .../testdata/array/fail_negative_size.carbon | 8 +-- .../testdata/array/fail_size_mismatch.carbon | 8 +-- explorer/testdata/array/index.carbon | 8 +-- explorer/testdata/array/nested.carbon | 8 +-- explorer/testdata/as/as_same_type.carbon | 8 +-- explorer/testdata/as/convert.carbon | 8 +-- .../as/fail_destination_not_type.carbon | 8 +-- .../testdata/as/fail_no_conversion.carbon | 10 ++-- explorer/testdata/as/implicit_as.carbon | 8 +-- explorer/testdata/assert/assert.carbon | 8 +-- explorer/testdata/assign/convert_rhs.carbon | 8 +-- .../testdata/assign/destruct_original.carbon | 8 +-- .../testdata/assign/reassign_original.carbon | 8 +-- .../assoc_const/fail_anonymous.carbon | 8 +-- .../assoc_const/fail_incomplete_impl_1.carbon | 8 +-- .../assoc_const/fail_incomplete_impl_2.carbon | 8 +-- .../assoc_const/fail_indirectly_equal.carbon | 8 +-- .../fail_match_in_deduction.carbon | 8 +-- .../fail_multi_impl_scoping.carbon | 8 +-- .../fail_multiple_deduction.carbon | 12 ++-- .../fail_overspecified_impl.carbon | 8 +-- .../assoc_const/fail_redefined.carbon | 8 +-- .../assoc_const/fail_unknown_value.carbon | 8 +-- ...known_value_specified_in_constraint.carbon | 8 +-- .../testdata/assoc_const/impl_lookup.carbon | 8 +-- .../testdata/assoc_const/implement.carbon | 8 +-- .../assoc_const/simple_constraint.carbon | 8 +-- .../assoc_const/simple_equality.carbon | 8 +-- .../testdata/basic_syntax/addition.carbon | 8 +-- explorer/testdata/basic_syntax/choice.carbon | 8 +-- .../fail_alternative_not_type.carbon | 8 +-- .../fail_alternative_uses_choice.carbon | 8 +-- .../fail_assign_to_function.carbon | 8 +-- .../basic_syntax/fail_assign_to_rval.carbon | 8 +-- .../testdata/basic_syntax/fail_block.carbon | 8 +-- .../basic_syntax/fail_choice_no_parens.carbon | 12 ++-- .../basic_syntax/fail_invalid_char.carbon | 8 +-- .../basic_syntax/fail_invalid_integer.carbon | 8 +-- .../fail_invalid_integer_type.carbon | 8 +-- .../fail_invalid_var_expression.carbon | 8 +-- .../basic_syntax/fail_missing_var.carbon | 8 +-- .../basic_syntax/fail_nested_binding.carbon | 8 +-- .../fail_unimplemented_example.carbon | 8 +-- .../fail_unknown_intrinsic.carbon | 8 +-- .../fail_unsupported_integer_type.carbon | 8 +-- .../basic_syntax/fail_var_named_self.carbon | 8 +-- .../basic_syntax/fail_var_type.carbon | 8 +-- explorer/testdata/basic_syntax/next.carbon | 8 +-- .../not_compare_precedence.carbon | 8 +-- .../basic_syntax/placeholder_variable.carbon | 8 +-- explorer/testdata/basic_syntax/record.carbon | 8 +-- explorer/testdata/basic_syntax/star.carbon | 8 +-- explorer/testdata/basic_syntax/trace.carbon | 27 +++++---- .../testdata/basic_syntax/var_tuple.carbon | 8 +-- explorer/testdata/basic_syntax/zero.carbon | 8 +-- explorer/testdata/block/empty.carbon | 8 +-- explorer/testdata/block/shadowing.carbon | 8 +-- ..._choice_multiple_template_arguments.carbon | 8 +-- ...ric_choice_nested_in_template_class.carbon | 10 ++-- .../generic_choice_simple_assignment.carbon | 8 +-- explorer/testdata/class/assign.carbon | 8 +-- explorer/testdata/class/assign_member.carbon | 8 +-- explorer/testdata/class/bound_method.carbon | 8 +-- explorer/testdata/class/class_function.carbon | 8 +-- .../class/class_function_from_instance.carbon | 8 +-- .../testdata/class/class_function_self.carbon | 8 +-- .../class/class_function_value.carbon | 8 +-- explorer/testdata/class/empty_class.carbon | 8 +-- .../testdata/class/fail_abstract_class.carbon | 8 +-- .../testdata/class/fail_base_class.carbon | 8 +-- .../testdata/class/fail_class_extends.carbon | 8 +-- .../class/fail_class_named_self.carbon | 8 +-- .../class/fail_field_access_mismatch.carbon | 8 +-- .../testdata/class/fail_field_mismatch.carbon | 8 +-- .../testdata/class/fail_field_missing.carbon | 8 +-- .../testdata/class/fail_method_deduced.carbon | 8 +-- .../class/fail_method_from_class.carbon | 8 +-- .../testdata/class/fail_method_in_var.carbon | 8 +-- .../testdata/class/fail_return_method.carbon | 8 +-- explorer/testdata/class/function_param.carbon | 8 +-- explorer/testdata/class/global_var.carbon | 8 +-- explorer/testdata/class/method.carbon | 8 +-- .../testdata/class/method_call_method.carbon | 8 +-- explorer/testdata/class/method_self.carbon | 8 +-- explorer/testdata/class/temp.carbon | 8 +-- explorer/testdata/class/var.carbon | 8 +-- .../comparison/builtin_comparsion.carbon | 24 ++++---- .../comparison/builtin_equality.carbon | 56 +++++++++---------- .../comparison/custom_equality.carbon | 12 ++-- .../comparison/fail_empty_struct.carbon | 5 +- .../testdata/comparison/fail_no_impl.carbon | 5 +- .../testdata/constraint/binding_self.carbon | 8 +-- .../constraint/combined_interfaces.carbon | 8 +-- .../constraint/dot_self_is_other.carbon | 8 +-- .../constraint/fail_ambiguous_member.carbon | 8 +-- .../fail_dot_self_after_scope.carbon | 8 +-- .../fail_dot_self_after_scope_2.carbon | 8 +-- .../fail_dot_self_not_in_scope.carbon | 8 +-- .../constraint/fail_infinite_self.carbon | 8 +-- .../constraint/fail_infinite_self_ptr.carbon | 8 +-- .../constraint/fail_non_type_self.carbon | 8 +-- .../fail_where_equals_different_types.carbon | 12 ++-- .../fail_where_is_non_constraint.carbon | 8 +-- .../constraint/fail_where_is_non_type.carbon | 8 +-- .../constraint/fail_where_non_type_is.carbon | 8 +-- .../testdata/constraint/missing_member.carbon | 8 +-- .../constraint/no_combine_equality.carbon | 8 +-- .../constraint/nondependent_where.carbon | 8 +-- .../qualified_lookup_in_where.carbon | 8 +-- .../testdata/constraint/where_self.carbon | 8 +-- .../call_destructor_from_destructor.carbon | 16 +++--- .../destructor/destructor_with_return.carbon | 10 ++-- ...ail_multiple_destructor_declaration.carbon | 5 +- .../destructor/function_with_return.carbon | 14 ++--- .../testdata/destructor/loop_block.carbon | 20 +++---- .../destructor/loop_break_continue.carbon | 30 +++++----- .../nested_block_with_return.carbon | 16 +++--- .../await_maintains_scope.carbon | 8 +-- .../convert_run.carbon | 8 +-- .../creation_is_noop.carbon | 8 +-- .../fail_auto_return_await.carbon | 8 +-- .../fail_continuation_syntax.carbon | 8 +-- .../fail_lifetime.carbon | 8 +-- .../fail_recursive_continuation.carbon | 8 +-- .../fail_return_in_continuation.carbon | 8 +-- .../recursive.carbon | 8 +-- .../experimental_continuation/run.carbon | 8 +-- .../run_with_await.carbon | 8 +-- .../shallow_copy.carbon | 8 +-- explorer/testdata/for/for_loop.carbon | 43 +++++++------- explorer/testdata/for/for_loop_auto.carbon | 29 ++++------ explorer/testdata/for/for_loop_break.carbon | 8 +-- .../testdata/for/for_loop_continue.carbon | 8 +-- explorer/testdata/for/for_loop_empty.carbon | 8 +-- explorer/testdata/for/for_loop_nested.carbon | 8 +-- .../testdata/function/auto_return/add.carbon | 8 +-- .../auto_return/fail_direct_recurse.carbon | 8 +-- .../auto_return/fail_multiple_returns.carbon | 8 +-- .../auto_return/fail_no_return.carbon | 8 +-- .../auto_return/fail_separate_decl.carbon | 8 +-- .../auto_return/modify_arg_type.carbon | 8 +-- .../auto_return/modify_return_type.carbon | 8 +-- .../testdata/function/auto_return/type.carbon | 8 +-- .../testdata/function/convert_args.carbon | 8 +-- .../testdata/function/empty_params.carbon | 8 +-- .../function/fail_call_with_tuple.carbon | 8 +-- .../function/fail_invalid_fnty.carbon | 10 ++-- .../function/fail_match_no_return.carbon | 8 +-- .../function/fail_match_partial_return.carbon | 8 +-- .../function/fail_non_exhaustive_match.carbon | 8 +-- .../function/fail_parameter_type.carbon | 8 +-- explorer/testdata/function/fnty.carbon | 8 +-- .../function/ignored_parameter.carbon | 8 +-- .../testdata/function/multiple_args.carbon | 8 +-- ...non_exhaustive_match_no_return_type.carbon | 8 +-- .../non_exhaustive_match_return.carbon | 8 +-- .../testdata/function/param_lifetime.carbon | 8 +-- explorer/testdata/function/recursive.carbon | 8 +-- explorer/testdata/function/return.carbon | 8 +-- .../function/return_exhaustive_match.carbon | 8 +-- explorer/testdata/function/type_match.carbon | 8 +-- .../generic_class/class_function.carbon | 8 +-- .../generic_class/convert_from_struct.carbon | 8 +-- .../generic_class/fail_args_mismatch.carbon | 6 +- .../fail_argument_deduction.carbon | 12 ++-- .../fail_bad_parameter_type.carbon | 8 +-- .../fail_field_access_on_generic.carbon | 8 +-- .../fail_generic_class_arg.carbon | 8 +-- .../fail_generic_in_pattern.carbon | 8 +-- .../fail_instantiate_non_generic.carbon | 8 +-- .../generic_class/fail_no_args.carbon | 8 +-- .../generic_class/fail_point_equal.carbon | 8 +-- .../fail_return_type_is_type.carbon | 8 +-- .../generic_class/fail_self_with_arg.carbon | 8 +-- .../generic_class/fail_two_arg_lists.carbon | 8 +-- .../fail_value_param_mismatch.carbon | 8 +-- .../generic_class_substitution.carbon | 8 +-- .../generic_fun_and_class.carbon | 8 +-- .../generic_class/generic_point.carbon | 8 +-- .../generic_class/impl_with_argument.carbon | 8 +-- .../generic_class/impl_with_self.carbon | 8 +-- .../instantiation_at_compile_time.carbon | 8 +-- .../param_with_dependent_type.carbon | 8 +-- .../generic_class/point_with_interface.carbon | 8 +-- .../generic_class/use_at_compile_time.carbon | 8 +-- .../testdata/generic_class/use_self.carbon | 8 +-- .../testdata/generic_function/apply.carbon | 8 +-- .../call_at_compile_time.carbon | 8 +-- ...ail_implicit_conversion_extra_field.carbon | 8 +-- ...l_implicit_conversion_missing_field.carbon | 8 +-- .../fail_missing_exclam.carbon | 8 +-- .../generic_function/fail_not_addable.carbon | 10 ++-- .../generic_function/fail_not_type.carbon | 8 +-- .../fail_type_deduction_mismatch.carbon | 12 ++-- .../fail_type_deduction_unused.carbon | 10 ++-- .../fail_wrong_variable_substituation.carbon | 8 +-- .../generic_function/generic_method.carbon | 8 +-- .../implicit_conversion.carbon | 8 +-- .../generic_function/non_generic_param.carbon | 8 +-- .../nondeduced_generic_param.carbon | 8 +-- .../generic_function/return_val.carbon | 8 +-- .../testdata/generic_function/swap.carbon | 8 +-- .../generic_function/tuple_map.carbon | 8 +-- .../generic_function/type_matching.carbon | 8 +-- .../fail_init_type_mismatch.carbon | 8 +-- .../global_variable/fail_named_self.carbon | 8 +-- .../implicit_conversion.carbon | 8 +-- .../global_variable/init_and_read.carbon | 8 +-- .../global_variable/init_from_function.carbon | 8 +-- .../global_variable/init_order.carbon | 8 +-- .../testdata/global_variable/shadowing.carbon | 8 +-- .../testdata/global_variable/write.carbon | 8 +-- .../write_from_function.carbon | 8 +-- .../testdata/if_else/convert_condition.carbon | 8 +-- explorer/testdata/if_else/if_else.carbon | 8 +-- explorer/testdata/if_else/if_else_if.carbon | 8 +-- .../testdata/if_else/if_else_if_else.carbon | 8 +-- explorer/testdata/if_else/if_false.carbon | 8 +-- explorer/testdata/if_else/if_nesting.carbon | 8 +-- explorer/testdata/if_else/if_true.carbon | 8 +-- .../if_expression/convert_condition.carbon | 8 +-- .../if_expression/if_then_else.carbon | 8 +-- .../testdata/impl/deducible_parameter.carbon | 8 +-- .../testdata/impl/fail_ambiguous_impl.carbon | 8 +-- .../impl/fail_ambiguous_impl_generic.carbon | 8 +-- .../testdata/impl/fail_bad_member_kind.carbon | 8 +-- explorer/testdata/impl/fail_impl_as.carbon | 8 +-- .../impl/fail_impl_as_non_interface.carbon | 8 +-- .../impl/fail_impl_as_not_constraint.carbon | 8 +-- .../impl/fail_impl_as_parameterized.carbon | 8 +-- .../impl/fail_nondeducible_parameter.carbon | 8 +-- .../impl/fail_param_interface_in_impl.carbon | 8 +-- .../impl/fail_unambiguous_impl_generic.carbon | 8 +-- .../impl/fail_unmet_impl_constraint.carbon | 8 +-- .../testdata/impl/generic_method_impl.carbon | 8 +-- explorer/testdata/impl/impl_constraint.carbon | 8 +-- .../impl/impl_in_generic_class.carbon | 8 +-- explorer/testdata/impl/param_impl.carbon | 8 +-- explorer/testdata/impl/param_impl2.carbon | 8 +-- .../testdata/impl/param_impl_with_self.carbon | 8 +-- .../impl/param_interface_in_impl.carbon | 8 +-- .../import/fail_nonexistent_library.carbon | 8 +-- .../import/fail_nonexistent_package.carbon | 8 +-- explorer/testdata/import/fail_order.carbon | 8 +-- .../testdata/interface/class_function.carbon | 8 +-- .../interface/constrained_parameter.carbon | 8 +-- .../external_impl_point_vector.carbon | 8 +-- .../interface/external_impl_use_self.carbon | 8 +-- .../interface/fail_bad_member_kind.carbon | 8 +-- .../fail_external_impl_omit_self.carbon | 8 +-- .../interface/fail_external_impl_self.carbon | 8 +-- .../interface/fail_impl_bad_member.carbon | 12 ++-- .../interface/fail_impl_missing_member.carbon | 8 +-- .../interface/fail_impl_not_type.carbon | 8 +-- .../fail_interface_missing_member.carbon | 8 +-- .../testdata/interface/fail_no_impl.carbon | 8 +-- .../interface/fail_use_symbolic_member.carbon | 8 +-- .../interface/generic_call_generic.carbon | 8 +-- .../interface/generic_with_two_params.carbon | 8 +-- .../impl_self_interface_parameter.carbon | 8 +-- explorer/testdata/interface/omit_self.carbon | 8 +-- .../param_with_dependent_type.carbon | 8 +-- .../testdata/interface/parameterized.carbon | 8 +-- .../interface/tuple_vector_add_scale.carbon | 8 +-- .../interface/vector_point_add_scale.carbon | 8 +-- explorer/testdata/interface/with_self.carbon | 8 +-- .../testdata/let/fail_function_args.carbon | 8 +-- .../testdata/let/fail_global_assign.carbon | 8 +-- .../let/fail_global_named_self.carbon | 8 +-- .../testdata/let/fail_local_assign.carbon | 8 +-- .../testdata/let/fail_local_named_self.carbon | 8 +-- .../testdata/let/fail_match_choice.carbon | 8 +-- explorer/testdata/let/fail_method_args.carbon | 8 +-- .../let/fail_tuple_pattern_let_context.carbon | 8 +-- ...il_tuple_pattern_let_context_nested.carbon | 8 +-- .../let/fail_tuple_pattern_let_in_var.carbon | 8 +-- .../testdata/let/implicit_conversion.carbon | 8 +-- .../let/implicit_conversion_choice.carbon | 8 +-- .../testdata/let/nested_tuple_pattern.carbon | 8 +-- .../testdata/linked_list/linked_list.carbon | 24 ++++---- explorer/testdata/lit.cfg.py | 43 +------------- explorer/testdata/match/any_int.carbon | 8 +-- explorer/testdata/match/convert.carbon | 8 +-- explorer/testdata/match/exhaustive.carbon | 8 +-- .../testdata/match/exhaustive_bool.carbon | 8 +-- .../match/exhaustive_exponential_8x.carbon | 8 +-- .../exhaustive_exponential_series_t.carbon | 8 +-- .../fail_exhaustive_exponential_9x.carbon | 8 +-- ...ail_exhaustive_exponential_series_t.carbon | 8 +-- .../testdata/match/fail_exhaustive_int.carbon | 8 +-- .../match/fail_not_alternative.carbon | 8 +-- .../testdata/match/fail_not_exhaustive.carbon | 8 +-- .../testdata/match/fail_not_reachable.carbon | 8 +-- .../match/fail_not_reachable_default.carbon | 8 +-- .../match/fail_pattern_type_mismatch.carbon | 12 ++-- .../testdata/match/fail_redundant_int.carbon | 8 +-- explorer/testdata/match/int.carbon | 8 +-- explorer/testdata/match/int_default.carbon | 8 +-- explorer/testdata/match/no_match.carbon | 8 +-- explorer/testdata/match/placeholder.carbon | 8 +-- .../member_access/convert_lhs_class.carbon | 8 +-- .../convert_lhs_interface.carbon | 8 +-- .../evaluate_type_before_dot.carbon | 18 +++--- .../fail_qualified_non_member.carbon | 8 +-- .../member_access/fail_vacuous_access.carbon | 8 +-- .../fail_vacuous_access_via_type_param.carbon | 8 +-- ...rly_vacuous_access_with_impl_lookup.carbon | 8 +-- ...acuous_access_with_instance_binding.carbon | 8 +-- .../param_qualified_interface_member.carbon | 8 +-- .../qualified_class_member.carbon | 8 +-- .../qualified_constraint_member.carbon | 8 +-- .../qualified_interface_member.carbon | 8 +-- .../qualified_param_member.carbon | 8 +-- .../qualified_struct_member.carbon | 8 +-- .../type_qualified_interface_member.carbon | 8 +-- .../mixin/fail_circular_mixing.carbon | 8 +-- .../mixin/fail_field_member_name_clash.carbon | 8 +-- .../fail_method_member_name_clash.carbon | 8 +-- .../mixin/fail_mix_as_type_expr.carbon | 8 +-- .../mixin/fail_mix_diamond_clash.carbon | 8 +-- .../testdata/mixin/fail_mix_in_global.carbon | 8 +-- .../testdata/mixin/fail_mix_in_impl.carbon | 8 +-- .../mixin/fail_mix_members_clash.carbon | 8 +-- .../mixin/fail_recursive_mixing.carbon | 8 +-- .../mixin/fail_self_substitution.carbon | 8 +-- .../testdata/mixin/self_substitution.carbon | 8 +-- .../testdata/mixin/simple_mix_in_mixin.carbon | 8 +-- explorer/testdata/mixin/simple_reuse.carbon | 8 +-- .../use_mixin_method_in_class_method.carbon | 8 +-- .../name_lookup/class_fn_body_reorder.carbon | 8 +-- .../name_lookup/fail_block_duplicate.carbon | 8 +-- .../name_lookup/fail_choice_duplicate.carbon | 8 +-- .../name_lookup/fail_class_duplicate.carbon | 8 +-- ...ail_class_fn_use_before_declaration.carbon | 8 +-- .../fail_class_use_in_params.carbon | 8 +-- .../name_lookup/fail_fn_use_in_param.carbon | 8 +-- .../fail_fn_use_in_return_type.carbon | 8 +-- .../name_lookup/fail_global_duplicate.carbon | 8 +-- .../fail_use_before_declare.carbon | 8 +-- .../fail_var_use_before_declaration.carbon | 8 +-- .../testdata/name_lookup/global_shadow.carbon | 8 +-- .../testdata/name_lookup/match_shadow.carbon | 8 +-- explorer/testdata/operators/add.carbon | 8 +-- .../testdata/operators/add_builtin.carbon | 12 ++-- explorer/testdata/operators/bit_and.carbon | 8 +-- .../testdata/operators/bit_complement.carbon | 8 +-- explorer/testdata/operators/bit_or.carbon | 8 +-- explorer/testdata/operators/bit_xor.carbon | 8 +-- explorer/testdata/operators/bitwise.carbon | 8 +-- explorer/testdata/operators/div.carbon | 8 +-- .../testdata/operators/div_builtin.carbon | 12 ++-- .../testdata/operators/fail_no_add.carbon | 10 ++-- .../testdata/operators/fail_no_mul.carbon | 10 ++-- .../testdata/operators/fail_no_negate.carbon | 10 ++-- .../testdata/operators/fail_no_sub.carbon | 10 ++-- explorer/testdata/operators/left_shift.carbon | 8 +-- explorer/testdata/operators/mod.carbon | 8 +-- .../testdata/operators/mod_builtin.carbon | 12 ++-- explorer/testdata/operators/mod_edges.carbon | 8 +-- explorer/testdata/operators/mul.carbon | 8 +-- .../testdata/operators/mul_builtin.carbon | 12 ++-- explorer/testdata/operators/negate.carbon | 8 +-- .../testdata/operators/negate_builtin.carbon | 12 ++-- .../testdata/operators/right_shift.carbon | 8 +-- explorer/testdata/operators/shift.carbon | 8 +-- .../operators/shortcircuit_and.carbon | 8 +-- .../shortcircuit_and_no_shortcircuit.carbon | 8 +-- .../testdata/operators/shortcircuit_or.carbon | 8 +-- .../shortcircuit_or_no_shortcircuit.carbon | 8 +-- explorer/testdata/operators/sub.carbon | 8 +-- .../testdata/operators/sub_builtin.carbon | 12 ++-- .../init_optional_with_non_value.carbon | 8 +-- .../optional/init_optional_with_value.carbon | 10 ++-- explorer/testdata/package/fail_missing.carbon | 8 +-- explorer/testdata/package/with_library.carbon | 8 +-- explorer/testdata/pointer/aliasing.carbon | 8 +-- explorer/testdata/pointer/basic.carbon | 8 +-- .../pointer/fail_rvalue_addressof.carbon | 8 +-- .../pointer/fail_use_after_free.carbon | 8 +-- .../pointer/heap_alloc_lifetime.carbon | 8 +-- .../testdata/pointer/intrinsic_new.carbon | 8 +-- .../testdata/pointer/new_and_delete.carbon | 8 +-- .../testdata/pointer/struct_pointer.carbon | 8 +-- .../testdata/print/associated_constant.carbon | 12 ++-- explorer/testdata/print/fail_no_args.carbon | 8 +-- explorer/testdata/print/fail_not_str.carbon | 12 ++-- .../testdata/print/fail_too_many_args.carbon | 8 +-- explorer/testdata/print/fail_type.carbon | 12 ++-- explorer/testdata/print/format_only.carbon | 10 ++-- explorer/testdata/print/i32.carbon | 10 ++-- explorer/testdata/random/random.carbon | 10 ++-- .../return/convert_return_value.carbon | 8 +-- .../testdata/return/explicit_empty.carbon | 8 +-- .../fail_explicit_with_no_return.carbon | 8 +-- .../fail_explicit_with_plain_return.carbon | 8 +-- .../fail_implicit_with_explicit_return.carbon | 8 +-- .../return/implicit_with_no_return.carbon | 8 +-- .../return/implicit_with_plain_return.carbon | 8 +-- .../fail_duplicate_return_var.carbon | 8 +-- .../fail_missing_declaration.carbon | 8 +-- .../returned_var/fail_missing_return.carbon | 8 +-- ...ail_returned_var_mismatch_signature.carbon | 8 +-- .../fail_returned_var_multi_auto.carbon | 8 +-- .../fail_returned_var_type_mismatch.carbon | 8 +-- .../multiple_returned_var_control_flow.carbon | 8 +-- .../normal_return_control_flow.carbon | 8 +-- .../returned_var/returned_var_auto.carbon | 8 +-- .../returned_var/returned_var_basic.carbon | 8 +-- .../returned_var_name_lookup.carbon | 8 +-- .../returned_var_omitted_expression.carbon | 8 +-- explorer/testdata/string/basic.carbon | 8 +-- explorer/testdata/string/block.carbon | 8 +-- .../string/block_escaped_triple_quotes.carbon | 8 +-- .../string/block_file_type_indicator.carbon | 8 +-- .../fail_block_quotes_not_on_own_line.carbon | 8 +-- .../testdata/string/fail_hex_lower.carbon | 8 +-- .../testdata/string/fail_hex_truncated.carbon | 8 +-- .../string/fail_invalid_escape.carbon | 8 +-- explorer/testdata/string/fail_newline.carbon | 8 +-- explorer/testdata/string/fail_octal.carbon | 8 +-- ...il_raw_block_more_hash_tags_on_left.carbon | 8 +-- ...l_raw_block_more_hash_tags_on_right.carbon | 8 +-- ...il_raw_block_quotes_not_on_own_line.carbon | 8 +-- .../string/fail_raw_block_single_line.carbon | 8 +-- .../fail_raw_more_hash_tags_on_left.carbon | 8 +-- .../fail_raw_more_hash_tags_on_right.carbon | 8 +-- explorer/testdata/string/fail_tab.carbon | 8 +-- explorer/testdata/string/hex.carbon | 8 +-- explorer/testdata/string/newline.carbon | 8 +-- explorer/testdata/string/raw_basic.carbon | 8 +-- .../string/raw_basic_multi_hashtag.carbon | 8 +-- explorer/testdata/string/raw_block.carbon | 8 +-- .../raw_block_escaped_back_slash.carbon | 8 +-- .../raw_block_escaped_triple_quotes.carbon | 8 +-- explorer/testdata/string/raw_nesting.carbon | 8 +-- explorer/testdata/string/unicode.carbon | 8 +-- explorer/testdata/struct/assign.carbon | 8 +-- explorer/testdata/struct/assign_member.carbon | 8 +-- explorer/testdata/struct/empty.carbon | 8 +-- explorer/testdata/struct/ending_comma.carbon | 8 +-- explorer/testdata/struct/equality.carbon | 12 ++-- .../testdata/struct/equality_false.carbon | 8 +-- .../testdata/struct/fail_equality_type.carbon | 5 +- .../struct/fail_field_access_mismatch.carbon | 8 +-- explorer/testdata/struct/name_order.carbon | 8 +-- explorer/testdata/struct/temp.carbon | 8 +-- explorer/testdata/struct/var.carbon | 8 +-- explorer/testdata/tuple/ending_comma.carbon | 8 +-- explorer/testdata/tuple/equality.carbon | 8 +-- explorer/testdata/tuple/equality_false.carbon | 8 +-- .../testdata/tuple/fail_equality_type.carbon | 5 +- explorer/testdata/tuple/fail_index.carbon | 8 +-- explorer/testdata/tuple/fail_index_var.carbon | 8 +-- explorer/testdata/tuple/fail_to_array.carbon | 8 +-- explorer/testdata/tuple/index.carbon | 8 +-- explorer/testdata/tuple/match.carbon | 8 +-- explorer/testdata/tuple/match_nested.carbon | 8 +-- .../testdata/tuple/no_ending_comma.carbon | 8 +-- explorer/testdata/tuple/to_array.carbon | 8 +-- .../control_flow_defer_to_dynamic.carbon | 8 +-- .../unformed/dynamic/fail_global.carbon | 8 +-- .../unformed/dynamic/fail_param.carbon | 8 +-- .../dynamic/fail_pattern_declare.carbon | 8 +-- .../unformed/dynamic/fail_return.carbon | 8 +-- .../unformed/dynamic/fail_returned_var.carbon | 8 +-- .../unformed/dynamic/fail_rhs_assign.carbon | 8 +-- .../unformed/global_assign_before_use.carbon | 8 +-- .../testdata/unformed/global_escape.carbon | 8 +-- .../global_unformed_without_use.carbon | 8 +-- .../unformed/local_assign_before_use.carbon | 8 +-- .../testdata/unformed/local_escape.carbon | 8 +-- .../local_unformed_without_use.carbon | 8 +-- .../testdata/unformed/pattern_declare.carbon | 8 +-- .../returned_var_assign_before_use.carbon | 8 +-- .../unformed/static/fail_field_value.carbon | 8 +-- .../unformed/static/fail_if_cond.carbon | 8 +-- .../unformed/static/fail_if_else.carbon | 8 +-- .../unformed/static/fail_if_then.carbon | 8 +-- .../static/fail_local_pattern_declare.carbon | 8 +-- .../static/fail_local_rhs_assign.carbon | 8 +-- .../unformed/static/fail_match_clause.carbon | 8 +-- .../static/fail_match_expression.carbon | 8 +-- .../unformed/static/fail_param.carbon | 8 +-- .../unformed/static/fail_return.carbon | 8 +-- .../unformed/static/fail_returned_var.carbon | 8 +-- .../unformed/static/fail_rhs_def.carbon | 8 +-- .../static/fail_struct_member_access.carbon | 8 +-- .../unformed/static/fail_while_body.carbon | 8 +-- .../unformed/static/fail_while_cond.carbon | 8 +-- explorer/testdata/while/basic.carbon | 8 +-- explorer/testdata/while/break.carbon | 8 +-- explorer/testdata/while/continue.carbon | 8 +-- .../testdata/while/convert_condition.carbon | 8 +-- explorer/update_checks.py | 4 +- toolchain/driver/testdata/carbon_test.carbon | 28 +++++----- .../driver/testdata/errors_sorted_test.carbon | 10 ++-- .../testdata/errors_streamed_test.carbon | 8 +-- toolchain/driver/testdata/lit.cfg.py | 36 +----------- toolchain/semantics/testdata/empty.carbon | 2 +- .../semantics/testdata/function/basic.carbon | 2 +- .../semantics/testdata/function/order.carbon | 2 +- toolchain/semantics/testdata/lit.cfg.py | 44 +-------------- .../testdata/return/binary_op.carbon | 2 +- .../semantics/testdata/return/literal.carbon | 2 +- .../semantics/testdata/return/trivial.carbon | 2 +- 523 files changed, 1778 insertions(+), 2847 deletions(-) create mode 100644 bazel/testing/lit.cfg.py mode change 100644 => 120000 explorer/testdata/lit.cfg.py mode change 100644 => 120000 toolchain/driver/testdata/lit.cfg.py mode change 100644 => 120000 toolchain/semantics/testdata/lit.cfg.py diff --git a/bazel/testing/lit.cfg.py b/bazel/testing/lit.cfg.py new file mode 100644 index 000000000000..7bb56f785475 --- /dev/null +++ b/bazel/testing/lit.cfg.py @@ -0,0 +1,56 @@ +__copyright__ = """ +Part of the Carbon Language project, under the Apache License v2.0 with LLVM +Exceptions. See /LICENSE for license information. +SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +""" + +import lit.formats +import os + + +# This is a provided variable, ignore the undefined name warning. +config = config # noqa: F821 + + +def fullpath(relative_path): + return os.path.join(os.environ["TEST_SRCDIR"], relative_path) + + +config.name = "lit" +config.suffixes = [".carbon"] +config.test_format = lit.formats.ShTest() + +config.substitutions.append( + ( + "%{carbon}", + fullpath("carbon/toolchain/driver/carbon"), + ) +) +_EXPLORER = "%s --prelude=%s" % ( + fullpath("carbon/explorer/explorer"), + fullpath("carbon/explorer/data/prelude.carbon"), +) +config.substitutions.append(("%{explorer}", _EXPLORER)) +config.substitutions.append( + ("%{explorer-trace}", _EXPLORER + " --parser_debug --trace_file=-") +) + +config.substitutions.append(("%{not}", fullpath("llvm-project/llvm/not"))) + +_FILE_CHECK = "%s --dump-input-filter=all" % fullpath( + "llvm-project/llvm/FileCheck" +) +config.substitutions.append(("%{FileCheck}", _FILE_CHECK)) +config.substitutions.append( + ( + "%{FileCheck-allow-unmatched}", + _FILE_CHECK + " --match-full-lines --strict-whitespace", + ) +) +config.substitutions.append( + ( + "%{FileCheck-strict}", + _FILE_CHECK + + " --implicit-check-not={{.}} --match-full-lines --strict-whitespace", + ) +) diff --git a/explorer/README.md b/explorer/README.md index 909ed75db1d6..fe1e5ef58e09 100644 --- a/explorer/README.md +++ b/explorer/README.md @@ -72,12 +72,10 @@ boilerplate at the top: // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; ``` diff --git a/explorer/interpreter/type_checker.cpp b/explorer/interpreter/type_checker.cpp index c86050e9aa97..7a1fe96aaa95 100644 --- a/explorer/interpreter/type_checker.cpp +++ b/explorer/interpreter/type_checker.cpp @@ -4334,7 +4334,7 @@ auto TypeChecker::CollectMember(Nonnull enclosing_decl, << enclosing_decl_name << " because it clashes with an existing member" << " with the same name (declared at " << it->second->source_loc() - << ") "; + << ")"; } } return Success(); diff --git a/explorer/testdata/addr/fail_method_let.carbon b/explorer/testdata/addr/fail_method_let.carbon index 5e3091a4ac06..a9db15bac7b6 100644 --- a/explorer/testdata/addr/fail_method_let.carbon +++ b/explorer/testdata/addr/fail_method_let.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -28,7 +26,7 @@ class Point { fn Main() -> i32 { let p: Point = Point.Origin(); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/addr/fail_method_let.carbon:[[@LINE+1]]: method GetSetX requires its receiver to be an lvalue + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/addr/fail_method_let.carbon:[[@LINE+1]]: method GetSetX requires its receiver to be an lvalue var x: auto = p.GetSetX(42); if (p.x == 42) { return x; diff --git a/explorer/testdata/addr/fail_method_me_misspelled.carbon b/explorer/testdata/addr/fail_method_me_misspelled.carbon index 33506bd84f42..39c13adeabd7 100644 --- a/explorer/testdata/addr/fail_method_me_misspelled.carbon +++ b/explorer/testdata/addr/fail_method_me_misspelled.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class C { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/addr/fail_method_me_misspelled.carbon:[[@LINE+1]]: illegal binding pattern in implicit parameter list + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/addr/fail_method_me_misspelled.carbon:[[@LINE+1]]: illegal binding pattern in implicit parameter list fn F[addr mew: Self*]() {} } diff --git a/explorer/testdata/addr/fail_method_me_type.carbon b/explorer/testdata/addr/fail_method_me_type.carbon index 976ab85adfd4..b560b8f9e491 100644 --- a/explorer/testdata/addr/fail_method_me_type.carbon +++ b/explorer/testdata/addr/fail_method_me_type.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -32,7 +30,7 @@ class Point { fn Main() -> i32 { var p: Point = Point.Origin(); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/addr/fail_method_me_type.carbon:[[@LINE+1]]: type error in method access, receiver type: 'class Point' is not implicitly convertible to 'class Shape' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/addr/fail_method_me_type.carbon:[[@LINE+1]]: type error in method access, receiver type: 'class Point' is not implicitly convertible to 'class Shape' var x: auto = p.GetSetX(42); if (p.x == 42) { return x; diff --git a/explorer/testdata/addr/method.carbon b/explorer/testdata/addr/method.carbon index c1e70582e070..93e7c57c2398 100644 --- a/explorer/testdata/addr/method.carbon +++ b/explorer/testdata/addr/method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/addr/nested_method.carbon b/explorer/testdata/addr/nested_method.carbon index cf35a423246e..9aca45ba4599 100644 --- a/explorer/testdata/addr/nested_method.carbon +++ b/explorer/testdata/addr/nested_method.carbon @@ -3,12 +3,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/alias/class_alias.carbon b/explorer/testdata/alias/class_alias.carbon index 754fbbe0b710..8406b85d83e2 100644 --- a/explorer/testdata/alias/class_alias.carbon +++ b/explorer/testdata/alias/class_alias.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: b.n: 1 -// CHECK: d.Get(0): 2 -// CHECK: e.Get(1): 3 -// CHECK: result: 0 +// CHECK:b.n: 1 +// CHECK:d.Get(0): 2 +// CHECK:e.Get(1): 3 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/alias/fail_alias_expression.carbon b/explorer/testdata/alias/fail_alias_expression.carbon index b37a1e0aa9fd..c6e62a13d548 100644 --- a/explorer/testdata/alias/fail_alias_expression.carbon +++ b/explorer/testdata/alias/fail_alias_expression.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_alias_expression.carbon:[[@LINE+1]]: invalid target for alias declaration +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_alias_expression.carbon:[[@LINE+1]]: invalid target for alias declaration alias A = 5; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/alias/fail_alias_var.carbon b/explorer/testdata/alias/fail_alias_var.carbon index 3819313dee13..7c37b149ab20 100644 --- a/explorer/testdata/alias/fail_alias_var.carbon +++ b/explorer/testdata/alias/fail_alias_var.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; var v: i32; // TODO: This should probably be valid if we allow global variables at all. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_alias_var.carbon:[[@LINE+1]]: invalid target for alias declaration +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_alias_var.carbon:[[@LINE+1]]: invalid target for alias declaration alias A = v; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/alias/fail_self_alias.carbon b/explorer/testdata/alias/fail_self_alias.carbon index a04eb5afaf1c..5df90ee6477b 100644 --- a/explorer/testdata/alias/fail_self_alias.carbon +++ b/explorer/testdata/alias/fail_self_alias.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_self_alias.carbon:[[@LINE+1]]: 'a' is not usable until after it has been completely declared +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/alias/fail_self_alias.carbon:[[@LINE+1]]: 'a' is not usable until after it has been completely declared alias a = a; fn Main() -> i32 { diff --git a/explorer/testdata/alias/function_alias.carbon b/explorer/testdata/alias/function_alias.carbon index b05b478eea39..faa9f6bbab06 100644 --- a/explorer/testdata/alias/function_alias.carbon +++ b/explorer/testdata/alias/function_alias.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 7 +// CHECK:result: 7 package ExplorerTest api; diff --git a/explorer/testdata/alias/interface_alias.carbon b/explorer/testdata/alias/interface_alias.carbon index 8cb3708bffa8..6e63f724d527 100644 --- a/explorer/testdata/alias/interface_alias.carbon +++ b/explorer/testdata/alias/interface_alias.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12345 +// CHECK:result: 12345 package ExplorerTest api; diff --git a/explorer/testdata/alias/member_name_alias.carbon b/explorer/testdata/alias/member_name_alias.carbon index f6da101a1a7a..f26084840645 100644 --- a/explorer/testdata/alias/member_name_alias.carbon +++ b/explorer/testdata/alias/member_name_alias.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/alias/struct_alias.carbon b/explorer/testdata/alias/struct_alias.carbon index 0a400681c3b3..05e799aca617 100644 --- a/explorer/testdata/alias/struct_alias.carbon +++ b/explorer/testdata/alias/struct_alias.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: ab.a: 2 -// CHECK: ab.b: 1 -// CHECK: ba.a: 2 -// CHECK: ba.b: 1 -// CHECK: result: 0 +// CHECK:ab.a: 2 +// CHECK:ab.b: 1 +// CHECK:ba.a: 2 +// CHECK:ba.b: 1 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/alias/type_alias.carbon b/explorer/testdata/alias/type_alias.carbon index 712e2606fb10..01c6eeef4a0e 100644 --- a/explorer/testdata/alias/type_alias.carbon +++ b/explorer/testdata/alias/type_alias.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 4 +// CHECK:result: 4 package ExplorerTest api; diff --git a/explorer/testdata/array/fail_index.carbon b/explorer/testdata/array/fail_index.carbon index 1f754fa30ad3..ec6caef395b4 100644 --- a/explorer/testdata/array/fail_index.carbon +++ b/explorer/testdata/array/fail_index.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: [i32; 2] = (0, 1); - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/array/fail_index.carbon:[[@LINE+1]]: index 2 out of range in (0, 1) + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/array/fail_index.carbon:[[@LINE+1]]: index 2 out of range in (0, 1) return x[2]; } diff --git a/explorer/testdata/array/fail_negative_size.carbon b/explorer/testdata/array/fail_negative_size.carbon index 707e5902ba6b..231eb1f60868 100644 --- a/explorer/testdata/array/fail_negative_size.carbon +++ b/explorer/testdata/array/fail_negative_size.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/array/fail_negative_size.carbon:[[@LINE+1]]: Array size cannot be negative + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/array/fail_negative_size.carbon:[[@LINE+1]]: Array size cannot be negative var x: [i32; -1] = (); return x[0]; } diff --git a/explorer/testdata/array/fail_size_mismatch.carbon b/explorer/testdata/array/fail_size_mismatch.carbon index 45693b4ae09a..bfa6b75c223c 100644 --- a/explorer/testdata/array/fail_size_mismatch.carbon +++ b/explorer/testdata/array/fail_size_mismatch.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/array/fail_size_mismatch.carbon:[[@LINE+1]]: type error in name binding: '(i32, i32, i32)' is not implicitly convertible to '[i32; 2]' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/array/fail_size_mismatch.carbon:[[@LINE+1]]: type error in name binding: '(i32, i32, i32)' is not implicitly convertible to '[i32; 2]' var x: [i32; 2] = (0, 1, 2); return x[0]; } diff --git a/explorer/testdata/array/index.carbon b/explorer/testdata/array/index.carbon index 5a7e47287b66..4f01243a4b08 100644 --- a/explorer/testdata/array/index.carbon +++ b/explorer/testdata/array/index.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/array/nested.carbon b/explorer/testdata/array/nested.carbon index 0043357aeec2..9f04efeaa1e3 100644 --- a/explorer/testdata/array/nested.carbon +++ b/explorer/testdata/array/nested.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/as/as_same_type.carbon b/explorer/testdata/as/as_same_type.carbon index 1da2ed4b38aa..d4adee86d1c5 100644 --- a/explorer/testdata/as/as_same_type.carbon +++ b/explorer/testdata/as/as_same_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/as/convert.carbon b/explorer/testdata/as/convert.carbon index 0e71efeca677..f27b2636b213 100644 --- a/explorer/testdata/as/convert.carbon +++ b/explorer/testdata/as/convert.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/as/fail_destination_not_type.carbon b/explorer/testdata/as/fail_destination_not_type.carbon index 45190fdf46b5..5b530828d249 100644 --- a/explorer/testdata/as/fail_destination_not_type.carbon +++ b/explorer/testdata/as/fail_destination_not_type.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/as/fail_destination_not_type.carbon:[[@LINE+1]]: Expected a type, but got 7 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/as/fail_destination_not_type.carbon:[[@LINE+1]]: Expected a type, but got 7 return 4 as 7; } diff --git a/explorer/testdata/as/fail_no_conversion.carbon b/explorer/testdata/as/fail_no_conversion.carbon index 6121e783f7de..651388b9a6b8 100644 --- a/explorer/testdata/as/fail_no_conversion.carbon +++ b/explorer/testdata/as/fail_no_conversion.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ class A { var n: i32; } fn Main() -> i32 { var a: A = {.n = 5}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/as/fail_no_conversion.carbon:[[@LINE+2]]: type error in `as`: `class A` is not explicitly convertible to `i32`: - // CHECK: could not find implementation of interface As(T = i32) for class A + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/as/fail_no_conversion.carbon:[[@LINE+2]]: type error in `as`: `class A` is not explicitly convertible to `i32`: + // CHECK:could not find implementation of interface As(T = i32) for class A return a as i32; } diff --git a/explorer/testdata/as/implicit_as.carbon b/explorer/testdata/as/implicit_as.carbon index d2cd3b5aec69..1d679b66f60e 100644 --- a/explorer/testdata/as/implicit_as.carbon +++ b/explorer/testdata/as/implicit_as.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/assert/assert.carbon b/explorer/testdata/assert/assert.carbon index b0469104e5c6..39ed0c87082b 100644 --- a/explorer/testdata/assert/assert.carbon +++ b/explorer/testdata/assert/assert.carbon @@ -5,12 +5,10 @@ // This won't auto-update because it uses a regex for the prelude line number, // so that it doesn't need to be updated on every prelude change. // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // NOAUTOUPDATE -// CHECK: RUNTIME ERROR: {{.*}}/explorer/data/prelude.carbon:{{.*}}: "HALLO WELT" +// CHECK:RUNTIME ERROR: {{.*}}/explorer/data/prelude.carbon:{{.*}}: "HALLO WELT" package ExplorerTest api; diff --git a/explorer/testdata/assign/convert_rhs.carbon b/explorer/testdata/assign/convert_rhs.carbon index 2bdd5b5ef9f9..febb9d6d4259 100644 --- a/explorer/testdata/assign/convert_rhs.carbon +++ b/explorer/testdata/assign/convert_rhs.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/assign/destruct_original.carbon b/explorer/testdata/assign/destruct_original.carbon index 821370954a28..9c1a61d022a1 100644 --- a/explorer/testdata/assign/destruct_original.carbon +++ b/explorer/testdata/assign/destruct_original.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/assign/reassign_original.carbon b/explorer/testdata/assign/reassign_original.carbon index b73232afa5e0..881a94da90cf 100644 --- a/explorer/testdata/assign/reassign_original.carbon +++ b/explorer/testdata/assign/reassign_original.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/assoc_const/fail_anonymous.carbon b/explorer/testdata/assoc_const/fail_anonymous.carbon index 4a12a0f09493..8a4b5ed58778 100644 --- a/explorer/testdata/assoc_const/fail_anonymous.carbon +++ b/explorer/testdata/assoc_const/fail_anonymous.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface Iface { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/assoc_const/fail_anonymous.carbon:[[@LINE+1]]: syntax error, unexpected UNDERSCORE, expecting identifier + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/assoc_const/fail_anonymous.carbon:[[@LINE+1]]: syntax error, unexpected UNDERSCORE, expecting identifier let _:! Type; } diff --git a/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon b/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon index f933a915e517..01a6c23fb856 100644 --- a/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon +++ b/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ interface HasThreeTypes { let C:! Type; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon:[[@LINE+1]]: implementation missing (.Self:! HasThreeTypes).B +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_incomplete_impl_1.carbon:[[@LINE+1]]: implementation missing (.Self:! HasThreeTypes).B external impl i32 as HasThreeTypes where .A == i32 and .C == i32 {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon b/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon index c45857f2d5a3..82af6707ffeb 100644 --- a/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon +++ b/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ interface HasThreeTypes { let C:! Type; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon:[[@LINE+1]]: implementation doesn't provide a concrete value for (.Self:! HasThreeTypes).B +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_incomplete_impl_2.carbon:[[@LINE+1]]: implementation doesn't provide a concrete value for (.Self:! HasThreeTypes).B external impl i32 as HasThreeTypes where .A == i32 and .B == .C {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/assoc_const/fail_indirectly_equal.carbon b/explorer/testdata/assoc_const/fail_indirectly_equal.carbon index 9620c4ae4f78..4afbd6845c1a 100644 --- a/explorer/testdata/assoc_const/fail_indirectly_equal.carbon +++ b/explorer/testdata/assoc_const/fail_indirectly_equal.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -25,7 +23,7 @@ fn F2[U:! A where .T == i32](x: i32) -> U.T { } fn F3[T:! A where .T == i32, U:! A where .T == i32](x: T.T) -> U.T { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_indirectly_equal.carbon:[[@LINE+1]]: type error in return value: '(T:! A where .Self.T == i32).T' is not implicitly convertible to '(U:! A where .Self.T == i32).T' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_indirectly_equal.carbon:[[@LINE+1]]: type error in return value: '(T:! A where .Self.T == i32).T' is not implicitly convertible to '(U:! A where .Self.T == i32).T' return x; } diff --git a/explorer/testdata/assoc_const/fail_match_in_deduction.carbon b/explorer/testdata/assoc_const/fail_match_in_deduction.carbon index b6b96f6bdf10..f16a0f378408 100644 --- a/explorer/testdata/assoc_const/fail_match_in_deduction.carbon +++ b/explorer/testdata/assoc_const/fail_match_in_deduction.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s // TODO: Should this work? @@ -24,7 +22,7 @@ fn F[Scalar:! Type, V:! Vector where .Dim == 3](p: Point(Scalar, V.Dim), v: V) { fn G[Scalar:! Type](p: Point(Scalar, 3)) {} fn H[V:! Vector where .Dim == 3](v: V) { var p: Point(i32, V.Dim) = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_match_in_deduction.carbon:[[@LINE+1]]: mismatch in non-type values, `(V:! Vector where .Self.Dim == 3).Dim` != `3` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_match_in_deduction.carbon:[[@LINE+1]]: mismatch in non-type values, `(V:! Vector where .Self.Dim == 3).Dim` != `3` G(p); } diff --git a/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon b/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon index 4b18ce1a9f93..59078106d467 100644 --- a/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon +++ b/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -40,7 +38,7 @@ class C(T:! Type) { external impl C(i32) as B where .TB == () { fn FB() -> () { return (); } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon:[[@LINE+1]]: ambiguous implementations of interface B for class C(T = i32) +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_multi_impl_scoping.carbon:[[@LINE+1]]: ambiguous implementations of interface B for class C(T = i32) } fn Main() -> i32 { return C(i32).FB(); } diff --git a/explorer/testdata/assoc_const/fail_multiple_deduction.carbon b/explorer/testdata/assoc_const/fail_multiple_deduction.carbon index 7c36edf00848..c9a2b75846fa 100644 --- a/explorer/testdata/assoc_const/fail_multiple_deduction.carbon +++ b/explorer/testdata/assoc_const/fail_multiple_deduction.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -18,9 +16,9 @@ interface HasThreeTypes { } fn F[T:! Type](x: (T, T, T)); fn G[X:! HasThreeTypes where .A == .B and .B == .C and .C == .A](x: X) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_multiple_deduction.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: - // CHECK: (X:! HasThreeTypes where .Self.A == .Self.B and .Self.B == .Self.C and .Self.C == .Self.A).A - // CHECK: (X:! HasThreeTypes where .Self.A == .Self.B and .Self.B == .Self.C and .Self.C == .Self.A).B + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_multiple_deduction.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: + // CHECK: (X:! HasThreeTypes where .Self.A == .Self.B and .Self.B == .Self.C and .Self.C == .Self.A).A + // CHECK: (X:! HasThreeTypes where .Self.A == .Self.B and .Self.B == .Self.C and .Self.C == .Self.A).B F(x.Make()); } diff --git a/explorer/testdata/assoc_const/fail_overspecified_impl.carbon b/explorer/testdata/assoc_const/fail_overspecified_impl.carbon index 122443b221e7..01bce3dfcad0 100644 --- a/explorer/testdata/assoc_const/fail_overspecified_impl.carbon +++ b/explorer/testdata/assoc_const/fail_overspecified_impl.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ interface HasType { let T:! Type; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_overspecified_impl.carbon:[[@LINE+1]]: implementation provides multiple values for (.Self:! HasType).T: i32 and {.a: i32} +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_overspecified_impl.carbon:[[@LINE+1]]: implementation provides multiple values for (.Self:! HasType).T: i32 and {.a: i32} external impl i32 as HasType where .T == i32 and .T == {.a: i32} {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/assoc_const/fail_redefined.carbon b/explorer/testdata/assoc_const/fail_redefined.carbon index 25a9afd9943e..2ef671524c1d 100644 --- a/explorer/testdata/assoc_const/fail_redefined.carbon +++ b/explorer/testdata/assoc_const/fail_redefined.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface Iface { let T:! Type; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_redefined.carbon:[[@LINE+1]]: Duplicate name `T` also found at {{.*}}/explorer/testdata/assoc_const/fail_redefined.carbon:14 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_redefined.carbon:[[@LINE+1]]: Duplicate name `T` also found at {{.*}}/explorer/testdata/assoc_const/fail_redefined.carbon:12 let T:! Type; } diff --git a/explorer/testdata/assoc_const/fail_unknown_value.carbon b/explorer/testdata/assoc_const/fail_unknown_value.carbon index 81ade90902b2..1ceecaedab9b 100644 --- a/explorer/testdata/assoc_const/fail_unknown_value.carbon +++ b/explorer/testdata/assoc_const/fail_unknown_value.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ interface Iface { let N:! i32; } fn PickType(N: i32) -> Type { return i32; } fn F[T:! Iface](x: T) -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_unknown_value.carbon:[[@LINE+1]]: value of associated constant (T:! Iface).N is not known + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_unknown_value.carbon:[[@LINE+1]]: value of associated constant (T:! Iface).N is not known var x: PickType(T.N) = 0; return x; } diff --git a/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon b/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon index 999b6c0b6e06..9ad53998bf78 100644 --- a/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon +++ b/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ fn PickType(N: i32) -> Type { return i32; } fn F[T:! Iface where .N == 5](x: T) -> i32 { // TODO: This should be valid: the value of T.N is known to be 5 here. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon:[[@LINE+1]]: value of associated constant (T:! Iface where .Self.N == 5).N is not known + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/assoc_const/fail_unknown_value_specified_in_constraint.carbon:[[@LINE+1]]: value of associated constant (T:! Iface where .Self.N == 5).N is not known var x: PickType(T.N) = 0; return x; } diff --git a/explorer/testdata/assoc_const/impl_lookup.carbon b/explorer/testdata/assoc_const/impl_lookup.carbon index 542fa80daec6..168032caaa83 100644 --- a/explorer/testdata/assoc_const/impl_lookup.carbon +++ b/explorer/testdata/assoc_const/impl_lookup.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/assoc_const/implement.carbon b/explorer/testdata/assoc_const/implement.carbon index 8becf1f49ed3..2daf740a1ec4 100644 --- a/explorer/testdata/assoc_const/implement.carbon +++ b/explorer/testdata/assoc_const/implement.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/assoc_const/simple_constraint.carbon b/explorer/testdata/assoc_const/simple_constraint.carbon index e6998b8e86bc..b370dbebc6b5 100644 --- a/explorer/testdata/assoc_const/simple_constraint.carbon +++ b/explorer/testdata/assoc_const/simple_constraint.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/assoc_const/simple_equality.carbon b/explorer/testdata/assoc_const/simple_equality.carbon index 25736ebda1b3..61277a82c330 100644 --- a/explorer/testdata/assoc_const/simple_equality.carbon +++ b/explorer/testdata/assoc_const/simple_equality.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/addition.carbon b/explorer/testdata/basic_syntax/addition.carbon index 29666b44af66..4fb6dd1080a9 100644 --- a/explorer/testdata/basic_syntax/addition.carbon +++ b/explorer/testdata/basic_syntax/addition.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 7 +// CHECK:result: 7 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/choice.carbon b/explorer/testdata/basic_syntax/choice.carbon index 6303f275b241..fa9f059d5a14 100644 --- a/explorer/testdata/basic_syntax/choice.carbon +++ b/explorer/testdata/basic_syntax/choice.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon b/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon index c08e81614ed0..9fe4356cbac0 100644 --- a/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon +++ b/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon:[[@LINE+1]]: Expected a type, but got (42) +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_alternative_not_type.carbon:[[@LINE+1]]: Expected a type, but got (42) choice C { X(42) } fn Main() -> i32 { diff --git a/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon b/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon index c692fc6ef035..bad56a3b8617 100644 --- a/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon +++ b/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; choice Ch { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon:[[@LINE+1]]: 'Ch' is not usable until after it has been completely declared + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_alternative_uses_choice.carbon:[[@LINE+1]]: 'Ch' is not usable until after it has been completely declared Opt(Ch) } diff --git a/explorer/testdata/basic_syntax/fail_assign_to_function.carbon b/explorer/testdata/basic_syntax/fail_assign_to_function.carbon index 3c8cbf50e189..137a317cfb57 100644 --- a/explorer/testdata/basic_syntax/fail_assign_to_function.carbon +++ b/explorer/testdata/basic_syntax/fail_assign_to_function.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ fn F() {} fn G() {} fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_assign_to_function.carbon:[[@LINE+1]]: Cannot assign to rvalue 'F' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_assign_to_function.carbon:[[@LINE+1]]: Cannot assign to rvalue 'F' F = G; return 0; } diff --git a/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon b/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon index 3c3e33f261b3..a158b46871ec 100644 --- a/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon +++ b/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon:[[@LINE+1]]: Cannot assign to rvalue '1' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_assign_to_rval.carbon:[[@LINE+1]]: Cannot assign to rvalue '1' 1 = 0; return 0; } diff --git a/explorer/testdata/basic_syntax/fail_block.carbon b/explorer/testdata/basic_syntax/fail_block.carbon index 0b7e88f43532..b8db4a04df13 100644 --- a/explorer/testdata/basic_syntax/fail_block.carbon +++ b/explorer/testdata/basic_syntax/fail_block.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_block.carbon:[[@LINE+1]]: syntax error, unexpected RETURN, expecting PERIOD or RIGHT_CURLY_BRACE + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_block.carbon:[[@LINE+1]]: syntax error, unexpected RETURN, expecting PERIOD or RIGHT_CURLY_BRACE return 0; } } diff --git a/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon b/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon index 5780bb05a801..cab244465619 100644 --- a/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon +++ b/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,9 +17,9 @@ choice Ints { fn Main() -> i32 { match (Ints.None()) { case Ints.None => { return 0; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon:[[@LINE+3]]: type error in `match` pattern type - // CHECK: expected: fn () -> choice Ints - // CHECK: actual: choice Ints + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_choice_no_parens.carbon:[[@LINE+3]]: type error in `match` pattern type + // CHECK:expected: fn () -> choice Ints + // CHECK:actual: choice Ints default => { return 1; } } } diff --git a/explorer/testdata/basic_syntax/fail_invalid_char.carbon b/explorer/testdata/basic_syntax/fail_invalid_char.carbon index d430ea7af2d4..5d7f93f703bd 100644 --- a/explorer/testdata/basic_syntax/fail_invalid_char.carbon +++ b/explorer/testdata/basic_syntax/fail_invalid_char.carbon @@ -2,11 +2,9 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_char.carbon:[[@LINE+1]]: invalid character '\xEF' in source file. +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_char.carbon:[[@LINE+1]]: invalid character '\xEF' in source file. � diff --git a/explorer/testdata/basic_syntax/fail_invalid_integer.carbon b/explorer/testdata/basic_syntax/fail_invalid_integer.carbon index 76f987fc9568..a41884fdbec3 100644 --- a/explorer/testdata/basic_syntax/fail_invalid_integer.carbon +++ b/explorer/testdata/basic_syntax/fail_invalid_integer.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_integer.carbon:[[@LINE+1]]: Invalid integer literal: 11111111111111111111111111 + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_integer.carbon:[[@LINE+1]]: Invalid integer literal: 11111111111111111111111111 return 11111111111111111111111111; } diff --git a/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon b/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon index d642e1e89cc5..f5d34f4f8e89 100644 --- a/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon +++ b/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon:[[@LINE+1]]: Invalid type literal: i11111111111111111111111111 + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_integer_type.carbon:[[@LINE+1]]: Invalid type literal: i11111111111111111111111111 var x: i11111111111111111111111111 = 1; return 0; } diff --git a/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon b/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon index 5480e1d1f477..4c4aaac9b05d 100644 --- a/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon +++ b/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon:[[@LINE+1]]: Expected expression for variable type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_invalid_var_expression.carbon:[[@LINE+1]]: Expected expression for variable type var a: auto; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/basic_syntax/fail_missing_var.carbon b/explorer/testdata/basic_syntax/fail_missing_var.carbon index 67f6d584cbf7..66881e7a2194 100644 --- a/explorer/testdata/basic_syntax/fail_missing_var.carbon +++ b/explorer/testdata/basic_syntax/fail_missing_var.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { // error - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_missing_var.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_missing_var.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * x : i32; return 1; } diff --git a/explorer/testdata/basic_syntax/fail_nested_binding.carbon b/explorer/testdata/basic_syntax/fail_nested_binding.carbon index 6b305c7d5878..114cfb719bc7 100644 --- a/explorer/testdata/basic_syntax/fail_nested_binding.carbon +++ b/explorer/testdata/basic_syntax/fail_nested_binding.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_nested_binding.carbon:[[@LINE+1]]: The type of a binding pattern cannot contain bindings. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_nested_binding.carbon:[[@LINE+1]]: The type of a binding pattern cannot contain bindings. var x: (T: Type) = 1; return 1; } diff --git a/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon b/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon index 6cf2b05b0cb2..6e2cbc6cf8c5 100644 --- a/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon +++ b/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon:[[@LINE+1]]: Unimplemented + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unimplemented_example.carbon:[[@LINE+1]]: Unimplemented return 1 __unimplemented_example_infix 2; } diff --git a/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon b/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon index 65c6baf84821..f27effd02bdf 100644 --- a/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon +++ b/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon:[[@LINE+1]]: Unknown intrinsic 'nonexistent' + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unknown_intrinsic.carbon:[[@LINE+1]]: Unknown intrinsic 'nonexistent' return __intrinsic_nonexistent(); } diff --git a/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon b/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon index fb17e15a1e6b..39ccc4b48fba 100644 --- a/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon +++ b/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon:[[@LINE+1]]: Only i32 is supported for now: i64 + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_unsupported_integer_type.carbon:[[@LINE+1]]: Only i32 is supported for now: i64 var x: i64 = 1; return 0; } diff --git a/explorer/testdata/basic_syntax/fail_var_named_self.carbon b/explorer/testdata/basic_syntax/fail_var_named_self.carbon index fbc7803c1f20..474261a6e454 100644 --- a/explorer/testdata/basic_syntax/fail_var_named_self.carbon +++ b/explorer/testdata/basic_syntax/fail_var_named_self.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ fn Main() -> i32 { // Error: can't use keyword `Self` as the name of a variable. // TODO: Current error message is unclear, better would be to say // something like: unexpected `Self`, expecting identifier - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_var_named_self.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_var_named_self.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * var Self : i32 = 0; return Self; } diff --git a/explorer/testdata/basic_syntax/fail_var_type.carbon b/explorer/testdata/basic_syntax/fail_var_type.carbon index b0b21eed5d68..70c92ec77dbd 100644 --- a/explorer/testdata/basic_syntax/fail_var_type.carbon +++ b/explorer/testdata/basic_syntax/fail_var_type.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main () -> i32 { // 42 cannot be used as the type of a variable. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_var_type.carbon:[[@LINE+1]]: Expected a type, but got 42 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/basic_syntax/fail_var_type.carbon:[[@LINE+1]]: Expected a type, but got 42 var x: 42 = 0; return x; } diff --git a/explorer/testdata/basic_syntax/next.carbon b/explorer/testdata/basic_syntax/next.carbon index 2ec3c04232a4..e1f190470b1e 100644 --- a/explorer/testdata/basic_syntax/next.carbon +++ b/explorer/testdata/basic_syntax/next.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/not_compare_precedence.carbon b/explorer/testdata/basic_syntax/not_compare_precedence.carbon index bfc37609b026..b64af43f52a6 100644 --- a/explorer/testdata/basic_syntax/not_compare_precedence.carbon +++ b/explorer/testdata/basic_syntax/not_compare_precedence.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn CompareBools(a: bool, b: bool) -> bool { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/not_compare_precedence.carbon:[[@LINE+1]]: syntax error, unexpected EQUAL_EQUAL, expecting SEMICOLON + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/basic_syntax/not_compare_precedence.carbon:[[@LINE+1]]: syntax error, unexpected EQUAL_EQUAL, expecting SEMICOLON return not a == b; } diff --git a/explorer/testdata/basic_syntax/placeholder_variable.carbon b/explorer/testdata/basic_syntax/placeholder_variable.carbon index 8e0d58dbcb75..160e6f97a75d 100644 --- a/explorer/testdata/basic_syntax/placeholder_variable.carbon +++ b/explorer/testdata/basic_syntax/placeholder_variable.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/record.carbon b/explorer/testdata/basic_syntax/record.carbon index 1612cbbeee72..0e98a6b28082 100644 --- a/explorer/testdata/basic_syntax/record.carbon +++ b/explorer/testdata/basic_syntax/record.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/star.carbon b/explorer/testdata/basic_syntax/star.carbon index 3fce44e856e7..561ff07b8116 100644 --- a/explorer/testdata/basic_syntax/star.carbon +++ b/explorer/testdata/basic_syntax/star.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/trace.carbon b/explorer/testdata/basic_syntax/trace.carbon index b38caa4626ee..3a68cc0122d7 100644 --- a/explorer/testdata/basic_syntax/trace.carbon +++ b/explorer/testdata/basic_syntax/trace.carbon @@ -2,25 +2,24 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // // A lot of output is elided: this is only checking for a few things for simple // sanity checking on --parser_debug --trace_file=- output. // // NOAUTOUPDATE -// CHECK: ********** source program ********** -// CHECK: interface ImplicitAs { -// CHECK: ********** type checking ********** -// CHECK: ** declaring interface ImplicitAs -// CHECK: ********** resolving unformed variables ********** -// CHECK: ********** printing declarations ********** -// CHECK: interface ImplicitAs { -// CHECK: ********** starting execution ********** -// CHECK: ********** initializing globals ********** -// CHECK: ********** calling main function ********** -// CHECK: --- step exp Main() .0. (:0) ---> -// CHECK: result: 0 +// CHECK:********** source program ********** +// CHECK:interface ImplicitAs { +// CHECK:********** type checking ********** +// CHECK:** declaring interface ImplicitAs +// CHECK:********** resolving unformed variables ********** +// CHECK:********** printing declarations ********** +// CHECK:interface ImplicitAs { +// CHECK:********** starting execution ********** +// CHECK:********** initializing globals ********** +// CHECK:********** calling main function ********** +// CHECK:--- step exp Main() .0. (:0) ---> +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/var_tuple.carbon b/explorer/testdata/basic_syntax/var_tuple.carbon index b3c503a823fe..28101557560f 100644 --- a/explorer/testdata/basic_syntax/var_tuple.carbon +++ b/explorer/testdata/basic_syntax/var_tuple.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/basic_syntax/zero.carbon b/explorer/testdata/basic_syntax/zero.carbon index ceccaab4a654..cadff806651e 100644 --- a/explorer/testdata/basic_syntax/zero.carbon +++ b/explorer/testdata/basic_syntax/zero.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/block/empty.carbon b/explorer/testdata/block/empty.carbon index b10b299358bc..8bddf9538e05 100644 --- a/explorer/testdata/block/empty.carbon +++ b/explorer/testdata/block/empty.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/block/shadowing.carbon b/explorer/testdata/block/shadowing.carbon index b6bdaa724b55..71c9187d315e 100644 --- a/explorer/testdata/block/shadowing.carbon +++ b/explorer/testdata/block/shadowing.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/choice/generic_choice_multiple_template_arguments.carbon b/explorer/testdata/choice/generic_choice_multiple_template_arguments.carbon index 02948a04988f..192d99216d7d 100644 --- a/explorer/testdata/choice/generic_choice_multiple_template_arguments.carbon +++ b/explorer/testdata/choice/generic_choice_multiple_template_arguments.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 22 +// CHECK:result: 22 package ExplorerTest api; diff --git a/explorer/testdata/choice/generic_choice_nested_in_template_class.carbon b/explorer/testdata/choice/generic_choice_nested_in_template_class.carbon index 93a0a9fe5d25..0f213d3534d4 100644 --- a/explorer/testdata/choice/generic_choice_nested_in_template_class.carbon +++ b/explorer/testdata/choice/generic_choice_nested_in_template_class.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: H 22 -// CHECK: result: 0 +// CHECK:H 22 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/choice/generic_choice_simple_assignment.carbon b/explorer/testdata/choice/generic_choice_simple_assignment.carbon index 6b9f00fc2f13..8190ae220573 100644 --- a/explorer/testdata/choice/generic_choice_simple_assignment.carbon +++ b/explorer/testdata/choice/generic_choice_simple_assignment.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 22 +// CHECK:result: 22 package ExplorerTest api; diff --git a/explorer/testdata/class/assign.carbon b/explorer/testdata/class/assign.carbon index fad9ea710496..4225afa83f3e 100644 --- a/explorer/testdata/class/assign.carbon +++ b/explorer/testdata/class/assign.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/assign_member.carbon b/explorer/testdata/class/assign_member.carbon index e1d73002897c..36c2ef3ef74b 100644 --- a/explorer/testdata/class/assign_member.carbon +++ b/explorer/testdata/class/assign_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/bound_method.carbon b/explorer/testdata/class/bound_method.carbon index 0d73ebed84eb..9d18fada7646 100644 --- a/explorer/testdata/class/bound_method.carbon +++ b/explorer/testdata/class/bound_method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/class_function.carbon b/explorer/testdata/class/class_function.carbon index c5a813c38988..c3866c400e2a 100644 --- a/explorer/testdata/class/class_function.carbon +++ b/explorer/testdata/class/class_function.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/class_function_from_instance.carbon b/explorer/testdata/class/class_function_from_instance.carbon index db21ba27d4db..0a3de685e89a 100644 --- a/explorer/testdata/class/class_function_from_instance.carbon +++ b/explorer/testdata/class/class_function_from_instance.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/class_function_self.carbon b/explorer/testdata/class/class_function_self.carbon index 0f1aa6e85bc2..757922ba7b60 100644 --- a/explorer/testdata/class/class_function_self.carbon +++ b/explorer/testdata/class/class_function_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/class_function_value.carbon b/explorer/testdata/class/class_function_value.carbon index 15d70cf5d569..0fe9ec00f75a 100644 --- a/explorer/testdata/class/class_function_value.carbon +++ b/explorer/testdata/class/class_function_value.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/empty_class.carbon b/explorer/testdata/class/empty_class.carbon index 3133a683c777..d877358eb5a1 100644 --- a/explorer/testdata/class/empty_class.carbon +++ b/explorer/testdata/class/empty_class.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/fail_abstract_class.carbon b/explorer/testdata/class/fail_abstract_class.carbon index aae01dd79890..5eb3f03d927c 100644 --- a/explorer/testdata/class/fail_abstract_class.carbon +++ b/explorer/testdata/class/fail_abstract_class.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; abstract class C { fn F() {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_abstract_class.carbon:[[@LINE+1]]: Class prefixes `base` and `abstract` are not supported yet +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_abstract_class.carbon:[[@LINE+1]]: Class prefixes `base` and `abstract` are not supported yet } fn Main() -> i32 { diff --git a/explorer/testdata/class/fail_base_class.carbon b/explorer/testdata/class/fail_base_class.carbon index a22d39e113a9..37163632be3e 100644 --- a/explorer/testdata/class/fail_base_class.carbon +++ b/explorer/testdata/class/fail_base_class.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; base class C { fn F() {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_base_class.carbon:[[@LINE+1]]: Class prefixes `base` and `abstract` are not supported yet +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_base_class.carbon:[[@LINE+1]]: Class prefixes `base` and `abstract` are not supported yet } fn Main() -> i32 { diff --git a/explorer/testdata/class/fail_class_extends.carbon b/explorer/testdata/class/fail_class_extends.carbon index fba1c7013991..ffcc95b32358 100644 --- a/explorer/testdata/class/fail_class_extends.carbon +++ b/explorer/testdata/class/fail_class_extends.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class A { class B extends A { fn F() {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_class_extends.carbon:[[@LINE+1]]: Class extension with `extends` is not supported yet +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_class_extends.carbon:[[@LINE+1]]: Class extension with `extends` is not supported yet } fn Main() -> i32 { diff --git a/explorer/testdata/class/fail_class_named_self.carbon b/explorer/testdata/class/fail_class_named_self.carbon index e65f677a9744..0a3de792cb42 100644 --- a/explorer/testdata/class/fail_class_named_self.carbon +++ b/explorer/testdata/class/fail_class_named_self.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // Error: Can't use keyword `Self` as the name of a class. -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/class/fail_class_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/class/fail_class_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier class Self { var x: i32; var y: i32; diff --git a/explorer/testdata/class/fail_field_access_mismatch.carbon b/explorer/testdata/class/fail_field_access_mismatch.carbon index eb2db096a42f..40cb7841e665 100644 --- a/explorer/testdata/class/fail_field_access_mismatch.carbon +++ b/explorer/testdata/class/fail_field_access_mismatch.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,6 +15,6 @@ class Point { fn Main() -> i32 { var p: Point = {.x = 1, .y = 2}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_access_mismatch.carbon:[[@LINE+1]]: class Point does not have a field named z + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_access_mismatch.carbon:[[@LINE+1]]: class Point does not have a field named z return p.z - 1; } diff --git a/explorer/testdata/class/fail_field_mismatch.carbon b/explorer/testdata/class/fail_field_mismatch.carbon index d1791463a20b..173ad477606b 100644 --- a/explorer/testdata/class/fail_field_mismatch.carbon +++ b/explorer/testdata/class/fail_field_mismatch.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class Point { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_mismatch.carbon:[[@LINE+1]]: type error in name binding: '{.x: i32, .z: i32}' is not implicitly convertible to 'class Point' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_mismatch.carbon:[[@LINE+1]]: type error in name binding: '{.x: i32, .z: i32}' is not implicitly convertible to 'class Point' var p: Point = {.x = 1, .z = 2}; return p.x - 1; } diff --git a/explorer/testdata/class/fail_field_missing.carbon b/explorer/testdata/class/fail_field_missing.carbon index 37d3795386d0..7cfa17de9810 100644 --- a/explorer/testdata/class/fail_field_missing.carbon +++ b/explorer/testdata/class/fail_field_missing.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class Point { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_missing.carbon:[[@LINE+1]]: type error in name binding: '{.x: i32}' is not implicitly convertible to 'class Point' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_field_missing.carbon:[[@LINE+1]]: type error in name binding: '{.x: i32}' is not implicitly convertible to 'class Point' var p: Point = {.x = 1}; return p.x - 1; } diff --git a/explorer/testdata/class/fail_method_deduced.carbon b/explorer/testdata/class/fail_method_deduced.carbon index f011182006db..b7084bccfd93 100644 --- a/explorer/testdata/class/fail_method_deduced.carbon +++ b/explorer/testdata/class/fail_method_deduced.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,7 +17,7 @@ fn H[T:! Type](x: T) {} fn Main() -> i32 { H(C.F); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_deduced.carbon:[[@LINE+1]]: Expected a type, but got member name G + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_deduced.carbon:[[@LINE+1]]: Expected a type, but got member name G H(C.G); return 0; } diff --git a/explorer/testdata/class/fail_method_from_class.carbon b/explorer/testdata/class/fail_method_from_class.carbon index 414747b9f08e..1fe7507da879 100644 --- a/explorer/testdata/class/fail_method_from_class.carbon +++ b/explorer/testdata/class/fail_method_from_class.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -24,6 +22,6 @@ class Point { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_from_class.carbon:[[@LINE+1]]: in call `Point.GetX()`, expected callee to be a function, found `member name GetX` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_from_class.carbon:[[@LINE+1]]: in call `Point.GetX()`, expected callee to be a function, found `member name GetX` return Point.GetX(); } diff --git a/explorer/testdata/class/fail_method_in_var.carbon b/explorer/testdata/class/fail_method_in_var.carbon index 58cfdfd42bbf..6b8cde19cd30 100644 --- a/explorer/testdata/class/fail_method_in_var.carbon +++ b/explorer/testdata/class/fail_method_in_var.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ class C { fn Main() -> i32 { var f: auto = C.F; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_in_var.carbon:[[@LINE+1]]: Expected a type, but got member name G + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_method_in_var.carbon:[[@LINE+1]]: Expected a type, but got member name G var g: auto = C.G; return 0; diff --git a/explorer/testdata/class/fail_return_method.carbon b/explorer/testdata/class/fail_return_method.carbon index ef6e05ecf013..147bbe71a20f 100644 --- a/explorer/testdata/class/fail_return_method.carbon +++ b/explorer/testdata/class/fail_return_method.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class C { } fn ReturnF() -> auto { return C.F; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_return_method.carbon:[[@LINE+1]]: Expected a type, but got member name G +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/class/fail_return_method.carbon:[[@LINE+1]]: Expected a type, but got member name G fn ReturnG() -> auto { return C.G; } fn Main() -> i32 { diff --git a/explorer/testdata/class/function_param.carbon b/explorer/testdata/class/function_param.carbon index 12c66fbbe0ba..b210109ce4d5 100644 --- a/explorer/testdata/class/function_param.carbon +++ b/explorer/testdata/class/function_param.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/global_var.carbon b/explorer/testdata/class/global_var.carbon index 7ba15504f2d8..a09930d1ed62 100644 --- a/explorer/testdata/class/global_var.carbon +++ b/explorer/testdata/class/global_var.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/method.carbon b/explorer/testdata/class/method.carbon index 64871158213b..876cfe2d4995 100644 --- a/explorer/testdata/class/method.carbon +++ b/explorer/testdata/class/method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/method_call_method.carbon b/explorer/testdata/class/method_call_method.carbon index dd72eb81846e..1e52aa1681b0 100644 --- a/explorer/testdata/class/method_call_method.carbon +++ b/explorer/testdata/class/method_call_method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/method_self.carbon b/explorer/testdata/class/method_self.carbon index af7a184e0aaa..c079a9b89c5b 100644 --- a/explorer/testdata/class/method_self.carbon +++ b/explorer/testdata/class/method_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/temp.carbon b/explorer/testdata/class/temp.carbon index d64a203c561c..48f83df76f8a 100644 --- a/explorer/testdata/class/temp.carbon +++ b/explorer/testdata/class/temp.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/class/var.carbon b/explorer/testdata/class/var.carbon index ab70055f5f9f..9acfbd7ccf6d 100644 --- a/explorer/testdata/class/var.carbon +++ b/explorer/testdata/class/var.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/comparison/builtin_comparsion.carbon b/explorer/testdata/comparison/builtin_comparsion.carbon index 5dddd2c890e2..1a70a679b9f4 100644 --- a/explorer/testdata/comparison/builtin_comparsion.carbon +++ b/explorer/testdata/comparison/builtin_comparsion.carbon @@ -2,20 +2,18 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: strings less: 1 -// CHECK: ints less: 0 -// CHECK: strings less eq: 1 -// CHECK: ints less eq: 1 -// CHECK: strings greater: 0 -// CHECK: ints greater: 0 -// CHECK: strings greater eq: 0 -// CHECK: ints greater eq: 1 -// CHECK: result: 0 +// CHECK:strings less: 1 +// CHECK:ints less: 0 +// CHECK:strings less eq: 1 +// CHECK:ints less eq: 1 +// CHECK:strings greater: 0 +// CHECK:ints greater: 0 +// CHECK:strings greater eq: 0 +// CHECK:ints greater eq: 1 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/comparison/builtin_equality.carbon b/explorer/testdata/comparison/builtin_equality.carbon index 601f5da50bce..0a12b1d34bc3 100644 --- a/explorer/testdata/comparison/builtin_equality.carbon +++ b/explorer/testdata/comparison/builtin_equality.carbon @@ -2,36 +2,34 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: bool: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: string: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: int: 1 -// CHECK: result: 0 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:bool: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:string: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:int: 1 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/comparison/custom_equality.carbon b/explorer/testdata/comparison/custom_equality.carbon index d243a8dab55c..558974d76be7 100644 --- a/explorer/testdata/comparison/custom_equality.carbon +++ b/explorer/testdata/comparison/custom_equality.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: structs equal: 0 -// CHECK: structs not equal: 1 -// CHECK: result: 0 +// CHECK:structs equal: 0 +// CHECK:structs not equal: 1 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/comparison/fail_empty_struct.carbon b/explorer/testdata/comparison/fail_empty_struct.carbon index d09a2b189dfb..b7a71614724b 100644 --- a/explorer/testdata/comparison/fail_empty_struct.carbon +++ b/explorer/testdata/comparison/fail_empty_struct.carbon @@ -2,13 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 2>&1 | %{FileCheck} %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // TODO: This should work -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/comparison/fail_empty_struct.carbon:[[@LINE+1]]: type error in call: '{}' is not implicitly convertible to 'Type' +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/comparison/fail_empty_struct.carbon:[[@LINE+1]]: type error in call: '{}' is not implicitly convertible to 'Type' external impl {} as EqWith({}) { fn Equal[me: Self](other: Self) -> bool { return true; diff --git a/explorer/testdata/comparison/fail_no_impl.carbon b/explorer/testdata/comparison/fail_no_impl.carbon index 3a52076ddbce..01d51ee48c2c 100644 --- a/explorer/testdata/comparison/fail_no_impl.carbon +++ b/explorer/testdata/comparison/fail_no_impl.carbon @@ -2,13 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 2>&1 | %{FileCheck} %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/comparison/fail_no_impl.carbon:[[@LINE+1]]: i32 is not equality comparable with String (could not find implementation of interface EqWith(U = String) for i32) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/comparison/fail_no_impl.carbon:[[@LINE+1]]: i32 is not equality comparable with String (could not find implementation of interface EqWith(U = String) for i32) Print("different types equal: {0}", if 1 == "1" then 1 else 0); return 0; } diff --git a/explorer/testdata/constraint/binding_self.carbon b/explorer/testdata/constraint/binding_self.carbon index 3ef0e6c2040c..216c84933899 100644 --- a/explorer/testdata/constraint/binding_self.carbon +++ b/explorer/testdata/constraint/binding_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12 +// CHECK:result: 12 package ExplorerTest api; diff --git a/explorer/testdata/constraint/combined_interfaces.carbon b/explorer/testdata/constraint/combined_interfaces.carbon index b044544e769c..934a2d8f6b14 100644 --- a/explorer/testdata/constraint/combined_interfaces.carbon +++ b/explorer/testdata/constraint/combined_interfaces.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 526 +// CHECK:result: 526 package ExplorerTest api; diff --git a/explorer/testdata/constraint/dot_self_is_other.carbon b/explorer/testdata/constraint/dot_self_is_other.carbon index 6bee40ffa8a7..9506314c4337 100644 --- a/explorer/testdata/constraint/dot_self_is_other.carbon +++ b/explorer/testdata/constraint/dot_self_is_other.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12 +// CHECK:result: 12 package ExplorerTest api; diff --git a/explorer/testdata/constraint/fail_ambiguous_member.carbon b/explorer/testdata/constraint/fail_ambiguous_member.carbon index 33ecde91c2ff..99af5bcbdbbb 100644 --- a/explorer/testdata/constraint/fail_ambiguous_member.carbon +++ b/explorer/testdata/constraint/fail_ambiguous_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface A { fn F() -> i32; } interface B { fn F() -> i32; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_ambiguous_member.carbon:[[@LINE+1]]: ambiguous member access, F found in interface A and interface B +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_ambiguous_member.carbon:[[@LINE+1]]: ambiguous member access, F found in interface A and interface B fn Get[T:! A & B](n: T) -> i32 { return n.F(); } impl i32 as A { diff --git a/explorer/testdata/constraint/fail_dot_self_after_scope.carbon b/explorer/testdata/constraint/fail_dot_self_after_scope.carbon index dcf15c7db576..12acb7eda8fe 100644 --- a/explorer/testdata/constraint/fail_dot_self_after_scope.carbon +++ b/explorer/testdata/constraint/fail_dot_self_after_scope.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface FrobWith(T:! Type) {} fn F[T:! FrobWith(.Self)] - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_after_scope.carbon:[[@LINE+1]]: could not resolve '.Self' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_after_scope.carbon:[[@LINE+1]]: could not resolve '.Self' (U: .Self) { } diff --git a/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon b/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon index c586f9609f70..5532df470e91 100644 --- a/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon +++ b/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface FrobWith(T:! Type) {} fn F[T:! FrobWith(.Self), - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `U` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_after_scope_2.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `U` U:! .Self]() { } diff --git a/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon b/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon index d7a9684ad702..ddee0b30257f 100644 --- a/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon +++ b/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon:[[@LINE+1]]: could not resolve '.Self' +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_dot_self_not_in_scope.carbon:[[@LINE+1]]: could not resolve '.Self' fn Main() -> .Self { return 0; } diff --git a/explorer/testdata/constraint/fail_infinite_self.carbon b/explorer/testdata/constraint/fail_infinite_self.carbon index d9de04374912..cb517b5c9a7a 100644 --- a/explorer/testdata/constraint/fail_infinite_self.carbon +++ b/explorer/testdata/constraint/fail_infinite_self.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_infinite_self.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_infinite_self.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` fn F[T:! .Self]() {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_infinite_self_ptr.carbon b/explorer/testdata/constraint/fail_infinite_self_ptr.carbon index efa75f1d6a84..b35ca237fce7 100644 --- a/explorer/testdata/constraint/fail_infinite_self_ptr.carbon +++ b/explorer/testdata/constraint/fail_infinite_self_ptr.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_infinite_self_ptr.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_infinite_self_ptr.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` fn F[T:! .Self*]() {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_non_type_self.carbon b/explorer/testdata/constraint/fail_non_type_self.carbon index 56f8ef358696..f2d9b678159d 100644 --- a/explorer/testdata/constraint/fail_non_type_self.carbon +++ b/explorer/testdata/constraint/fail_non_type_self.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class X(T:! Type) {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_non_type_self.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_non_type_self.carbon:[[@LINE+1]]: `.Self` used in type of non-type binding `T` fn F[T:! X(.Self)](x: T) {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_where_equals_different_types.carbon b/explorer/testdata/constraint/fail_where_equals_different_types.carbon index d8257a1e33dd..e6f6ef07d503 100644 --- a/explorer/testdata/constraint/fail_where_equals_different_types.carbon +++ b/explorer/testdata/constraint/fail_where_equals_different_types.carbon @@ -2,19 +2,17 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface A {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_equals_different_types.carbon:[[@LINE+3]]: type mismatch between values in `where LHS == RHS` -// CHECK: LHS type: i32 -// CHECK: RHS type: Type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_equals_different_types.carbon:[[@LINE+3]]: type mismatch between values in `where LHS == RHS` +// CHECK: LHS type: i32 +// CHECK: RHS type: Type alias B = A where 4 == i32; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_where_is_non_constraint.carbon b/explorer/testdata/constraint/fail_where_is_non_constraint.carbon index 76421268eb85..0261b91a3a05 100644 --- a/explorer/testdata/constraint/fail_where_is_non_constraint.carbon +++ b/explorer/testdata/constraint/fail_where_is_non_constraint.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface A {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_is_non_constraint.carbon:[[@LINE+1]]: expression after `is` does not resolve to a constraint, found value i32 of type Type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_is_non_constraint.carbon:[[@LINE+1]]: expression after `is` does not resolve to a constraint, found value i32 of type Type alias B = A where i32 is i32; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_where_is_non_type.carbon b/explorer/testdata/constraint/fail_where_is_non_type.carbon index f20429429078..d1304d6b9500 100644 --- a/explorer/testdata/constraint/fail_where_is_non_type.carbon +++ b/explorer/testdata/constraint/fail_where_is_non_type.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface A {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_is_non_type.carbon:[[@LINE+1]]: expression after `is` does not resolve to a constraint, found i32 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_is_non_type.carbon:[[@LINE+1]]: expression after `is` does not resolve to a constraint, found i32 alias B = A where i32 is 5; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/fail_where_non_type_is.carbon b/explorer/testdata/constraint/fail_where_non_type_is.carbon index a132a7276c60..4c0cdd599e4b 100644 --- a/explorer/testdata/constraint/fail_where_non_type_is.carbon +++ b/explorer/testdata/constraint/fail_where_non_type_is.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface A {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_non_type_is.carbon:[[@LINE+1]]: Expected a type, but got 4 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/fail_where_non_type_is.carbon:[[@LINE+1]]: Expected a type, but got 4 alias B = A where 4 is A; fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/constraint/missing_member.carbon b/explorer/testdata/constraint/missing_member.carbon index f8dda156cd10..96ca63b9d918 100644 --- a/explorer/testdata/constraint/missing_member.carbon +++ b/explorer/testdata/constraint/missing_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface A { fn F() -> i32; } interface B { fn G() -> i32; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/missing_member.carbon:[[@LINE+1]]: member access, H not in constraint interface A & interface B where .Self:! Type is interface A and .Self:! Type is interface B +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/missing_member.carbon:[[@LINE+1]]: member access, H not in constraint interface A & interface B where .Self:! Type is interface A and .Self:! Type is interface B fn Get[T:! A & B](n: T) -> i32 { return n.H(); } impl i32 as A { diff --git a/explorer/testdata/constraint/no_combine_equality.carbon b/explorer/testdata/constraint/no_combine_equality.carbon index 7ff785ec031d..023d4f46e280 100644 --- a/explorer/testdata/constraint/no_combine_equality.carbon +++ b/explorer/testdata/constraint/no_combine_equality.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ impl i32 as I {} fn F(A:! i32, B:! i32, C:! i32, D:! i32, E:! i32, T:! I where A == B and C == D and C == E and B == D) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/no_combine_equality.carbon:[[@LINE+1]]: member access, F not in constraint interface I where .Self:! I is interface I and A:! i32 == B:! i32 and C:! i32 == D:! i32 and C:! i32 == E:! i32 and B:! i32 == D:! i32 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/constraint/no_combine_equality.carbon:[[@LINE+1]]: member access, F not in constraint interface I where .Self:! I is interface I and A:! i32 == B:! i32 and C:! i32 == D:! i32 and C:! i32 == E:! i32 and B:! i32 == D:! i32 T.F(); } diff --git a/explorer/testdata/constraint/nondependent_where.carbon b/explorer/testdata/constraint/nondependent_where.carbon index b151286415b0..b5d9aa23efe0 100644 --- a/explorer/testdata/constraint/nondependent_where.carbon +++ b/explorer/testdata/constraint/nondependent_where.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/constraint/qualified_lookup_in_where.carbon b/explorer/testdata/constraint/qualified_lookup_in_where.carbon index 04460eaa7cf6..cd51301b3ab6 100644 --- a/explorer/testdata/constraint/qualified_lookup_in_where.carbon +++ b/explorer/testdata/constraint/qualified_lookup_in_where.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 122 +// CHECK:result: 122 package ExplorerTest api; diff --git a/explorer/testdata/constraint/where_self.carbon b/explorer/testdata/constraint/where_self.carbon index 3abf0d78ef6c..467626603b5b 100644 --- a/explorer/testdata/constraint/where_self.carbon +++ b/explorer/testdata/constraint/where_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12 +// CHECK:result: 12 package ExplorerTest api; diff --git a/explorer/testdata/destructor/call_destructor_from_destructor.carbon b/explorer/testdata/destructor/call_destructor_from_destructor.carbon index 5d0c792183a9..93df6b9bd692 100644 --- a/explorer/testdata/destructor/call_destructor_from_destructor.carbon +++ b/explorer/testdata/destructor/call_destructor_from_destructor.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR A 1 -// CHECK: DESTRUCTOR B 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: DESTRUCTOR A 4 -// CHECK: result: 1 +// CHECK:DESTRUCTOR A 1 +// CHECK:DESTRUCTOR B 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:DESTRUCTOR A 4 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/destructor/destructor_with_return.carbon b/explorer/testdata/destructor/destructor_with_return.carbon index 1f04732b0ace..93d85a61931c 100644 --- a/explorer/testdata/destructor/destructor_with_return.carbon +++ b/explorer/testdata/destructor/destructor_with_return.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR A 3 -// CHECK: result: 1 +// CHECK:DESTRUCTOR A 3 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon b/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon index 74aa50c7a256..444866d95c07 100644 --- a/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon +++ b/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon @@ -2,7 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 2>&1 | %{FileCheck} %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +14,7 @@ class A{ } destructor[me: Self]{ Print("DESTRUCTOR A2 {0}",me.n); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon:[[@LINE+1]]: Duplicate name `destructor` also found at {{.*}}/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon:13 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon:[[@LINE+1]]: Duplicate name `destructor` also found at {{.*}}/explorer/testdata/destructor/fail_multiple_destructor_declaration.carbon:14 } var n: i32; } diff --git a/explorer/testdata/destructor/function_with_return.carbon b/explorer/testdata/destructor/function_with_return.carbon index 66bdaa503ec0..7c0767faf620 100644 --- a/explorer/testdata/destructor/function_with_return.carbon +++ b/explorer/testdata/destructor/function_with_return.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR C 1 -// CHECK: DESTRUCTOR B 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: result: 1 +// CHECK:DESTRUCTOR C 1 +// CHECK:DESTRUCTOR B 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/destructor/loop_block.carbon b/explorer/testdata/destructor/loop_block.carbon index bfa3193fce9b..0d2534d7830d 100644 --- a/explorer/testdata/destructor/loop_block.carbon +++ b/explorer/testdata/destructor/loop_block.carbon @@ -2,18 +2,16 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR A 1 -// CHECK: DESTRUCTOR A 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: DESTRUCTOR A 1 -// CHECK: DESTRUCTOR A 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: result: 1 +// CHECK:DESTRUCTOR A 1 +// CHECK:DESTRUCTOR A 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:DESTRUCTOR A 1 +// CHECK:DESTRUCTOR A 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/destructor/loop_break_continue.carbon b/explorer/testdata/destructor/loop_break_continue.carbon index f76b17ec6c25..7b6dddad6ead 100644 --- a/explorer/testdata/destructor/loop_break_continue.carbon +++ b/explorer/testdata/destructor/loop_break_continue.carbon @@ -2,23 +2,21 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR A 1 -// CHECK: DESTRUCTOR A 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: DESTRUCTOR A 4 -// CHECK: DESTRUCTOR A 5 -// CHECK: DESTRUCTOR A 6 -// CHECK: DESTRUCTOR A 7 -// CHECK: DESTRUCTOR A 8 -// CHECK: DESTRUCTOR A 6 -// CHECK: DESTRUCTOR A 7 -// CHECK: DESTRUCTOR A 8 -// CHECK: result: 1 +// CHECK:DESTRUCTOR A 1 +// CHECK:DESTRUCTOR A 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:DESTRUCTOR A 4 +// CHECK:DESTRUCTOR A 5 +// CHECK:DESTRUCTOR A 6 +// CHECK:DESTRUCTOR A 7 +// CHECK:DESTRUCTOR A 8 +// CHECK:DESTRUCTOR A 6 +// CHECK:DESTRUCTOR A 7 +// CHECK:DESTRUCTOR A 8 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/destructor/nested_block_with_return.carbon b/explorer/testdata/destructor/nested_block_with_return.carbon index e5ffa2d68d10..fe4bcf7370f8 100644 --- a/explorer/testdata/destructor/nested_block_with_return.carbon +++ b/explorer/testdata/destructor/nested_block_with_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: DESTRUCTOR A 1 -// CHECK: DESTRUCTOR A 2 -// CHECK: DESTRUCTOR A 3 -// CHECK: DESTRUCTOR A 4 -// CHECK: result: 2 +// CHECK:DESTRUCTOR A 1 +// CHECK:DESTRUCTOR A 2 +// CHECK:DESTRUCTOR A 3 +// CHECK:DESTRUCTOR A 4 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/await_maintains_scope.carbon b/explorer/testdata/experimental_continuation/await_maintains_scope.carbon index e643268b1f20..c7567a910536 100644 --- a/explorer/testdata/experimental_continuation/await_maintains_scope.carbon +++ b/explorer/testdata/experimental_continuation/await_maintains_scope.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/convert_run.carbon b/explorer/testdata/experimental_continuation/convert_run.carbon index c3a08f2c9fec..ff45f9516544 100644 --- a/explorer/testdata/experimental_continuation/convert_run.carbon +++ b/explorer/testdata/experimental_continuation/convert_run.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/creation_is_noop.carbon b/explorer/testdata/experimental_continuation/creation_is_noop.carbon index 6ef28af2af34..ba8e89c7a5f2 100644 --- a/explorer/testdata/experimental_continuation/creation_is_noop.carbon +++ b/explorer/testdata/experimental_continuation/creation_is_noop.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon b/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon index ba8c07515646..56a5a2153ad0 100644 --- a/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon +++ b/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn f() -> auto { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_auto_return_await.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement __await; } diff --git a/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon b/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon index edc3985c8797..9d14d5160993 100644 --- a/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon +++ b/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32 = 0; - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon:[[@LINE+1]]: syntax error, unexpected identifier, expecting LEFT_CURLY_BRACE + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_continuation_syntax.carbon:[[@LINE+1]]: syntax error, unexpected identifier, expecting LEFT_CURLY_BRACE __continuation k x = 3; __run k; return x; diff --git a/explorer/testdata/experimental_continuation/fail_lifetime.carbon b/explorer/testdata/experimental_continuation/fail_lifetime.carbon index ac9961ab2f94..0f95d2546bcb 100644 --- a/explorer/testdata/experimental_continuation/fail_lifetime.carbon +++ b/explorer/testdata/experimental_continuation/fail_lifetime.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ package ExplorerTest api; fn capture() -> __Continuation { var x: i32 = 1; __continuation k { - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_lifetime.carbon:[[@LINE+1]]: undefined behavior: access to dead value 1 + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_lifetime.carbon:[[@LINE+1]]: undefined behavior: access to dead value 1 var y: i32 = x; } return k; diff --git a/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon b/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon index c53d5c769885..f793108f6215 100644 --- a/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon +++ b/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn f() { __continuation k { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon:[[@LINE+1]]: 'k' is not usable until after it has been completely declared + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_recursive_continuation.carbon:[[@LINE+1]]: 'k' is not usable until after it has been completely declared __run k; } } diff --git a/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon b/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon index 36119c62fb6c..92e4cfdd37ed 100644 --- a/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon +++ b/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ fn Main() -> i32 { var x: i32 = 0; __continuation k { x = x + 1; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon:[[@LINE+1]]: return is not within a function body + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/experimental_continuation/fail_return_in_continuation.carbon:[[@LINE+1]]: return is not within a function body return x; } } diff --git a/explorer/testdata/experimental_continuation/recursive.carbon b/explorer/testdata/experimental_continuation/recursive.carbon index 630a60c6339c..acfec0867b9f 100644 --- a/explorer/testdata/experimental_continuation/recursive.carbon +++ b/explorer/testdata/experimental_continuation/recursive.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 10 +// CHECK:result: 10 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/run.carbon b/explorer/testdata/experimental_continuation/run.carbon index f0eda1f87530..dcd4bf559da5 100644 --- a/explorer/testdata/experimental_continuation/run.carbon +++ b/explorer/testdata/experimental_continuation/run.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/run_with_await.carbon b/explorer/testdata/experimental_continuation/run_with_await.carbon index 432bc60577a8..b2b01b27ca12 100644 --- a/explorer/testdata/experimental_continuation/run_with_await.carbon +++ b/explorer/testdata/experimental_continuation/run_with_await.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/experimental_continuation/shallow_copy.carbon b/explorer/testdata/experimental_continuation/shallow_copy.carbon index 8383bba399ec..24ac6d4bee9e 100644 --- a/explorer/testdata/experimental_continuation/shallow_copy.carbon +++ b/explorer/testdata/experimental_continuation/shallow_copy.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/for/for_loop.carbon b/explorer/testdata/for/for_loop.carbon index 657215b46298..0ca88473f6af 100644 --- a/explorer/testdata/for/for_loop.carbon +++ b/explorer/testdata/for/for_loop.carbon @@ -2,36 +2,31 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: result: 8 +// CHECK:HALLO WELT 0 +// CHECK:HALLO WELT 1 +// CHECK:HALLO WELT 2 +// CHECK:HALLO WELT 3 +// CHECK:HALLO WELT 0 +// CHECK:HALLO WELT 1 +// CHECK:HALLO WELT 2 +// CHECK:HALLO WELT 3 +// CHECK:result: 8 package ExplorerTest api; - - - fn Main() -> i32 { - var ar: [i32; 4] = (0, 1,2,3); - var count : i32 = 0; - for( x: i32 in ar){ - Print("HALLO WELT ", x); - count = count +1; + var ar: [i32; 4] = (0, 1, 2, 3); + var count: i32 = 0; + for (x: i32 in ar) { + Print("HALLO WELT {0}", x); + count = count + 1; } - for( x: i32 in ar){ - Print("HALLO WELT ", x); - count = count +1; + for (x: i32 in ar) { + Print("HALLO WELT {0}", x); + count = count + 1; } return count; } diff --git a/explorer/testdata/for/for_loop_auto.carbon b/explorer/testdata/for/for_loop_auto.carbon index 2b19b78cf439..dfe7ddfc9a67 100644 --- a/explorer/testdata/for/for_loop_auto.carbon +++ b/explorer/testdata/for/for_loop_auto.carbon @@ -2,28 +2,23 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: HALLO WELT -// CHECK: result: 4 +// CHECK:HALLO WELT 0 +// CHECK:HALLO WELT 1 +// CHECK:HALLO WELT 2 +// CHECK:HALLO WELT 3 +// CHECK:result: 4 package ExplorerTest api; - - - fn Main() -> i32 { - var ar: [i32; 4] = (0, 1,2,3); - var count : i32 = 0; - for( x: auto in ar){ - Print("HALLO WELT ", x); - count = count +1; + var ar: [i32; 4] = (0, 1, 2, 3); + var count: i32 = 0; + for (x: auto in ar) { + Print("HALLO WELT {0}", x); + count = count + 1; } return count; } diff --git a/explorer/testdata/for/for_loop_break.carbon b/explorer/testdata/for/for_loop_break.carbon index b6d1e1311349..d1011ea90cec 100644 --- a/explorer/testdata/for/for_loop_break.carbon +++ b/explorer/testdata/for/for_loop_break.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/for/for_loop_continue.carbon b/explorer/testdata/for/for_loop_continue.carbon index d4720d7ce494..4936a3784f43 100644 --- a/explorer/testdata/for/for_loop_continue.carbon +++ b/explorer/testdata/for/for_loop_continue.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 4 +// CHECK:result: 4 package ExplorerTest api; diff --git a/explorer/testdata/for/for_loop_empty.carbon b/explorer/testdata/for/for_loop_empty.carbon index 781be8909897..1eeeeeb2ef1c 100644 --- a/explorer/testdata/for/for_loop_empty.carbon +++ b/explorer/testdata/for/for_loop_empty.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/for/for_loop_nested.carbon b/explorer/testdata/for/for_loop_nested.carbon index ce1d381c52ec..f000e39803f7 100644 --- a/explorer/testdata/for/for_loop_nested.carbon +++ b/explorer/testdata/for/for_loop_nested.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 20 +// CHECK:result: 20 package ExplorerTest api; diff --git a/explorer/testdata/function/auto_return/add.carbon b/explorer/testdata/function/auto_return/add.carbon index 7eec2391c41d..1c4b1aae0140 100644 --- a/explorer/testdata/function/auto_return/add.carbon +++ b/explorer/testdata/function/auto_return/add.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/auto_return/fail_direct_recurse.carbon b/explorer/testdata/function/auto_return/fail_direct_recurse.carbon index f2805ed32460..4af82fb2c6b6 100644 --- a/explorer/testdata/function/auto_return/fail_direct_recurse.carbon +++ b/explorer/testdata/function/auto_return/fail_direct_recurse.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ package ExplorerTest api; // used. fn Recurse(x: i32, do_recurse: bool) -> auto { if (do_recurse) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_direct_recurse.carbon:[[@LINE+1]]: Function calls itself, but has a deduced return type + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_direct_recurse.carbon:[[@LINE+1]]: Function calls itself, but has a deduced return type Recurse(x, false); } return x; diff --git a/explorer/testdata/function/auto_return/fail_multiple_returns.carbon b/explorer/testdata/function/auto_return/fail_multiple_returns.carbon index e83d30c50c17..7c01e564701c 100644 --- a/explorer/testdata/function/auto_return/fail_multiple_returns.carbon +++ b/explorer/testdata/function/auto_return/fail_multiple_returns.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ fn Add(x: i32, y: i32) -> auto { if (x == 0) { return x; } else if (y == 0) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_multiple_returns.carbon:[[@LINE+1]]: Only one return is allowed in a function with an `auto` return type. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_multiple_returns.carbon:[[@LINE+1]]: Only one return is allowed in a function with an `auto` return type. return y; } else { return x + y; diff --git a/explorer/testdata/function/auto_return/fail_no_return.carbon b/explorer/testdata/function/auto_return/fail_no_return.carbon index 9fb3a6721833..76c67a86ff16 100644 --- a/explorer/testdata/function/auto_return/fail_no_return.carbon +++ b/explorer/testdata/function/auto_return/fail_no_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn NoReturn() -> auto { -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement } fn Main() { diff --git a/explorer/testdata/function/auto_return/fail_separate_decl.carbon b/explorer/testdata/function/auto_return/fail_separate_decl.carbon index e23d42a98083..77b22af1efa2 100644 --- a/explorer/testdata/function/auto_return/fail_separate_decl.carbon +++ b/explorer/testdata/function/auto_return/fail_separate_decl.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // This declaration is not allowed. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_separate_decl.carbon:[[@LINE+1]]: Function declaration has deduced return type but no body +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/auto_return/fail_separate_decl.carbon:[[@LINE+1]]: Function declaration has deduced return type but no body fn Add(x: i32, y: i32) -> auto; fn Main() -> i32 { diff --git a/explorer/testdata/function/auto_return/modify_arg_type.carbon b/explorer/testdata/function/auto_return/modify_arg_type.carbon index 71add53cea84..4f9cdb9e4867 100644 --- a/explorer/testdata/function/auto_return/modify_arg_type.carbon +++ b/explorer/testdata/function/auto_return/modify_arg_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/auto_return/modify_return_type.carbon b/explorer/testdata/function/auto_return/modify_return_type.carbon index 8d01bc3e114d..05d26c5de5c8 100644 --- a/explorer/testdata/function/auto_return/modify_return_type.carbon +++ b/explorer/testdata/function/auto_return/modify_return_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/auto_return/type.carbon b/explorer/testdata/function/auto_return/type.carbon index 7477746b4f96..d0d4c9a04287 100644 --- a/explorer/testdata/function/auto_return/type.carbon +++ b/explorer/testdata/function/auto_return/type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/convert_args.carbon b/explorer/testdata/function/convert_args.carbon index 9b094843edfb..342746cd22ff 100644 --- a/explorer/testdata/function/convert_args.carbon +++ b/explorer/testdata/function/convert_args.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 123 +// CHECK:result: 123 package ExplorerTest api; diff --git a/explorer/testdata/function/empty_params.carbon b/explorer/testdata/function/empty_params.carbon index a8362e9427be..79cfa9a30fec 100644 --- a/explorer/testdata/function/empty_params.carbon +++ b/explorer/testdata/function/empty_params.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/fail_call_with_tuple.carbon b/explorer/testdata/function/fail_call_with_tuple.carbon index 23e8737c7423..263ac56f35e5 100644 --- a/explorer/testdata/function/fail_call_with_tuple.carbon +++ b/explorer/testdata/function/fail_call_with_tuple.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,6 +13,6 @@ fn f(x: i32, y: i32) -> i32 { return x + y; } fn Main() -> i32 { var xy: (i32, i32) = (1, 2); // should fail to type-check - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_call_with_tuple.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 2 but got 1 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_call_with_tuple.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 2 but got 1 return f(xy); } diff --git a/explorer/testdata/function/fail_invalid_fnty.carbon b/explorer/testdata/function/fail_invalid_fnty.carbon index 77642b7d3389..65c2801fa316 100644 --- a/explorer/testdata/function/fail_invalid_fnty.carbon +++ b/explorer/testdata/function/fail_invalid_fnty.carbon @@ -2,18 +2,16 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // TODO: We should type-check the prelude before the main input so that we can // use it within the types of top-level declarations. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_invalid_fnty.carbon:[[@LINE+2]]: type error in `-`: -// CHECK: missing declaration for builtin `Negate` +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_invalid_fnty.carbon:[[@LINE+2]]: type error in `-`: +// CHECK:missing declaration for builtin `Negate` fn f(g: __Fn(-true) -> true) { } diff --git a/explorer/testdata/function/fail_match_no_return.carbon b/explorer/testdata/function/fail_match_no_return.carbon index b16e52a6e82c..d481d36458ef 100644 --- a/explorer/testdata/function/fail_match_no_return.carbon +++ b/explorer/testdata/function/fail_match_no_return.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var x: i32 = 0; match(0) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_match_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_match_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement case 1 => { x = 1; } case _: auto => { x = 2; } } diff --git a/explorer/testdata/function/fail_match_partial_return.carbon b/explorer/testdata/function/fail_match_partial_return.carbon index 87aeacf7ce66..d67960293946 100644 --- a/explorer/testdata/function/fail_match_partial_return.carbon +++ b/explorer/testdata/function/fail_match_partial_return.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var x: i32 = 0; match (0) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_match_partial_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_match_partial_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement case 1 => { x = 1; } case _: auto => { return 0; } } diff --git a/explorer/testdata/function/fail_non_exhaustive_match.carbon b/explorer/testdata/function/fail_non_exhaustive_match.carbon index 98d0a95cb851..8505f6f8ae35 100644 --- a/explorer/testdata/function/fail_non_exhaustive_match.carbon +++ b/explorer/testdata/function/fail_non_exhaustive_match.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,5 +13,5 @@ fn Main() -> i32 { match (n) { case 1 => { return 0; } } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_non_exhaustive_match.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_non_exhaustive_match.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type } diff --git a/explorer/testdata/function/fail_parameter_type.carbon b/explorer/testdata/function/fail_parameter_type.carbon index 0d5f48c6260b..d99d659624fd 100644 --- a/explorer/testdata/function/fail_parameter_type.carbon +++ b/explorer/testdata/function/fail_parameter_type.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // 42 cannot be used as the type of a parameter. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_parameter_type.carbon:[[@LINE+1]]: Expected a type, but got 42 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/function/fail_parameter_type.carbon:[[@LINE+1]]: Expected a type, but got 42 fn f(x: 42) -> i32 { return x - 1; } diff --git a/explorer/testdata/function/fnty.carbon b/explorer/testdata/function/fnty.carbon index 11237cf40892..269b44251b2e 100644 --- a/explorer/testdata/function/fnty.carbon +++ b/explorer/testdata/function/fnty.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/ignored_parameter.carbon b/explorer/testdata/function/ignored_parameter.carbon index 599b745ff80d..97fe833fe7a3 100644 --- a/explorer/testdata/function/ignored_parameter.carbon +++ b/explorer/testdata/function/ignored_parameter.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/multiple_args.carbon b/explorer/testdata/function/multiple_args.carbon index fc9f580f3594..3cf664c64c63 100644 --- a/explorer/testdata/function/multiple_args.carbon +++ b/explorer/testdata/function/multiple_args.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/non_exhaustive_match_no_return_type.carbon b/explorer/testdata/function/non_exhaustive_match_no_return_type.carbon index 3d2440130947..bff7bb133819 100644 --- a/explorer/testdata/function/non_exhaustive_match_no_return_type.carbon +++ b/explorer/testdata/function/non_exhaustive_match_no_return_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/non_exhaustive_match_return.carbon b/explorer/testdata/function/non_exhaustive_match_return.carbon index 54c900b2e8c0..f55980ca48fa 100644 --- a/explorer/testdata/function/non_exhaustive_match_return.carbon +++ b/explorer/testdata/function/non_exhaustive_match_return.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/function/param_lifetime.carbon b/explorer/testdata/function/param_lifetime.carbon index 9f284df653b0..3de28786a3cc 100644 --- a/explorer/testdata/function/param_lifetime.carbon +++ b/explorer/testdata/function/param_lifetime.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/recursive.carbon b/explorer/testdata/function/recursive.carbon index b1d63a87ad53..55b7e11fd9da 100644 --- a/explorer/testdata/function/recursive.carbon +++ b/explorer/testdata/function/recursive.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/return.carbon b/explorer/testdata/function/return.carbon index cc2e0c6a98bc..8196b9497fd4 100644 --- a/explorer/testdata/function/return.carbon +++ b/explorer/testdata/function/return.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/function/return_exhaustive_match.carbon b/explorer/testdata/function/return_exhaustive_match.carbon index cacf2ba1721a..edcc82f08483 100644 --- a/explorer/testdata/function/return_exhaustive_match.carbon +++ b/explorer/testdata/function/return_exhaustive_match.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/function/type_match.carbon b/explorer/testdata/function/type_match.carbon index 28401b16a5c5..48fc382b2055 100644 --- a/explorer/testdata/function/type_match.carbon +++ b/explorer/testdata/function/type_match.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/class_function.carbon b/explorer/testdata/generic_class/class_function.carbon index 49017109bf7b..14acc5e4c5e8 100644 --- a/explorer/testdata/generic_class/class_function.carbon +++ b/explorer/testdata/generic_class/class_function.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/convert_from_struct.carbon b/explorer/testdata/generic_class/convert_from_struct.carbon index f0875a6bf853..828017ca7f22 100644 --- a/explorer/testdata/generic_class/convert_from_struct.carbon +++ b/explorer/testdata/generic_class/convert_from_struct.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/fail_args_mismatch.carbon b/explorer/testdata/generic_class/fail_args_mismatch.carbon index 62eca4c7ae75..6d7680f47fb8 100644 --- a/explorer/testdata/generic_class/fail_args_mismatch.carbon +++ b/explorer/testdata/generic_class/fail_args_mismatch.carbon @@ -2,15 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false --dump-input=always -v %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class Point(T:! Type) { // Point(T, T) does not match class declaration - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_args_mismatch.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 1 but got 2 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_args_mismatch.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 1 but got 2 fn Origin(zero: T) -> Point(T, T) { return {.x = zero, .y = zero}; } diff --git a/explorer/testdata/generic_class/fail_argument_deduction.carbon b/explorer/testdata/generic_class/fail_argument_deduction.carbon index 5ad7276d4b52..5f6f7518fbc7 100644 --- a/explorer/testdata/generic_class/fail_argument_deduction.carbon +++ b/explorer/testdata/generic_class/fail_argument_deduction.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -22,8 +20,8 @@ fn FirstOfTwoPoints[T:! Type](a: Point(T), b: Point(T)) -> Point(T) { fn Main() -> i32 { var p: Point(i32) = {.x = 0, .y = 1}; var q: Point(bool) = {.x = true, .y = false}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_argument_deduction.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: - // CHECK: i32 - // CHECK: bool + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_argument_deduction.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: + // CHECK: i32 + // CHECK: bool return FirstOfTwoPoints(p, q).x; } diff --git a/explorer/testdata/generic_class/fail_bad_parameter_type.carbon b/explorer/testdata/generic_class/fail_bad_parameter_type.carbon index 03839182c87a..b0be30411e26 100644 --- a/explorer/testdata/generic_class/fail_bad_parameter_type.carbon +++ b/explorer/testdata/generic_class/fail_bad_parameter_type.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -24,7 +22,7 @@ class Point(T:! i32) { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_bad_parameter_type.carbon:[[@LINE+1]]: type error in call: 'Type' is not implicitly convertible to 'i32' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_bad_parameter_type.carbon:[[@LINE+1]]: type error in call: 'Type' is not implicitly convertible to 'i32' var p: Point(i32) = Point(i32).Origin(0); return p.GetX(); } diff --git a/explorer/testdata/generic_class/fail_field_access_on_generic.carbon b/explorer/testdata/generic_class/fail_field_access_on_generic.carbon index 5006628c9b67..751d3536e4ae 100644 --- a/explorer/testdata/generic_class/fail_field_access_on_generic.carbon +++ b/explorer/testdata/generic_class/fail_field_access_on_generic.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn BadSimpleMemberAccess[T:! Type](a: T) -> T { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_field_access_on_generic.carbon:[[@LINE+1]]: member access in unconstrained type + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_field_access_on_generic.carbon:[[@LINE+1]]: member access in unconstrained type return a.x; } diff --git a/explorer/testdata/generic_class/fail_generic_class_arg.carbon b/explorer/testdata/generic_class/fail_generic_class_arg.carbon index bfd034b5b5f8..21526e81dc8c 100644 --- a/explorer/testdata/generic_class/fail_generic_class_arg.carbon +++ b/explorer/testdata/generic_class/fail_generic_class_arg.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,7 +18,7 @@ class Point(T:! Type) { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_generic_class_arg.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 1 but got 2 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_generic_class_arg.carbon:[[@LINE+1]]: wrong number of arguments in function call, expected 1 but got 2 var p: Point(i32) = Point(i32, i32).Create(0, 1); return p.x; } diff --git a/explorer/testdata/generic_class/fail_generic_in_pattern.carbon b/explorer/testdata/generic_class/fail_generic_in_pattern.carbon index 595e41c5619d..4545be5dd8ce 100644 --- a/explorer/testdata/generic_class/fail_generic_in_pattern.carbon +++ b/explorer/testdata/generic_class/fail_generic_in_pattern.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var t: auto = 5; match (t) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_generic_in_pattern.carbon:[[@LINE+1]]: Generic binding may not occur in pattern with expected type: T:! i32 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_generic_in_pattern.carbon:[[@LINE+1]]: Generic binding may not occur in pattern with expected type: T:! i32 case T:! i32 => { return 0; } default => { return 1; } } diff --git a/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon b/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon index 9103911ccee1..0d5e78283ff2 100644 --- a/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon +++ b/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,7 +17,7 @@ class Point { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon:[[@LINE+1]]: in call `Point(i32)`, expected callee to be a function, found `typeof(class Point)` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_instantiate_non_generic.carbon:[[@LINE+1]]: in call `Point(i32)`, expected callee to be a function, found `typeof(class Point)` var p: Point(i32) = Point.Origin(); return 0; } diff --git a/explorer/testdata/generic_class/fail_no_args.carbon b/explorer/testdata/generic_class/fail_no_args.carbon index b737d1c7ccdd..6114d833fc6f 100644 --- a/explorer/testdata/generic_class/fail_no_args.carbon +++ b/explorer/testdata/generic_class/fail_no_args.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class Point(T:! Type) { } // Error: wrote `Point` instead of `Point(T)`, `Point` by itself is not a type. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_no_args.carbon:[[@LINE+1]]: Expected a type, but got Point + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_no_args.carbon:[[@LINE+1]]: Expected a type, but got Point fn GetX[me: Point]() -> T { return me.x; } diff --git a/explorer/testdata/generic_class/fail_point_equal.carbon b/explorer/testdata/generic_class/fail_point_equal.carbon index 442704d45813..0edf94acfae6 100644 --- a/explorer/testdata/generic_class/fail_point_equal.carbon +++ b/explorer/testdata/generic_class/fail_point_equal.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ class Point(T:! Type) { fn Main() -> i32 { var p: Point(i32) = {.x = 0, .y = 0}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_point_equal.carbon:[[@LINE+1]]: type error in name binding: 'class Point(T = i32)' is not implicitly convertible to 'class Point(T = bool)' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_point_equal.carbon:[[@LINE+1]]: type error in name binding: 'class Point(T = i32)' is not implicitly convertible to 'class Point(T = bool)' var q: Point(bool) = p; return 0; } diff --git a/explorer/testdata/generic_class/fail_return_type_is_type.carbon b/explorer/testdata/generic_class/fail_return_type_is_type.carbon index 2f757dd2ea2c..f1e08c459d33 100644 --- a/explorer/testdata/generic_class/fail_return_type_is_type.carbon +++ b/explorer/testdata/generic_class/fail_return_type_is_type.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class Point(T:! Type) { // The return type should be Point(T). Point by itself is not a type. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_return_type_is_type.carbon:[[@LINE+1]]: Expected a type, but got Point + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_return_type_is_type.carbon:[[@LINE+1]]: Expected a type, but got Point fn Create(x: T, y: T) -> Point { return {.x = x, .y = y}; } diff --git a/explorer/testdata/generic_class/fail_self_with_arg.carbon b/explorer/testdata/generic_class/fail_self_with_arg.carbon index 44600e9081d6..82fd856e121b 100644 --- a/explorer/testdata/generic_class/fail_self_with_arg.carbon +++ b/explorer/testdata/generic_class/fail_self_with_arg.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; class Point(T:! Type) { // Error: wrote `Self(T)` instead of `Self`. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_self_with_arg.carbon:[[@LINE+1]]: in call `Self(T)`, expected callee to be a function, found `typeof(class Point(T = T:! Type))` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_self_with_arg.carbon:[[@LINE+1]]: in call `Self(T)`, expected callee to be a function, found `typeof(class Point(T = T:! Type))` fn Origin(zero: T) -> Self(T) { return {.x = zero, .y = zero}; } diff --git a/explorer/testdata/generic_class/fail_two_arg_lists.carbon b/explorer/testdata/generic_class/fail_two_arg_lists.carbon index 262785406274..1cb9b2c69a79 100644 --- a/explorer/testdata/generic_class/fail_two_arg_lists.carbon +++ b/explorer/testdata/generic_class/fail_two_arg_lists.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class Point(T:! Type) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_two_arg_lists.carbon:[[@LINE+1]]: in call `Point(T)(T)`, expected callee to be a function, found `typeof(class Point(T = T:! Type))` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_two_arg_lists.carbon:[[@LINE+1]]: in call `Point(T)(T)`, expected callee to be a function, found `typeof(class Point(T = T:! Type))` fn Origin(zero: T) -> Point(T)(T) { return {.x = zero, .y = zero}; } diff --git a/explorer/testdata/generic_class/fail_value_param_mismatch.carbon b/explorer/testdata/generic_class/fail_value_param_mismatch.carbon index abcb43331d0c..6d8c7f5dc5f1 100644 --- a/explorer/testdata/generic_class/fail_value_param_mismatch.carbon +++ b/explorer/testdata/generic_class/fail_value_param_mismatch.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ fn F(x: HasI32Param(1)) {} fn Main() -> i32 { var n: HasI32Param(0) = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_value_param_mismatch.carbon:[[@LINE+1]]: mismatch in non-type values, `0` != `1` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_class/fail_value_param_mismatch.carbon:[[@LINE+1]]: mismatch in non-type values, `0` != `1` F(n); return 0; } diff --git a/explorer/testdata/generic_class/generic_class_substitution.carbon b/explorer/testdata/generic_class/generic_class_substitution.carbon index bf22c5a61cc3..779d21b00af4 100644 --- a/explorer/testdata/generic_class/generic_class_substitution.carbon +++ b/explorer/testdata/generic_class/generic_class_substitution.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/generic_fun_and_class.carbon b/explorer/testdata/generic_class/generic_fun_and_class.carbon index f62ea7a54e2e..e0c1c4d55ef8 100644 --- a/explorer/testdata/generic_class/generic_fun_and_class.carbon +++ b/explorer/testdata/generic_class/generic_fun_and_class.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/generic_point.carbon b/explorer/testdata/generic_class/generic_point.carbon index 58d39d257aa6..5c18e6a0c007 100644 --- a/explorer/testdata/generic_class/generic_point.carbon +++ b/explorer/testdata/generic_class/generic_point.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/impl_with_argument.carbon b/explorer/testdata/generic_class/impl_with_argument.carbon index 6bef60e3ebb3..06b6b49d89dc 100644 --- a/explorer/testdata/generic_class/impl_with_argument.carbon +++ b/explorer/testdata/generic_class/impl_with_argument.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/impl_with_self.carbon b/explorer/testdata/generic_class/impl_with_self.carbon index edfa65b6e7cc..34ec8996ccec 100644 --- a/explorer/testdata/generic_class/impl_with_self.carbon +++ b/explorer/testdata/generic_class/impl_with_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/instantiation_at_compile_time.carbon b/explorer/testdata/generic_class/instantiation_at_compile_time.carbon index 0df9059adefc..b133d3c5ff01 100644 --- a/explorer/testdata/generic_class/instantiation_at_compile_time.carbon +++ b/explorer/testdata/generic_class/instantiation_at_compile_time.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/param_with_dependent_type.carbon b/explorer/testdata/generic_class/param_with_dependent_type.carbon index 12b1cab95ae4..1a7a4271aae7 100644 --- a/explorer/testdata/generic_class/param_with_dependent_type.carbon +++ b/explorer/testdata/generic_class/param_with_dependent_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/point_with_interface.carbon b/explorer/testdata/generic_class/point_with_interface.carbon index 948cda25954f..d9ad38df7486 100644 --- a/explorer/testdata/generic_class/point_with_interface.carbon +++ b/explorer/testdata/generic_class/point_with_interface.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/use_at_compile_time.carbon b/explorer/testdata/generic_class/use_at_compile_time.carbon index 6c268dc50daa..113bd83321b2 100644 --- a/explorer/testdata/generic_class/use_at_compile_time.carbon +++ b/explorer/testdata/generic_class/use_at_compile_time.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_class/use_self.carbon b/explorer/testdata/generic_class/use_self.carbon index 9f7544d59a25..a5459922fced 100644 --- a/explorer/testdata/generic_class/use_self.carbon +++ b/explorer/testdata/generic_class/use_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/apply.carbon b/explorer/testdata/generic_function/apply.carbon index 23adb60b3c55..c34f6256f3d2 100644 --- a/explorer/testdata/generic_function/apply.carbon +++ b/explorer/testdata/generic_function/apply.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: -2 +// CHECK:result: -2 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/call_at_compile_time.carbon b/explorer/testdata/generic_function/call_at_compile_time.carbon index 0ace774c63a9..d8558c870f99 100644 --- a/explorer/testdata/generic_function/call_at_compile_time.carbon +++ b/explorer/testdata/generic_function/call_at_compile_time.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon b/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon index bd5c06765a0b..f59a4ca4de65 100644 --- a/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon +++ b/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Bad[T:! Type](x: {.a: i32, .b: T}) {} fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon:[[@LINE+1]]: mismatch in field names, source field `c` not in destination type `{.a: i32, .b: T:! Type}` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_implicit_conversion_extra_field.carbon:[[@LINE+1]]: mismatch in field names, source field `c` not in destination type `{.a: i32, .b: T:! Type}` Bad({.b = 5, .a = 7, .c = 2}); return 0; } diff --git a/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon b/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon index faaa3cdfa469..cb9dc04defa6 100644 --- a/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon +++ b/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Bad[T:! Type](x: {.a: i32, .b: T}) {} fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon:[[@LINE+1]]: mismatch in field names, destination field `b` not in source type `{.a: i32}` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_implicit_conversion_missing_field.carbon:[[@LINE+1]]: mismatch in field names, destination field `b` not in source type `{.a: i32}` Bad({.a = 5}); return 0; } diff --git a/explorer/testdata/generic_function/fail_missing_exclam.carbon b/explorer/testdata/generic_function/fail_missing_exclam.carbon index af13759f489a..28bf96da919c 100644 --- a/explorer/testdata/generic_function/fail_missing_exclam.carbon +++ b/explorer/testdata/generic_function/fail_missing_exclam.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/generic_function/fail_missing_exclam.carbon:[[@LINE+1]]: illegal binding pattern in implicit parameter list +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/generic_function/fail_missing_exclam.carbon:[[@LINE+1]]: illegal binding pattern in implicit parameter list fn F[T: Type](); fn Main() -> i32 { diff --git a/explorer/testdata/generic_function/fail_not_addable.carbon b/explorer/testdata/generic_function/fail_not_addable.carbon index 9576fc273222..492205f3513a 100644 --- a/explorer/testdata/generic_function/fail_not_addable.carbon +++ b/explorer/testdata/generic_function/fail_not_addable.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn id[T:! Type](x: T) -> T { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_not_addable.carbon:[[@LINE+2]]: type error in `+`: - // CHECK: could not find implementation of interface AddWith(U = i32) for T:! Type + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_not_addable.carbon:[[@LINE+2]]: type error in `+`: + // CHECK:could not find implementation of interface AddWith(U = i32) for T:! Type return x + 0; } diff --git a/explorer/testdata/generic_function/fail_not_type.carbon b/explorer/testdata/generic_function/fail_not_type.carbon index c8058432f737..dc9d873a852e 100644 --- a/explorer/testdata/generic_function/fail_not_type.carbon +++ b/explorer/testdata/generic_function/fail_not_type.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_not_type.carbon:[[@LINE+1]]: Expected a type, but got 42 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_not_type.carbon:[[@LINE+1]]: Expected a type, but got 42 fn F[a:! 42](); fn Main() -> i32 { diff --git a/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon b/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon index 95908dc0016c..0011131b61ed 100644 --- a/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon +++ b/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,8 +13,8 @@ fn fst[T:! Type](x: T, y: T) -> T { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: - // CHECK: i32 - // CHECK: bool + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_type_deduction_mismatch.carbon:[[@LINE+3]]: deduced multiple different values for T:! Type: + // CHECK: i32 + // CHECK: bool return fst(0, true); } diff --git a/explorer/testdata/generic_function/fail_type_deduction_unused.carbon b/explorer/testdata/generic_function/fail_type_deduction_unused.carbon index 8de1b49bc8ce..5a6069b72e6d 100644 --- a/explorer/testdata/generic_function/fail_type_deduction_unused.carbon +++ b/explorer/testdata/generic_function/fail_type_deduction_unused.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ fn id[T:! Type](x: i32) -> i32 { } fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_type_deduction_unused.carbon:[[@LINE+2]]: could not deduce type argument for type parameter T - // CHECK: in id(0) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_type_deduction_unused.carbon:[[@LINE+2]]: could not deduce type argument for type parameter T + // CHECK:in id(0) return id(0); } diff --git a/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon b/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon index 169b9b4e4bd5..2988fd927f17 100644 --- a/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon +++ b/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package Foo api; @@ -17,7 +15,7 @@ fn Get[T:! ()](n: T) -> i32 { return 2; } fn Main() -> i32 { var x : X = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon:[[@LINE+1]]: cannot convert deduced value class X for T to parameter type () + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/generic_function/fail_wrong_variable_substituation.carbon:[[@LINE+1]]: cannot convert deduced value class X for T to parameter type () Get(x); return 0; } diff --git a/explorer/testdata/generic_function/generic_method.carbon b/explorer/testdata/generic_function/generic_method.carbon index 42e90001cb3e..7b2356bcdd27 100644 --- a/explorer/testdata/generic_function/generic_method.carbon +++ b/explorer/testdata/generic_function/generic_method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/implicit_conversion.carbon b/explorer/testdata/generic_function/implicit_conversion.carbon index ad6ee0025e8e..dabd9a026957 100644 --- a/explorer/testdata/generic_function/implicit_conversion.carbon +++ b/explorer/testdata/generic_function/implicit_conversion.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 4213 +// CHECK:result: 4213 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/non_generic_param.carbon b/explorer/testdata/generic_function/non_generic_param.carbon index 0c9ae63d3984..13f736142574 100644 --- a/explorer/testdata/generic_function/non_generic_param.carbon +++ b/explorer/testdata/generic_function/non_generic_param.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/nondeduced_generic_param.carbon b/explorer/testdata/generic_function/nondeduced_generic_param.carbon index d2e3b032b23b..88947c351e64 100644 --- a/explorer/testdata/generic_function/nondeduced_generic_param.carbon +++ b/explorer/testdata/generic_function/nondeduced_generic_param.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; class A(T:! Type) { diff --git a/explorer/testdata/generic_function/return_val.carbon b/explorer/testdata/generic_function/return_val.carbon index 123148ead34a..6da039103aa4 100644 --- a/explorer/testdata/generic_function/return_val.carbon +++ b/explorer/testdata/generic_function/return_val.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/swap.carbon b/explorer/testdata/generic_function/swap.carbon index 8f341cbde568..be89cb1db70a 100644 --- a/explorer/testdata/generic_function/swap.carbon +++ b/explorer/testdata/generic_function/swap.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/tuple_map.carbon b/explorer/testdata/generic_function/tuple_map.carbon index 67eed0ae6c3c..06b82a789f06 100644 --- a/explorer/testdata/generic_function/tuple_map.carbon +++ b/explorer/testdata/generic_function/tuple_map.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/generic_function/type_matching.carbon b/explorer/testdata/generic_function/type_matching.carbon index 1955a3457eb8..7fd2db7c231b 100644 --- a/explorer/testdata/generic_function/type_matching.carbon +++ b/explorer/testdata/generic_function/type_matching.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/fail_init_type_mismatch.carbon b/explorer/testdata/global_variable/fail_init_type_mismatch.carbon index 0f941d8a5c5b..c5fd8d30d0d7 100644 --- a/explorer/testdata/global_variable/fail_init_type_mismatch.carbon +++ b/explorer/testdata/global_variable/fail_init_type_mismatch.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // Test type checking of global variable. Error expected. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/global_variable/fail_init_type_mismatch.carbon:[[@LINE+1]]: type error in initializer of variable: 'bool' is not implicitly convertible to 'i32' +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/global_variable/fail_init_type_mismatch.carbon:[[@LINE+1]]: type error in initializer of variable: 'bool' is not implicitly convertible to 'i32' var flag: i32 = true; fn Main() -> i32 { diff --git a/explorer/testdata/global_variable/fail_named_self.carbon b/explorer/testdata/global_variable/fail_named_self.carbon index a22596ec5fed..f7ab098e6478 100644 --- a/explorer/testdata/global_variable/fail_named_self.carbon +++ b/explorer/testdata/global_variable/fail_named_self.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // Error: global variable may not be named with keyword `Self`. -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/global_variable/fail_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/global_variable/fail_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier var Self: i32 = 0; fn Main() -> i32 { diff --git a/explorer/testdata/global_variable/implicit_conversion.carbon b/explorer/testdata/global_variable/implicit_conversion.carbon index 7114330d9058..d06e55ac9773 100644 --- a/explorer/testdata/global_variable/implicit_conversion.carbon +++ b/explorer/testdata/global_variable/implicit_conversion.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/init_and_read.carbon b/explorer/testdata/global_variable/init_and_read.carbon index 30804c20d65c..d684d894aa46 100644 --- a/explorer/testdata/global_variable/init_and_read.carbon +++ b/explorer/testdata/global_variable/init_and_read.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/init_from_function.carbon b/explorer/testdata/global_variable/init_from_function.carbon index e60f505a7b89..0b2072c17b31 100644 --- a/explorer/testdata/global_variable/init_from_function.carbon +++ b/explorer/testdata/global_variable/init_from_function.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/init_order.carbon b/explorer/testdata/global_variable/init_order.carbon index 3a4fdc20df4e..9079bb4e6a6a 100644 --- a/explorer/testdata/global_variable/init_order.carbon +++ b/explorer/testdata/global_variable/init_order.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/shadowing.carbon b/explorer/testdata/global_variable/shadowing.carbon index 298d46da8f20..b4fc9eb4cdb7 100644 --- a/explorer/testdata/global_variable/shadowing.carbon +++ b/explorer/testdata/global_variable/shadowing.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/write.carbon b/explorer/testdata/global_variable/write.carbon index 3bc97974aeeb..db66abd5c68c 100644 --- a/explorer/testdata/global_variable/write.carbon +++ b/explorer/testdata/global_variable/write.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/global_variable/write_from_function.carbon b/explorer/testdata/global_variable/write_from_function.carbon index 5d3f57c0f27c..234896ef2c6a 100644 --- a/explorer/testdata/global_variable/write_from_function.carbon +++ b/explorer/testdata/global_variable/write_from_function.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/convert_condition.carbon b/explorer/testdata/if_else/convert_condition.carbon index 63e34fa09f0f..9ce83509ab58 100644 --- a/explorer/testdata/if_else/convert_condition.carbon +++ b/explorer/testdata/if_else/convert_condition.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_else.carbon b/explorer/testdata/if_else/if_else.carbon index de4ac083705b..d630af13f03e 100644 --- a/explorer/testdata/if_else/if_else.carbon +++ b/explorer/testdata/if_else/if_else.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_else_if.carbon b/explorer/testdata/if_else/if_else_if.carbon index deedbdb84d69..e632c0c52444 100644 --- a/explorer/testdata/if_else/if_else_if.carbon +++ b/explorer/testdata/if_else/if_else_if.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_else_if_else.carbon b/explorer/testdata/if_else/if_else_if_else.carbon index a1db8dcf72b5..0070b11bc3c6 100644 --- a/explorer/testdata/if_else/if_else_if_else.carbon +++ b/explorer/testdata/if_else/if_else_if_else.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_false.carbon b/explorer/testdata/if_else/if_false.carbon index 58c0aefaa92c..3c14a38b50d3 100644 --- a/explorer/testdata/if_else/if_false.carbon +++ b/explorer/testdata/if_else/if_false.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_nesting.carbon b/explorer/testdata/if_else/if_nesting.carbon index 7289aa595310..ce8875c22158 100644 --- a/explorer/testdata/if_else/if_nesting.carbon +++ b/explorer/testdata/if_else/if_nesting.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_else/if_true.carbon b/explorer/testdata/if_else/if_true.carbon index fe123a969a66..925a1e9ad10e 100644 --- a/explorer/testdata/if_else/if_true.carbon +++ b/explorer/testdata/if_else/if_true.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/if_expression/convert_condition.carbon b/explorer/testdata/if_expression/convert_condition.carbon index 3bc3fa124eaf..3beb412a2640 100644 --- a/explorer/testdata/if_expression/convert_condition.carbon +++ b/explorer/testdata/if_expression/convert_condition.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/if_expression/if_then_else.carbon b/explorer/testdata/if_expression/if_then_else.carbon index aa32a1aed16f..5468e5501640 100644 --- a/explorer/testdata/if_expression/if_then_else.carbon +++ b/explorer/testdata/if_expression/if_then_else.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12 +// CHECK:result: 12 package ExplorerTest api; diff --git a/explorer/testdata/impl/deducible_parameter.carbon b/explorer/testdata/impl/deducible_parameter.carbon index 2bf1bbe6c321..f89e6e17ddf1 100644 --- a/explorer/testdata/impl/deducible_parameter.carbon +++ b/explorer/testdata/impl/deducible_parameter.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/impl/fail_ambiguous_impl.carbon b/explorer/testdata/impl/fail_ambiguous_impl.carbon index 3a21ceda258e..2dace25bcc5c 100644 --- a/explorer/testdata/impl/fail_ambiguous_impl.carbon +++ b/explorer/testdata/impl/fail_ambiguous_impl.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s @@ -37,7 +35,7 @@ external impl Point as Vector { fn Scale[me: Point](v: i32) -> Point { return {.x = me.x * v, .y = me.y * v}; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_ambiguous_impl.carbon:[[@LINE+1]]: ambiguous implementations of interface Vector for class Point +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_ambiguous_impl.carbon:[[@LINE+1]]: ambiguous implementations of interface Vector for class Point } fn AddAndScaleGeneric[T:! Vector](a: T, b: T, s: i32) -> T { diff --git a/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon b/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon index 0854a76a6d03..938f9c8e9373 100644 --- a/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon +++ b/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -24,7 +22,7 @@ fn Main() -> i32 { let b: A(i32) = {}; F(a); G(b); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon:[[@LINE+1]]: ambiguous implementations of interface B(T = i32) for class A(T = i32) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_ambiguous_impl_generic.carbon:[[@LINE+1]]: ambiguous implementations of interface B(T = i32) for class A(T = i32) F(b); return 0; } diff --git a/explorer/testdata/impl/fail_bad_member_kind.carbon b/explorer/testdata/impl/fail_bad_member_kind.carbon index 72be158e69aa..4ad500830e44 100644 --- a/explorer/testdata/impl/fail_bad_member_kind.carbon +++ b/explorer/testdata/impl/fail_bad_member_kind.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ interface A { } external impl i32 as A { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/impl/fail_bad_member_kind.carbon:[[@LINE+1]]: syntax error, unexpected CLASS, expecting ALIAS or FN or RIGHT_CURLY_BRACE + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/impl/fail_bad_member_kind.carbon:[[@LINE+1]]: syntax error, unexpected CLASS, expecting ALIAS or FN or RIGHT_CURLY_BRACE class T {} } diff --git a/explorer/testdata/impl/fail_impl_as.carbon b/explorer/testdata/impl/fail_impl_as.carbon index eb29d57fb4f1..fd1ad52ce7b4 100644 --- a/explorer/testdata/impl/fail_impl_as.carbon +++ b/explorer/testdata/impl/fail_impl_as.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type i32 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type i32 external impl i32 as i32 {} fn Main() -> i32 { diff --git a/explorer/testdata/impl/fail_impl_as_non_interface.carbon b/explorer/testdata/impl/fail_impl_as_non_interface.carbon index 9c94b1bc2339..73dff2f1767b 100644 --- a/explorer/testdata/impl/fail_impl_as_non_interface.carbon +++ b/explorer/testdata/impl/fail_impl_as_non_interface.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_non_interface.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type String +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_non_interface.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type String external impl i32 as String {} fn Main() -> i32 { diff --git a/explorer/testdata/impl/fail_impl_as_not_constraint.carbon b/explorer/testdata/impl/fail_impl_as_not_constraint.carbon index 682ea6dafd5f..026d953f0e5b 100644 --- a/explorer/testdata/impl/fail_impl_as_not_constraint.carbon +++ b/explorer/testdata/impl/fail_impl_as_not_constraint.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_not_constraint.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type i32 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_not_constraint.carbon:[[@LINE+1]]: expected constraint after `as`, found value of type i32 external impl i32 as i32 {} fn Main() -> i32 { diff --git a/explorer/testdata/impl/fail_impl_as_parameterized.carbon b/explorer/testdata/impl/fail_impl_as_parameterized.carbon index 88789d002331..49d1201adc2f 100644 --- a/explorer/testdata/impl/fail_impl_as_parameterized.carbon +++ b/explorer/testdata/impl/fail_impl_as_parameterized.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface Vector(Scalar:! Type) { } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_parameterized.carbon:[[@LINE+1]]: Expected a type, but got Vector +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_impl_as_parameterized.carbon:[[@LINE+1]]: Expected a type, but got Vector external impl i32 as Vector {} fn Main() -> i32 { diff --git a/explorer/testdata/impl/fail_nondeducible_parameter.carbon b/explorer/testdata/impl/fail_nondeducible_parameter.carbon index c6bb5837f81f..c51094d8f039 100644 --- a/explorer/testdata/impl/fail_nondeducible_parameter.carbon +++ b/explorer/testdata/impl/fail_nondeducible_parameter.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface A(T:! Type) {} interface B {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_nondeducible_parameter.carbon:[[@LINE+1]]: parameter `T:! Type` is not deducible from `impl i32 as interface B` +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_nondeducible_parameter.carbon:[[@LINE+1]]: parameter `T:! Type` is not deducible from `impl i32 as interface B` external impl forall [T:! Type] i32 as A(T) & B {} fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/impl/fail_param_interface_in_impl.carbon b/explorer/testdata/impl/fail_param_interface_in_impl.carbon index 1baa85dbb07d..9cb15188008f 100644 --- a/explorer/testdata/impl/fail_param_interface_in_impl.carbon +++ b/explorer/testdata/impl/fail_param_interface_in_impl.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -21,7 +19,7 @@ fn Main() -> i32 { let n: i32 = 0; CheckSimilar(true, false); CheckSimilar(true, n); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_param_interface_in_impl.carbon:[[@LINE+1]]: could not find implementation of interface Similar(T = i32) for bool + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_param_interface_in_impl.carbon:[[@LINE+1]]: could not find implementation of interface Similar(T = i32) for bool CheckSimilar(n, false); return 0; } diff --git a/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon b/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon index 482048b46e62..c9ab20e996a7 100644 --- a/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon +++ b/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -46,7 +44,7 @@ fn Main() -> i32 { var a: Point(i32) = {.x = 1, .y = 1}; var b: Point(i32) = {.x = 2, .y = 3}; // TODO: This shouldn't be considered ambiguous. - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon:[[@LINE+1]]: ambiguous implementations of interface Vector(T = i32) for class Point(T = i32) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_unambiguous_impl_generic.carbon:[[@LINE+1]]: ambiguous implementations of interface Vector(T = i32) for class Point(T = i32) var p: Point(i32) = AddAndScaleGeneric(a, b, 5); return p.x - 15; } diff --git a/explorer/testdata/impl/fail_unmet_impl_constraint.carbon b/explorer/testdata/impl/fail_unmet_impl_constraint.carbon index 3e69d4280294..3795dc57b7a2 100644 --- a/explorer/testdata/impl/fail_unmet_impl_constraint.carbon +++ b/explorer/testdata/impl/fail_unmet_impl_constraint.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface A {} interface B {} -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_unmet_impl_constraint.carbon:[[@LINE+1]]: could not find implementation of interface B for i32 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/impl/fail_unmet_impl_constraint.carbon:[[@LINE+1]]: could not find implementation of interface B for i32 external impl i32 as A where i32 is B {} fn Main() -> i32 { diff --git a/explorer/testdata/impl/generic_method_impl.carbon b/explorer/testdata/impl/generic_method_impl.carbon index 01d600509927..cabe33ab7807 100644 --- a/explorer/testdata/impl/generic_method_impl.carbon +++ b/explorer/testdata/impl/generic_method_impl.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/impl/impl_constraint.carbon b/explorer/testdata/impl/impl_constraint.carbon index 49b5f6cc216f..5be7b44f35f4 100644 --- a/explorer/testdata/impl/impl_constraint.carbon +++ b/explorer/testdata/impl/impl_constraint.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1234 +// CHECK:result: 1234 package ExplorerTest api; diff --git a/explorer/testdata/impl/impl_in_generic_class.carbon b/explorer/testdata/impl/impl_in_generic_class.carbon index 94e2f2959d32..a858329d37ab 100644 --- a/explorer/testdata/impl/impl_in_generic_class.carbon +++ b/explorer/testdata/impl/impl_in_generic_class.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1133 +// CHECK:result: 1133 package ExplorerTest api; diff --git a/explorer/testdata/impl/param_impl.carbon b/explorer/testdata/impl/param_impl.carbon index 4b67ef17c222..4029d8c897db 100644 --- a/explorer/testdata/impl/param_impl.carbon +++ b/explorer/testdata/impl/param_impl.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/impl/param_impl2.carbon b/explorer/testdata/impl/param_impl2.carbon index 26fd213da650..f986f00a20da 100644 --- a/explorer/testdata/impl/param_impl2.carbon +++ b/explorer/testdata/impl/param_impl2.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/impl/param_impl_with_self.carbon b/explorer/testdata/impl/param_impl_with_self.carbon index 8a5e8f5e4988..9eef8beab04a 100644 --- a/explorer/testdata/impl/param_impl_with_self.carbon +++ b/explorer/testdata/impl/param_impl_with_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/impl/param_interface_in_impl.carbon b/explorer/testdata/impl/param_interface_in_impl.carbon index 6a25f89a9350..87fd79405823 100644 --- a/explorer/testdata/impl/param_interface_in_impl.carbon +++ b/explorer/testdata/impl/param_interface_in_impl.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/import/fail_nonexistent_library.carbon b/explorer/testdata/import/fail_nonexistent_library.carbon index a8f74073eee7..865a5c18bf2c 100644 --- a/explorer/testdata/import/fail_nonexistent_library.carbon +++ b/explorer/testdata/import/fail_nonexistent_library.carbon @@ -4,12 +4,10 @@ // // TODO: This SHOULD fail but doesn't presently. // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/import/fail_nonexistent_package.carbon b/explorer/testdata/import/fail_nonexistent_package.carbon index 15ce18350daf..835f807a9f2f 100644 --- a/explorer/testdata/import/fail_nonexistent_package.carbon +++ b/explorer/testdata/import/fail_nonexistent_package.carbon @@ -4,12 +4,10 @@ // // TODO: This SHOULD fail but doesn't presently. // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/import/fail_order.carbon b/explorer/testdata/import/fail_order.carbon index 93724a0c3ad5..9ed469348812 100644 --- a/explorer/testdata/import/fail_order.carbon +++ b/explorer/testdata/import/fail_order.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,5 +12,5 @@ fn Main() -> i32 { return 0; } -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/import/fail_order.carbon:[[@LINE+1]]: syntax error, unexpected IMPORT, expecting END_OF_FILE +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/import/fail_order.carbon:[[@LINE+1]]: syntax error, unexpected IMPORT, expecting END_OF_FILE import ExplorerTest library "Nonexistent"; diff --git a/explorer/testdata/interface/class_function.carbon b/explorer/testdata/interface/class_function.carbon index 9a27bc26c43d..4da06400a319 100644 --- a/explorer/testdata/interface/class_function.carbon +++ b/explorer/testdata/interface/class_function.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/constrained_parameter.carbon b/explorer/testdata/interface/constrained_parameter.carbon index e6b3a747e590..3e7468fa6d32 100644 --- a/explorer/testdata/interface/constrained_parameter.carbon +++ b/explorer/testdata/interface/constrained_parameter.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/external_impl_point_vector.carbon b/explorer/testdata/interface/external_impl_point_vector.carbon index 143ad3df2dc2..2c4ccf13732d 100644 --- a/explorer/testdata/interface/external_impl_point_vector.carbon +++ b/explorer/testdata/interface/external_impl_point_vector.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/external_impl_use_self.carbon b/explorer/testdata/interface/external_impl_use_self.carbon index cff62cf76d9f..e9bff8f6f5fb 100644 --- a/explorer/testdata/interface/external_impl_use_self.carbon +++ b/explorer/testdata/interface/external_impl_use_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/fail_bad_member_kind.carbon b/explorer/testdata/interface/fail_bad_member_kind.carbon index c101a5e96725..6b75a0db4f37 100644 --- a/explorer/testdata/interface/fail_bad_member_kind.carbon +++ b/explorer/testdata/interface/fail_bad_member_kind.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; interface Bad { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/interface/fail_bad_member_kind.carbon:[[@LINE+1]]: syntax error, unexpected VAR, expecting FN or LET or RIGHT_CURLY_BRACE + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/interface/fail_bad_member_kind.carbon:[[@LINE+1]]: syntax error, unexpected VAR, expecting FN or LET or RIGHT_CURLY_BRACE var V: i32; } diff --git a/explorer/testdata/interface/fail_external_impl_omit_self.carbon b/explorer/testdata/interface/fail_external_impl_omit_self.carbon index b4fb2e34fa1d..23faf5cffa77 100644 --- a/explorer/testdata/interface/fail_external_impl_omit_self.carbon +++ b/explorer/testdata/interface/fail_external_impl_omit_self.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -21,7 +19,7 @@ class Point { } // Error: need to specify which type implementing `Vector` for. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_external_impl_omit_self.carbon:[[@LINE+1]]: could not resolve 'Self' +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_external_impl_omit_self.carbon:[[@LINE+1]]: could not resolve 'Self' external impl as Vector { fn Add[me: Point](b: Point) -> Point { return {.x = me.x + b.x, .y = me.y + b.y}; diff --git a/explorer/testdata/interface/fail_external_impl_self.carbon b/explorer/testdata/interface/fail_external_impl_self.carbon index 84946129165c..6456b59570fd 100644 --- a/explorer/testdata/interface/fail_external_impl_self.carbon +++ b/explorer/testdata/interface/fail_external_impl_self.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,7 +18,7 @@ class Point { var y: i32; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_external_impl_self.carbon:[[@LINE+1]]: could not resolve 'Self' +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_external_impl_self.carbon:[[@LINE+1]]: could not resolve 'Self' external impl Self as Vector { fn Add[me: Point](b: Point) -> Point { return {.x = me.x + b.x, .y = me.y + b.y}; diff --git a/explorer/testdata/interface/fail_impl_bad_member.carbon b/explorer/testdata/interface/fail_impl_bad_member.carbon index 65d769f7d801..de901c067c67 100644 --- a/explorer/testdata/interface/fail_impl_bad_member.carbon +++ b/explorer/testdata/interface/fail_impl_bad_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -24,9 +22,9 @@ class Point { } fn Scale[me: Point](v: i32) -> i32 { return 0; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_bad_member.carbon:[[@LINE+3]]: type error in member of implementation - // CHECK: expected: fn (i32) -> class Point - // CHECK: actual: fn (i32) -> i32 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_bad_member.carbon:[[@LINE+3]]: type error in member of implementation + // CHECK:expected: fn (i32) -> class Point + // CHECK:actual: fn (i32) -> i32 } } } diff --git a/explorer/testdata/interface/fail_impl_missing_member.carbon b/explorer/testdata/interface/fail_impl_missing_member.carbon index 4d7b419e828b..c5b733a812cb 100644 --- a/explorer/testdata/interface/fail_impl_missing_member.carbon +++ b/explorer/testdata/interface/fail_impl_missing_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -22,7 +20,7 @@ class Point { fn Add[me: Point](b: Point) -> Point { return {.x = me.x + b.x, .y = me.y + b.y}; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_missing_member.carbon:[[@LINE+1]]: implementation missing Scale + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_missing_member.carbon:[[@LINE+1]]: implementation missing Scale } } diff --git a/explorer/testdata/interface/fail_impl_not_type.carbon b/explorer/testdata/interface/fail_impl_not_type.carbon index 8f766098f71b..752d10380b4a 100644 --- a/explorer/testdata/interface/fail_impl_not_type.carbon +++ b/explorer/testdata/interface/fail_impl_not_type.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; interface Vector { fn Zero() -> i32; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_not_type.carbon:[[@LINE+1]]: Expected a type, but got "hello" +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_impl_not_type.carbon:[[@LINE+1]]: Expected a type, but got "hello" impl "hello" as Vector { fn Zero() -> i32 { return 0; } } diff --git a/explorer/testdata/interface/fail_interface_missing_member.carbon b/explorer/testdata/interface/fail_interface_missing_member.carbon index 14bbe7fb0a46..60da98fb2c18 100644 --- a/explorer/testdata/interface/fail_interface_missing_member.carbon +++ b/explorer/testdata/interface/fail_interface_missing_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ interface Vector { } fn ScaleGeneric[T:! Vector](a: T, s: i32) -> T { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_interface_missing_member.carbon:[[@LINE+1]]: member access, Scale not in interface Vector + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_interface_missing_member.carbon:[[@LINE+1]]: member access, Scale not in interface Vector return a.Scale(s); } diff --git a/explorer/testdata/interface/fail_no_impl.carbon b/explorer/testdata/interface/fail_no_impl.carbon index db752f278856..832d071cb504 100644 --- a/explorer/testdata/interface/fail_no_impl.carbon +++ b/explorer/testdata/interface/fail_no_impl.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -27,7 +25,7 @@ fn AddAndScaleGeneric[T:! Vector](a: T, b: T, s: i32) -> T { fn Main() -> i32 { var a: Point = {.x = 0, .y = 0}; var b: Point = {.x = 2, .y = 3}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_no_impl.carbon:[[@LINE+1]]: could not find implementation of interface Vector for class Point + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_no_impl.carbon:[[@LINE+1]]: could not find implementation of interface Vector for class Point var p: Point = AddAndScaleGeneric(a, b, 3); return p.x - 6; } diff --git a/explorer/testdata/interface/fail_use_symbolic_member.carbon b/explorer/testdata/interface/fail_use_symbolic_member.carbon index 096016b327a8..7491b5ace047 100644 --- a/explorer/testdata/interface/fail_use_symbolic_member.carbon +++ b/explorer/testdata/interface/fail_use_symbolic_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ interface X { fn F() -> Type; } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_use_symbolic_member.carbon:[[@LINE+1]]: member lookup for F in symbolic witness for T:! X +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/interface/fail_use_symbolic_member.carbon:[[@LINE+1]]: member lookup for F in symbolic witness for T:! X fn G[T:! X]() -> T.F() { return {}; } diff --git a/explorer/testdata/interface/generic_call_generic.carbon b/explorer/testdata/interface/generic_call_generic.carbon index 9a016f1dbe0f..7102146bbb49 100644 --- a/explorer/testdata/interface/generic_call_generic.carbon +++ b/explorer/testdata/interface/generic_call_generic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/generic_with_two_params.carbon b/explorer/testdata/interface/generic_with_two_params.carbon index ac50395ee781..447d459eb068 100644 --- a/explorer/testdata/interface/generic_with_two_params.carbon +++ b/explorer/testdata/interface/generic_with_two_params.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/impl_self_interface_parameter.carbon b/explorer/testdata/interface/impl_self_interface_parameter.carbon index 24285f26432f..bb3c339419d0 100644 --- a/explorer/testdata/interface/impl_self_interface_parameter.carbon +++ b/explorer/testdata/interface/impl_self_interface_parameter.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/omit_self.carbon b/explorer/testdata/interface/omit_self.carbon index 32db2d5ae0f4..a04cb878e5a4 100644 --- a/explorer/testdata/interface/omit_self.carbon +++ b/explorer/testdata/interface/omit_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/param_with_dependent_type.carbon b/explorer/testdata/interface/param_with_dependent_type.carbon index e8ffa9e65627..26e35d62f0d8 100644 --- a/explorer/testdata/interface/param_with_dependent_type.carbon +++ b/explorer/testdata/interface/param_with_dependent_type.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 42 +// CHECK:result: 42 package ExplorerTest api; diff --git a/explorer/testdata/interface/parameterized.carbon b/explorer/testdata/interface/parameterized.carbon index c66d1cc71652..9ffcefc5b80c 100644 --- a/explorer/testdata/interface/parameterized.carbon +++ b/explorer/testdata/interface/parameterized.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/tuple_vector_add_scale.carbon b/explorer/testdata/interface/tuple_vector_add_scale.carbon index 35f6294685f6..c3078c4071d6 100644 --- a/explorer/testdata/interface/tuple_vector_add_scale.carbon +++ b/explorer/testdata/interface/tuple_vector_add_scale.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/vector_point_add_scale.carbon b/explorer/testdata/interface/vector_point_add_scale.carbon index 961b19c71360..343dfe3d7a19 100644 --- a/explorer/testdata/interface/vector_point_add_scale.carbon +++ b/explorer/testdata/interface/vector_point_add_scale.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/interface/with_self.carbon b/explorer/testdata/interface/with_self.carbon index 95c49ea532f8..0eb27e39f7fd 100644 --- a/explorer/testdata/interface/with_self.carbon +++ b/explorer/testdata/interface/with_self.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/let/fail_function_args.carbon b/explorer/testdata/let/fail_function_args.carbon index 1212434d9fe2..81e648bf5402 100644 --- a/explorer/testdata/let/fail_function_args.carbon +++ b/explorer/testdata/let/fail_function_args.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn f((var x: i32, y: i32)) -> i32 { x = 0; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_function_args.carbon:[[@LINE+1]]: Cannot assign to rvalue 'y' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_function_args.carbon:[[@LINE+1]]: Cannot assign to rvalue 'y' y = 0; return x - 1; } diff --git a/explorer/testdata/let/fail_global_assign.carbon b/explorer/testdata/let/fail_global_assign.carbon index b8299ba57df2..2b12f25095b4 100644 --- a/explorer/testdata/let/fail_global_assign.carbon +++ b/explorer/testdata/let/fail_global_assign.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; let x: i32 = 10; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_global_assign.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_global_assign.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' x = 0; return 0; } diff --git a/explorer/testdata/let/fail_global_named_self.carbon b/explorer/testdata/let/fail_global_named_self.carbon index 5afa959aeb33..5a0b5d5d0cc2 100644 --- a/explorer/testdata/let/fail_global_named_self.carbon +++ b/explorer/testdata/let/fail_global_named_self.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; // Error: Can't use keyword `Self` as the name of a global. -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_global_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_global_named_self.carbon:[[@LINE+1]]: syntax error, unexpected SELF, expecting identifier let Self: i32 = 10; fn Main() -> i32 { diff --git a/explorer/testdata/let/fail_local_assign.carbon b/explorer/testdata/let/fail_local_assign.carbon index d7c7ee1b86db..a9e157d89ed3 100644 --- a/explorer/testdata/let/fail_local_assign.carbon +++ b/explorer/testdata/let/fail_local_assign.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { let x: auto = 10; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_local_assign.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_local_assign.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' x = 0; return 0; } diff --git a/explorer/testdata/let/fail_local_named_self.carbon b/explorer/testdata/let/fail_local_named_self.carbon index bfab9364314c..0d78917f7658 100644 --- a/explorer/testdata/let/fail_local_named_self.carbon +++ b/explorer/testdata/let/fail_local_named_self.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { // Error: Can't use keyword `Self` as the name of a local. - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_local_named_self.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_local_named_self.carbon:[[@LINE+1]]: syntax error, unexpected COLON, expecting SLASH or binary * let Self: auto = 10; return 0; } diff --git a/explorer/testdata/let/fail_match_choice.carbon b/explorer/testdata/let/fail_match_choice.carbon index 089e6a272825..2625aaed32a1 100644 --- a/explorer/testdata/let/fail_match_choice.carbon +++ b/explorer/testdata/let/fail_match_choice.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -27,7 +25,7 @@ fn Main() -> i32 { n = n - 1; } case Ints.Two(x: auto, y: auto) => { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_match_choice.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_match_choice.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' x = 0; } } diff --git a/explorer/testdata/let/fail_method_args.carbon b/explorer/testdata/let/fail_method_args.carbon index f0c36a058a57..7527261dfbef 100644 --- a/explorer/testdata/let/fail_method_args.carbon +++ b/explorer/testdata/let/fail_method_args.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ class Point { } fn SetX[me: Point](x: i32) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_method_args.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_method_args.carbon:[[@LINE+1]]: Cannot assign to rvalue 'x' x = 10; } diff --git a/explorer/testdata/let/fail_tuple_pattern_let_context.carbon b/explorer/testdata/let/fail_tuple_pattern_let_context.carbon index 1914ea97cac5..acea767427cf 100644 --- a/explorer/testdata/let/fail_tuple_pattern_let_context.carbon +++ b/explorer/testdata/let/fail_tuple_pattern_let_context.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ fn Main() -> i32 { let (var a: auto, b: auto, c: auto, d: auto) = (1, 2, 3, 4); a = 0; // should fail - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_context.carbon:[[@LINE+1]]: Cannot assign to rvalue 'c' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_context.carbon:[[@LINE+1]]: Cannot assign to rvalue 'c' c = 0; return 0; } diff --git a/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon b/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon index 367b67796153..1abe6becf4a7 100644 --- a/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon +++ b/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon:[[@LINE+1]]: syntax error, unexpected LET + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_context_nested.carbon:[[@LINE+1]]: syntax error, unexpected LET let (var a: auto, b: auto, c: auto, var (d: auto, let e: auto)) = (1, 2, 3, (4, 5)); return 0; diff --git a/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon b/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon index 5425d423ca2a..ae9e3caf2c36 100644 --- a/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon +++ b/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon:[[@LINE+1]]: syntax error, unexpected LET + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/let/fail_tuple_pattern_let_in_var.carbon:[[@LINE+1]]: syntax error, unexpected LET var (var a: auto, b: auto, let c: auto, d: auto) = (1, 2, 3, 4); return 0; } diff --git a/explorer/testdata/let/implicit_conversion.carbon b/explorer/testdata/let/implicit_conversion.carbon index c6974d493109..8c2f4340dc1c 100644 --- a/explorer/testdata/let/implicit_conversion.carbon +++ b/explorer/testdata/let/implicit_conversion.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/let/implicit_conversion_choice.carbon b/explorer/testdata/let/implicit_conversion_choice.carbon index 3cc2864a8fe5..ad0823924d3b 100644 --- a/explorer/testdata/let/implicit_conversion_choice.carbon +++ b/explorer/testdata/let/implicit_conversion_choice.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/let/nested_tuple_pattern.carbon b/explorer/testdata/let/nested_tuple_pattern.carbon index 58c9c0259047..270c0e17d0d2 100644 --- a/explorer/testdata/let/nested_tuple_pattern.carbon +++ b/explorer/testdata/let/nested_tuple_pattern.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/linked_list/linked_list.carbon b/explorer/testdata/linked_list/linked_list.carbon index 1083cae9042a..d029e6b720a8 100644 --- a/explorer/testdata/linked_list/linked_list.carbon +++ b/explorer/testdata/linked_list/linked_list.carbon @@ -2,20 +2,18 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: 1 -// CHECK: 2 -// CHECK: 3 -// CHECK: 4 -// CHECK: 1 -// CHECK: 2 -// CHECK: 3 -// CHECK: 4 -// CHECK: result: 0 +// CHECK:1 +// CHECK:2 +// CHECK:3 +// CHECK:4 +// CHECK:1 +// CHECK:2 +// CHECK:3 +// CHECK:4 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/lit.cfg.py b/explorer/testdata/lit.cfg.py deleted file mode 100644 index 0f1166f60ee2..000000000000 --- a/explorer/testdata/lit.cfg.py +++ /dev/null @@ -1,42 +0,0 @@ -__copyright__ = """ -Part of the Carbon Language project, under the Apache License v2.0 with LLVM -Exceptions. See /LICENSE for license information. -SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -""" - -import lit.formats -import os - - -# This is a provided variable, ignore the undefined name warning. -config = config # noqa: F821 - - -def fullpath(relative_path): - return os.path.join(os.environ["TEST_SRCDIR"], relative_path) - - -config.name = "lit" -config.suffixes = [".carbon"] -config.test_format = lit.formats.ShTest() - -config.substitutions.append( - ("%{prelude}", fullpath("carbon/explorer/data/prelude.carbon")) -) -config.substitutions.append( - ( - "%{explorer}", - "%s --prelude=%s" - % ( - fullpath("carbon/explorer/explorer"), - fullpath("carbon/explorer/data/prelude.carbon"), - ), - ) -) -config.substitutions.append(("%{not}", fullpath("llvm-project/llvm/not"))) -config.substitutions.append( - ( - "%{FileCheck}", - fullpath("llvm-project/llvm/FileCheck --dump-input-filter=all"), - ) -) diff --git a/explorer/testdata/lit.cfg.py b/explorer/testdata/lit.cfg.py new file mode 120000 index 000000000000..b4c4a91c593d --- /dev/null +++ b/explorer/testdata/lit.cfg.py @@ -0,0 +1 @@ +../../bazel/testing/lit.cfg.py \ No newline at end of file diff --git a/explorer/testdata/match/any_int.carbon b/explorer/testdata/match/any_int.carbon index 48558070c0a0..cad9035ad0a3 100644 --- a/explorer/testdata/match/any_int.carbon +++ b/explorer/testdata/match/any_int.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/convert.carbon b/explorer/testdata/match/convert.carbon index 631aad4cf669..8b8a4e3b28b3 100644 --- a/explorer/testdata/match/convert.carbon +++ b/explorer/testdata/match/convert.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/exhaustive.carbon b/explorer/testdata/match/exhaustive.carbon index b79650c3ed58..288ab518fd0a 100644 --- a/explorer/testdata/match/exhaustive.carbon +++ b/explorer/testdata/match/exhaustive.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/match/exhaustive_bool.carbon b/explorer/testdata/match/exhaustive_bool.carbon index 7d6b4ae77e32..bbe2e79bbcdd 100644 --- a/explorer/testdata/match/exhaustive_bool.carbon +++ b/explorer/testdata/match/exhaustive_bool.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/match/exhaustive_exponential_8x.carbon b/explorer/testdata/match/exhaustive_exponential_8x.carbon index 3db0d472a176..ff35cbb8b83b 100644 --- a/explorer/testdata/match/exhaustive_exponential_8x.carbon +++ b/explorer/testdata/match/exhaustive_exponential_8x.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/exhaustive_exponential_series_t.carbon b/explorer/testdata/match/exhaustive_exponential_series_t.carbon index 2a322eb43230..86656923b03d 100644 --- a/explorer/testdata/match/exhaustive_exponential_series_t.carbon +++ b/explorer/testdata/match/exhaustive_exponential_series_t.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon b/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon index 97de14d82782..c6a8cd1f727c 100644 --- a/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon +++ b/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -31,5 +29,5 @@ fn Main() -> i32 { case (_: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, AB.B(), AB.A()) => { return 8; } case (_: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, AB.B()) => { return 9; } } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_exponential_9x.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type } diff --git a/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon b/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon index 1447d7f9ad66..a1b0d63f2442 100644 --- a/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon +++ b/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -40,5 +38,5 @@ fn Main() -> i32 { case (_: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, AB.A()) => { return 16; } case (_: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, _: AB, AB.B()) => { return 17; } } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_exponential_series_t.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type } diff --git a/explorer/testdata/match/fail_exhaustive_int.carbon b/explorer/testdata/match/fail_exhaustive_int.carbon index c77e9a20a25d..7929e49a1935 100644 --- a/explorer/testdata/match/fail_exhaustive_int.carbon +++ b/explorer/testdata/match/fail_exhaustive_int.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ fn A(n: i32) -> i32 { case 1 => { return 1; } case 2 => { return 2; } } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_int.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_exhaustive_int.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type } fn Main() -> i32 { diff --git a/explorer/testdata/match/fail_not_alternative.carbon b/explorer/testdata/match/fail_not_alternative.carbon index a647ee1abe56..efb0fa8a7e62 100644 --- a/explorer/testdata/match/fail_not_alternative.carbon +++ b/explorer/testdata/match/fail_not_alternative.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var x: i32 = 0; match (x) { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/match/fail_not_alternative.carbon:[[@LINE+1]]: Alternative pattern must have the form of a field access. + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/match/fail_not_alternative.carbon:[[@LINE+1]]: Alternative pattern must have the form of a field access. case i32(n: i32) => { return 1; } diff --git a/explorer/testdata/match/fail_not_exhaustive.carbon b/explorer/testdata/match/fail_not_exhaustive.carbon index cb882ba1a43e..1a28373c9f09 100644 --- a/explorer/testdata/match/fail_not_exhaustive.carbon +++ b/explorer/testdata/match/fail_not_exhaustive.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,7 +18,7 @@ fn A(a: Opt, b: Opt) -> i32 { case (Opt.Some(n: i32), _: auto) => { return n; } case (_: auto, Opt.Some(n: i32)) => { return n; } } -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_exhaustive.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_exhaustive.carbon:[[@LINE+1]]: non-exhaustive match may allow control-flow to reach the end of a function that provides a `->` return type } fn Main() -> i32 { diff --git a/explorer/testdata/match/fail_not_reachable.carbon b/explorer/testdata/match/fail_not_reachable.carbon index 89e42a1f9fad..e9a6c100b380 100644 --- a/explorer/testdata/match/fail_not_reachable.carbon +++ b/explorer/testdata/match/fail_not_reachable.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,7 +17,7 @@ fn A(a: Opt, b: Opt) -> i32 { match ((a, b)) { case (Opt.Some(n: i32), _: auto) => { return n; } case (_: auto, Opt.Some(n: i32)) => { return n; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_reachable.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_reachable.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases case (Opt.Some(m: i32), Opt.Some(n: i32)) => { return m + n; } } return 0; diff --git a/explorer/testdata/match/fail_not_reachable_default.carbon b/explorer/testdata/match/fail_not_reachable_default.carbon index 596b00cfe06a..c173e8ee3907 100644 --- a/explorer/testdata/match/fail_not_reachable_default.carbon +++ b/explorer/testdata/match/fail_not_reachable_default.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,7 +18,7 @@ fn A(a: Opt, b: Opt) -> i32 { case (Opt.None(), Opt.None()) => { return 0; } case (Opt.Some(n: i32), _: auto) => { return n; } case (_: auto, Opt.Some(n: i32)) => { return n; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_reachable_default.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_not_reachable_default.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases default => { return -1; } } return 0; diff --git a/explorer/testdata/match/fail_pattern_type_mismatch.carbon b/explorer/testdata/match/fail_pattern_type_mismatch.carbon index 49b620e1e7eb..91b3c972cd62 100644 --- a/explorer/testdata/match/fail_pattern_type_mismatch.carbon +++ b/explorer/testdata/match/fail_pattern_type_mismatch.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -23,9 +21,9 @@ fn Main() -> i32 { // expression when checking each pattern. match ((a, a)) { case (0, n: A) => { return 1; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_pattern_type_mismatch.carbon:[[@LINE+3]]: type error in `match` pattern type - // CHECK: expected: (i32, class A) - // CHECK: actual: (class A, i32) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_pattern_type_mismatch.carbon:[[@LINE+3]]: type error in `match` pattern type + // CHECK:expected: (i32, class A) + // CHECK:actual: (class A, i32) case (n: A, 0) => { return 1; } case (1, 1) => { return 0; } } diff --git a/explorer/testdata/match/fail_redundant_int.carbon b/explorer/testdata/match/fail_redundant_int.carbon index 144ae4176bfc..255e4514749b 100644 --- a/explorer/testdata/match/fail_redundant_int.carbon +++ b/explorer/testdata/match/fail_redundant_int.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn A(n: i32) -> i32 { match (n) { case 1 => { return 1; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_redundant_int.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/match/fail_redundant_int.carbon:[[@LINE+1]]: unreachable case: all values matched by this case are matched by earlier cases case 1 => { return 2; } case (_: i32) => { return 3; } } diff --git a/explorer/testdata/match/int.carbon b/explorer/testdata/match/int.carbon index 0b8088dbbd77..c3eff63c9b47 100644 --- a/explorer/testdata/match/int.carbon +++ b/explorer/testdata/match/int.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/int_default.carbon b/explorer/testdata/match/int_default.carbon index d928c0a84541..cd5a1336c1e4 100644 --- a/explorer/testdata/match/int_default.carbon +++ b/explorer/testdata/match/int_default.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/no_match.carbon b/explorer/testdata/match/no_match.carbon index 31d27ee1d60f..d2ef6872714a 100644 --- a/explorer/testdata/match/no_match.carbon +++ b/explorer/testdata/match/no_match.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/match/placeholder.carbon b/explorer/testdata/match/placeholder.carbon index be672479f4c2..fc187e5656cc 100644 --- a/explorer/testdata/match/placeholder.carbon +++ b/explorer/testdata/match/placeholder.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/member_access/convert_lhs_class.carbon b/explorer/testdata/member_access/convert_lhs_class.carbon index 29c74a36e464..077f4d4e2803 100644 --- a/explorer/testdata/member_access/convert_lhs_class.carbon +++ b/explorer/testdata/member_access/convert_lhs_class.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; diff --git a/explorer/testdata/member_access/convert_lhs_interface.carbon b/explorer/testdata/member_access/convert_lhs_interface.carbon index 811d3d5cf84f..06dfce8bef45 100644 --- a/explorer/testdata/member_access/convert_lhs_interface.carbon +++ b/explorer/testdata/member_access/convert_lhs_interface.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; diff --git a/explorer/testdata/member_access/evaluate_type_before_dot.carbon b/explorer/testdata/member_access/evaluate_type_before_dot.carbon index bc3795c3e385..e5acc39c2dbd 100644 --- a/explorer/testdata/member_access/evaluate_type_before_dot.carbon +++ b/explorer/testdata/member_access/evaluate_type_before_dot.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Struct OK -// CHECK: Choice OK -// CHECK: Class OK -// CHECK: Interface OK -// CHECK: Constraint OK -// CHECK: result: 0 +// CHECK:Struct OK +// CHECK:Choice OK +// CHECK:Class OK +// CHECK:Interface OK +// CHECK:Constraint OK +// CHECK:result: 0 package Foo api; diff --git a/explorer/testdata/member_access/fail_qualified_non_member.carbon b/explorer/testdata/member_access/fail_qualified_non_member.carbon index 6252ce58ebe3..4b611ba59a0f 100644 --- a/explorer/testdata/member_access/fail_qualified_non_member.carbon +++ b/explorer/testdata/member_access/fail_qualified_non_member.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package Foo api; @@ -13,7 +11,7 @@ fn F[me: i32]() {} fn Main() -> i32 { // TODO: It's unclear whether this is valid per the current rules. See // https://github.com/carbon-language/carbon-lang/pull/1122 - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_qualified_non_member.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> () + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_qualified_non_member.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> () 42.(F)(); return 0; } diff --git a/explorer/testdata/member_access/fail_vacuous_access.carbon b/explorer/testdata/member_access/fail_vacuous_access.carbon index 140c1782dc88..9c60231bf968 100644 --- a/explorer/testdata/member_access/fail_vacuous_access.carbon +++ b/explorer/testdata/member_access/fail_vacuous_access.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package Foo api; @@ -17,6 +15,6 @@ class X { } fn Main() -> i32 { var a: X = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_vacuous_access.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> i32 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_vacuous_access.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> i32 return a.(X.(A.F))(); } diff --git a/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon b/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon index a47469912491..c49ce859e52f 100644 --- a/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon +++ b/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package Foo api; @@ -16,7 +14,7 @@ class X { } } fn F[T:! A](a: T) -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> i32 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/member_access/fail_vacuous_access_via_type_param.carbon:[[@LINE+1]]: expected name of instance member or interface member in compound member access, found fn () -> i32 return a.(T.F)(); } fn Main() -> i32 { diff --git a/explorer/testdata/member_access/nearly_vacuous_access_with_impl_lookup.carbon b/explorer/testdata/member_access/nearly_vacuous_access_with_impl_lookup.carbon index fe6c1d6d053e..c3ba3c8b6219 100644 --- a/explorer/testdata/member_access/nearly_vacuous_access_with_impl_lookup.carbon +++ b/explorer/testdata/member_access/nearly_vacuous_access_with_impl_lookup.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package Foo api; interface A { fn F() -> i32; } diff --git a/explorer/testdata/member_access/nearly_vacuous_access_with_instance_binding.carbon b/explorer/testdata/member_access/nearly_vacuous_access_with_instance_binding.carbon index 9cc8cffd7871..0c1dbb48f7a9 100644 --- a/explorer/testdata/member_access/nearly_vacuous_access_with_instance_binding.carbon +++ b/explorer/testdata/member_access/nearly_vacuous_access_with_instance_binding.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package Foo api; interface A { fn F[me: Self]() -> i32; } diff --git a/explorer/testdata/member_access/param_qualified_interface_member.carbon b/explorer/testdata/member_access/param_qualified_interface_member.carbon index bfb8f63f810d..8116279dea64 100644 --- a/explorer/testdata/member_access/param_qualified_interface_member.carbon +++ b/explorer/testdata/member_access/param_qualified_interface_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; interface A { diff --git a/explorer/testdata/member_access/qualified_class_member.carbon b/explorer/testdata/member_access/qualified_class_member.carbon index c2e16ab4f13e..4cb975cd3dde 100644 --- a/explorer/testdata/member_access/qualified_class_member.carbon +++ b/explorer/testdata/member_access/qualified_class_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; class X { diff --git a/explorer/testdata/member_access/qualified_constraint_member.carbon b/explorer/testdata/member_access/qualified_constraint_member.carbon index ed62b95a7398..3a3bc295c716 100644 --- a/explorer/testdata/member_access/qualified_constraint_member.carbon +++ b/explorer/testdata/member_access/qualified_constraint_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 12 +// CHECK:result: 12 package Foo api; interface A { diff --git a/explorer/testdata/member_access/qualified_interface_member.carbon b/explorer/testdata/member_access/qualified_interface_member.carbon index 77fca174a6f3..8c7e2cd79b12 100644 --- a/explorer/testdata/member_access/qualified_interface_member.carbon +++ b/explorer/testdata/member_access/qualified_interface_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; interface A { diff --git a/explorer/testdata/member_access/qualified_param_member.carbon b/explorer/testdata/member_access/qualified_param_member.carbon index e3d16d6f94b7..9bd0fd2c34a2 100644 --- a/explorer/testdata/member_access/qualified_param_member.carbon +++ b/explorer/testdata/member_access/qualified_param_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package Foo api; interface A { diff --git a/explorer/testdata/member_access/qualified_struct_member.carbon b/explorer/testdata/member_access/qualified_struct_member.carbon index 5a1076c176d7..e5bc2e4aa615 100644 --- a/explorer/testdata/member_access/qualified_struct_member.carbon +++ b/explorer/testdata/member_access/qualified_struct_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package Foo api; fn Main() -> i32 { diff --git a/explorer/testdata/member_access/type_qualified_interface_member.carbon b/explorer/testdata/member_access/type_qualified_interface_member.carbon index b95a0ef3f4d0..78d5509ca69d 100644 --- a/explorer/testdata/member_access/type_qualified_interface_member.carbon +++ b/explorer/testdata/member_access/type_qualified_interface_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 42 +// CHECK:result: 42 package Foo api; interface HasDefault { diff --git a/explorer/testdata/mixin/fail_circular_mixing.carbon b/explorer/testdata/mixin/fail_circular_mixing.carbon index 13bf3d19506c..2e428995eafd 100644 --- a/explorer/testdata/mixin/fail_circular_mixing.carbon +++ b/explorer/testdata/mixin/fail_circular_mixing.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ __mixin M1 { fn F1[me: Self](x: Self) -> Self{ return x; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_circular_mixing.carbon:[[@LINE+1]]: 'M3' has not been declared yet + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_circular_mixing.carbon:[[@LINE+1]]: 'M3' has not been declared yet __mix M3; } diff --git a/explorer/testdata/mixin/fail_field_member_name_clash.carbon b/explorer/testdata/mixin/fail_field_member_name_clash.carbon index f0e5f6acfbee..6123b18d9798 100644 --- a/explorer/testdata/mixin/fail_field_member_name_clash.carbon +++ b/explorer/testdata/mixin/fail_field_member_name_clash.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,7 +17,7 @@ __mixin M { class C { let F: i32 = 0; __mix M; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:[[@LINE+1]]: Member named F (declared at {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:16) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:20) +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:[[@LINE+1]]: Member named F (declared at {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:14) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_field_member_name_clash.carbon:18) } fn Main() -> i32 { diff --git a/explorer/testdata/mixin/fail_method_member_name_clash.carbon b/explorer/testdata/mixin/fail_method_member_name_clash.carbon index 2b18c62df677..c80d50cf7c35 100644 --- a/explorer/testdata/mixin/fail_method_member_name_clash.carbon +++ b/explorer/testdata/mixin/fail_method_member_name_clash.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -21,7 +19,7 @@ class C { return x; } __mix M; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:[[@LINE+1]]: Member named F (declared at {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:16) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:22) +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:[[@LINE+1]]: Member named F (declared at {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:14) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_method_member_name_clash.carbon:20) } fn Main() -> i32 { diff --git a/explorer/testdata/mixin/fail_mix_as_type_expr.carbon b/explorer/testdata/mixin/fail_mix_as_type_expr.carbon index b1fa73cdeed9..2871f92f8efa 100644 --- a/explorer/testdata/mixin/fail_mix_as_type_expr.carbon +++ b/explorer/testdata/mixin/fail_mix_as_type_expr.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; __mixin Operations {} fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_as_type_expr.carbon:[[@LINE+1]]: Expected a type, but got mixin Operations + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_as_type_expr.carbon:[[@LINE+1]]: Expected a type, but got mixin Operations var a: Operations; return 0; } diff --git a/explorer/testdata/mixin/fail_mix_diamond_clash.carbon b/explorer/testdata/mixin/fail_mix_diamond_clash.carbon index e7b7bf5318bf..a295a30b430d 100644 --- a/explorer/testdata/mixin/fail_mix_diamond_clash.carbon +++ b/explorer/testdata/mixin/fail_mix_diamond_clash.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -30,7 +28,7 @@ __mixin M3 { class C { __mix M2; __mix M3; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_diamond_clash.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_mix_diamond_clash.carbon:15) is being mixed multiple times into C +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_diamond_clash.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_mix_diamond_clash.carbon:13) is being mixed multiple times into C } fn Main() -> i32 { diff --git a/explorer/testdata/mixin/fail_mix_in_global.carbon b/explorer/testdata/mixin/fail_mix_in_global.carbon index 39f99f4e7bb5..e0912613b361 100644 --- a/explorer/testdata/mixin/fail_mix_in_global.carbon +++ b/explorer/testdata/mixin/fail_mix_in_global.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,7 +14,7 @@ __mixin Operations { } } -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_in_global.carbon:[[@LINE+1]]: syntax error, unexpected MIX, expecting END_OF_FILE +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_in_global.carbon:[[@LINE+1]]: syntax error, unexpected MIX, expecting END_OF_FILE __mix Operations; class Point { diff --git a/explorer/testdata/mixin/fail_mix_in_impl.carbon b/explorer/testdata/mixin/fail_mix_in_impl.carbon index 2fb52bf159e8..c1fa313bd457 100644 --- a/explorer/testdata/mixin/fail_mix_in_impl.carbon +++ b/explorer/testdata/mixin/fail_mix_in_impl.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -21,7 +19,7 @@ interface A { } external impl i32 as A { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_in_impl.carbon:[[@LINE+1]]: syntax error, unexpected MIX, expecting ALIAS or FN or RIGHT_CURLY_BRACE + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_in_impl.carbon:[[@LINE+1]]: syntax error, unexpected MIX, expecting ALIAS or FN or RIGHT_CURLY_BRACE __mix Operations; fn F() {} } diff --git a/explorer/testdata/mixin/fail_mix_members_clash.carbon b/explorer/testdata/mixin/fail_mix_members_clash.carbon index 183e345d7e20..c9eac843fe81 100644 --- a/explorer/testdata/mixin/fail_mix_members_clash.carbon +++ b/explorer/testdata/mixin/fail_mix_members_clash.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -23,7 +21,7 @@ __mixin M2 { class C { __mix M1; __mix M2; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:20) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:15) +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:18) cannot be mixed into C because it clashes with an existing member with the same name (declared at {{.*}}/explorer/testdata/mixin/fail_mix_members_clash.carbon:13) } fn Main() -> i32 { diff --git a/explorer/testdata/mixin/fail_recursive_mixing.carbon b/explorer/testdata/mixin/fail_recursive_mixing.carbon index 70267364ecb1..95dc11748009 100644 --- a/explorer/testdata/mixin/fail_recursive_mixing.carbon +++ b/explorer/testdata/mixin/fail_recursive_mixing.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,7 +12,7 @@ __mixin M1 { return x; } __mix M1; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_recursive_mixing.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_recursive_mixing.carbon:15) is being mixed multiple times into M1 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_recursive_mixing.carbon:[[@LINE+1]]: Member named F1 (declared at {{.*}}/explorer/testdata/mixin/fail_recursive_mixing.carbon:13) is being mixed multiple times into M1 } class C { diff --git a/explorer/testdata/mixin/fail_self_substitution.carbon b/explorer/testdata/mixin/fail_self_substitution.carbon index cd117b0a8434..b0834d080f41 100644 --- a/explorer/testdata/mixin/fail_self_substitution.carbon +++ b/explorer/testdata/mixin/fail_self_substitution.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -38,7 +36,7 @@ class Complex { fn Main() -> i32 { var p: Point = Point.Origin(); var c: Complex = {.r = 42, .i = 1}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_self_substitution.carbon:[[@LINE+1]]: type error in call: 'class Complex' is not implicitly convertible to 'class Point' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/mixin/fail_self_substitution.carbon:[[@LINE+1]]: type error in call: 'class Complex' is not implicitly convertible to 'class Point' var p1: Point = p.F(c); return p1.x - 42; diff --git a/explorer/testdata/mixin/self_substitution.carbon b/explorer/testdata/mixin/self_substitution.carbon index d66f78f19d65..e99d89c69c5c 100644 --- a/explorer/testdata/mixin/self_substitution.carbon +++ b/explorer/testdata/mixin/self_substitution.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/mixin/simple_mix_in_mixin.carbon b/explorer/testdata/mixin/simple_mix_in_mixin.carbon index 0e0012e668bb..dd092736fc7c 100644 --- a/explorer/testdata/mixin/simple_mix_in_mixin.carbon +++ b/explorer/testdata/mixin/simple_mix_in_mixin.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/mixin/simple_reuse.carbon b/explorer/testdata/mixin/simple_reuse.carbon index 855e1310f054..8bfe216f707c 100644 --- a/explorer/testdata/mixin/simple_reuse.carbon +++ b/explorer/testdata/mixin/simple_reuse.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/mixin/use_mixin_method_in_class_method.carbon b/explorer/testdata/mixin/use_mixin_method_in_class_method.carbon index bd0b5687b5ee..eb70ac72f5fa 100644 --- a/explorer/testdata/mixin/use_mixin_method_in_class_method.carbon +++ b/explorer/testdata/mixin/use_mixin_method_in_class_method.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/name_lookup/class_fn_body_reorder.carbon b/explorer/testdata/name_lookup/class_fn_body_reorder.carbon index 2c7b60869978..3b577dfb2c81 100644 --- a/explorer/testdata/name_lookup/class_fn_body_reorder.carbon +++ b/explorer/testdata/name_lookup/class_fn_body_reorder.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/name_lookup/fail_block_duplicate.carbon b/explorer/testdata/name_lookup/fail_block_duplicate.carbon index cb394809df37..0c81e5ead523 100644 --- a/explorer/testdata/name_lookup/fail_block_duplicate.carbon +++ b/explorer/testdata/name_lookup/fail_block_duplicate.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32 = 0; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_block_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_block_duplicate.carbon:14 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_block_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_block_duplicate.carbon:12 var x: i32 = 0; return 0; } diff --git a/explorer/testdata/name_lookup/fail_choice_duplicate.carbon b/explorer/testdata/name_lookup/fail_choice_duplicate.carbon index 0de0d5ee4df2..903037dce0d9 100644 --- a/explorer/testdata/name_lookup/fail_choice_duplicate.carbon +++ b/explorer/testdata/name_lookup/fail_choice_duplicate.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; choice Ints { None, - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_choice_duplicate.carbon:[[@LINE+1]]: Duplicate name `None` in choice type + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_choice_duplicate.carbon:[[@LINE+1]]: Duplicate name `None` in choice type None, } diff --git a/explorer/testdata/name_lookup/fail_class_duplicate.carbon b/explorer/testdata/name_lookup/fail_class_duplicate.carbon index 3178ac1de59c..7cac7f7aff17 100644 --- a/explorer/testdata/name_lookup/fail_class_duplicate.carbon +++ b/explorer/testdata/name_lookup/fail_class_duplicate.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; class Foo { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_class_duplicate.carbon:14 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_class_duplicate.carbon:12 var x: i32; } diff --git a/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon b/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon index 8ed8ec5886f9..afcbba988c0c 100644 --- a/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon +++ b/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -21,7 +19,7 @@ class A { return 0; } - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon:[[@LINE+1]]: 'I' has not been declared yet + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_fn_use_before_declaration.carbon:[[@LINE+1]]: 'I' has not been declared yet fn H() -> I() { return 0; } diff --git a/explorer/testdata/name_lookup/fail_class_use_in_params.carbon b/explorer/testdata/name_lookup/fail_class_use_in_params.carbon index 0970cb35cb46..c31f34f82c43 100644 --- a/explorer/testdata/name_lookup/fail_class_use_in_params.carbon +++ b/explorer/testdata/name_lookup/fail_class_use_in_params.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_use_in_params.carbon:[[@LINE+1]]: 'A' is not usable until after it has been completely declared +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_class_use_in_params.carbon:[[@LINE+1]]: 'A' is not usable until after it has been completely declared class A(X:! A(i32)) { } diff --git a/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon b/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon index 8788c11c0683..0fed8e48aa8f 100644 --- a/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon +++ b/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon:[[@LINE+1]]: 'F' is not usable until after it has been completely declared +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_fn_use_in_param.carbon:[[@LINE+1]]: 'F' is not usable until after it has been completely declared fn F(x: F(0)) -> Type { return i32; } diff --git a/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon b/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon index 5013c42734a9..dbe7aaa688a2 100644 --- a/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon +++ b/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon:[[@LINE+1]]: 'F' is not usable until after it has been completely declared +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_fn_use_in_return_type.carbon:[[@LINE+1]]: 'F' is not usable until after it has been completely declared fn F() -> F() { return Type; } diff --git a/explorer/testdata/name_lookup/fail_global_duplicate.carbon b/explorer/testdata/name_lookup/fail_global_duplicate.carbon index 319a13416134..c110a0f55f55 100644 --- a/explorer/testdata/name_lookup/fail_global_duplicate.carbon +++ b/explorer/testdata/name_lookup/fail_global_duplicate.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; var x: i32 = 0; -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_global_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_global_duplicate.carbon:13 +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_global_duplicate.carbon:[[@LINE+1]]: Duplicate name `x` also found at {{.*}}/explorer/testdata/name_lookup/fail_global_duplicate.carbon:11 var x: i32 = 0; fn Main() -> i32 { diff --git a/explorer/testdata/name_lookup/fail_use_before_declare.carbon b/explorer/testdata/name_lookup/fail_use_before_declare.carbon index e693f772db5f..d720ff0e9397 100644 --- a/explorer/testdata/name_lookup/fail_use_before_declare.carbon +++ b/explorer/testdata/name_lookup/fail_use_before_declare.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_use_before_declare.carbon:[[@LINE+1]]: could not resolve 'x' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_use_before_declare.carbon:[[@LINE+1]]: could not resolve 'x' x = 0; var x: i32 = 0; return 0; diff --git a/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon b/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon index 1f44b45317ce..445ed8c9a7d9 100644 --- a/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon +++ b/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; // Test that a global variable may not depend on a later global. // Error expected. -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon:[[@LINE+1]]: 'y' has not been declared yet +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/name_lookup/fail_var_use_before_declaration.carbon:[[@LINE+1]]: 'y' has not been declared yet var x: i32 = y; var y: i32 = 0; diff --git a/explorer/testdata/name_lookup/global_shadow.carbon b/explorer/testdata/name_lookup/global_shadow.carbon index aebe34d86ff6..d53f81dffd6f 100644 --- a/explorer/testdata/name_lookup/global_shadow.carbon +++ b/explorer/testdata/name_lookup/global_shadow.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/name_lookup/match_shadow.carbon b/explorer/testdata/name_lookup/match_shadow.carbon index 572ec03d2d42..88cbd94e4ac0 100644 --- a/explorer/testdata/name_lookup/match_shadow.carbon +++ b/explorer/testdata/name_lookup/match_shadow.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/operators/add.carbon b/explorer/testdata/operators/add.carbon index 6bf042244704..a54e57e95011 100644 --- a/explorer/testdata/operators/add.carbon +++ b/explorer/testdata/operators/add.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 6 +// CHECK:result: 6 package ExplorerTest api; diff --git a/explorer/testdata/operators/add_builtin.carbon b/explorer/testdata/operators/add_builtin.carbon index e61291de95ea..d1fb03952aec 100644 --- a/explorer/testdata/operators/add_builtin.carbon +++ b/explorer/testdata/operators/add_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: 5 -// CHECK: Op: 5 -// CHECK: result: 0 +// CHECK:Interface: 5 +// CHECK:Op: 5 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/bit_and.carbon b/explorer/testdata/operators/bit_and.carbon index 08f633ad8576..92b7bac58eeb 100644 --- a/explorer/testdata/operators/bit_and.carbon +++ b/explorer/testdata/operators/bit_and.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/operators/bit_complement.carbon b/explorer/testdata/operators/bit_complement.carbon index ee13e9ac3ca1..e9b2f5ec077b 100644 --- a/explorer/testdata/operators/bit_complement.carbon +++ b/explorer/testdata/operators/bit_complement.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: -6 +// CHECK:result: -6 package ExplorerTest api; diff --git a/explorer/testdata/operators/bit_or.carbon b/explorer/testdata/operators/bit_or.carbon index 3487110474bc..d6e4117e69de 100644 --- a/explorer/testdata/operators/bit_or.carbon +++ b/explorer/testdata/operators/bit_or.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 5 +// CHECK:result: 5 package ExplorerTest api; diff --git a/explorer/testdata/operators/bit_xor.carbon b/explorer/testdata/operators/bit_xor.carbon index d9255cb39e18..d3f7f61d4421 100644 --- a/explorer/testdata/operators/bit_xor.carbon +++ b/explorer/testdata/operators/bit_xor.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 4 +// CHECK:result: 4 package ExplorerTest api; diff --git a/explorer/testdata/operators/bitwise.carbon b/explorer/testdata/operators/bitwise.carbon index ec82042d997c..93de60c8a113 100644 --- a/explorer/testdata/operators/bitwise.carbon +++ b/explorer/testdata/operators/bitwise.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/div.carbon b/explorer/testdata/operators/div.carbon index c15176a94330..0fc7076987e2 100644 --- a/explorer/testdata/operators/div.carbon +++ b/explorer/testdata/operators/div.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/operators/div_builtin.carbon b/explorer/testdata/operators/div_builtin.carbon index e73a4e3fc8e2..4af51e5711dc 100644 --- a/explorer/testdata/operators/div_builtin.carbon +++ b/explorer/testdata/operators/div_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: 2 -// CHECK: Op: 2 -// CHECK: result: 0 +// CHECK:Interface: 2 +// CHECK:Op: 2 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/fail_no_add.carbon b/explorer/testdata/operators/fail_no_add.carbon index 4d063eadd422..2d225fd319d4 100644 --- a/explorer/testdata/operators/fail_no_add.carbon +++ b/explorer/testdata/operators/fail_no_add.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,8 +12,8 @@ class A {} fn Main() -> i32 { var a: A = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_add.carbon:[[@LINE+2]]: type error in `+`: - // CHECK: could not find implementation of interface AddWith(U = i32) for class A + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_add.carbon:[[@LINE+2]]: type error in `+`: + // CHECK:could not find implementation of interface AddWith(U = i32) for class A a + 1; return 0; } diff --git a/explorer/testdata/operators/fail_no_mul.carbon b/explorer/testdata/operators/fail_no_mul.carbon index 0b6ab1fcc712..53b26126de5d 100644 --- a/explorer/testdata/operators/fail_no_mul.carbon +++ b/explorer/testdata/operators/fail_no_mul.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,8 +12,8 @@ class A {} fn Main() -> i32 { var a: A = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_mul.carbon:[[@LINE+2]]: type error in `*`: - // CHECK: could not find implementation of interface MulWith(U = i32) for class A + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_mul.carbon:[[@LINE+2]]: type error in `*`: + // CHECK:could not find implementation of interface MulWith(U = i32) for class A a * 1; return 0; } diff --git a/explorer/testdata/operators/fail_no_negate.carbon b/explorer/testdata/operators/fail_no_negate.carbon index 249ffcdbf455..b5f11b13cfa1 100644 --- a/explorer/testdata/operators/fail_no_negate.carbon +++ b/explorer/testdata/operators/fail_no_negate.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,8 +12,8 @@ class A {} fn Main() -> i32 { var a: A = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_negate.carbon:[[@LINE+2]]: type error in `-`: - // CHECK: could not find implementation of interface Negate for class A + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_negate.carbon:[[@LINE+2]]: type error in `-`: + // CHECK:could not find implementation of interface Negate for class A -a; return 0; } diff --git a/explorer/testdata/operators/fail_no_sub.carbon b/explorer/testdata/operators/fail_no_sub.carbon index 492d54c35342..791228f60740 100644 --- a/explorer/testdata/operators/fail_no_sub.carbon +++ b/explorer/testdata/operators/fail_no_sub.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -14,8 +12,8 @@ class A {} fn Main() -> i32 { var a: A = {}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_sub.carbon:[[@LINE+2]]: type error in `-`: - // CHECK: could not find implementation of interface SubWith(U = i32) for class A + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/operators/fail_no_sub.carbon:[[@LINE+2]]: type error in `-`: + // CHECK:could not find implementation of interface SubWith(U = i32) for class A a - 1; return 0; } diff --git a/explorer/testdata/operators/left_shift.carbon b/explorer/testdata/operators/left_shift.carbon index 02ec75e691ea..536ef8f7d45a 100644 --- a/explorer/testdata/operators/left_shift.carbon +++ b/explorer/testdata/operators/left_shift.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 10 +// CHECK:result: 10 package ExplorerTest api; diff --git a/explorer/testdata/operators/mod.carbon b/explorer/testdata/operators/mod.carbon index 336671c00bcd..5d6cd6a5fb60 100644 --- a/explorer/testdata/operators/mod.carbon +++ b/explorer/testdata/operators/mod.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/operators/mod_builtin.carbon b/explorer/testdata/operators/mod_builtin.carbon index cf3f2f753ed2..176bfa58b49c 100644 --- a/explorer/testdata/operators/mod_builtin.carbon +++ b/explorer/testdata/operators/mod_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: 2 -// CHECK: Op: 2 -// CHECK: result: 0 +// CHECK:Interface: 2 +// CHECK:Op: 2 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/mod_edges.carbon b/explorer/testdata/operators/mod_edges.carbon index 8350cea2c89f..2f81cf592f76 100644 --- a/explorer/testdata/operators/mod_edges.carbon +++ b/explorer/testdata/operators/mod_edges.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/mul.carbon b/explorer/testdata/operators/mul.carbon index a9c89c4f93f8..a0ebb723cee3 100644 --- a/explorer/testdata/operators/mul.carbon +++ b/explorer/testdata/operators/mul.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 10 +// CHECK:result: 10 package ExplorerTest api; diff --git a/explorer/testdata/operators/mul_builtin.carbon b/explorer/testdata/operators/mul_builtin.carbon index 563fdcc63b5b..74de6e22bee6 100644 --- a/explorer/testdata/operators/mul_builtin.carbon +++ b/explorer/testdata/operators/mul_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: 6 -// CHECK: Op: 6 -// CHECK: result: 0 +// CHECK:Interface: 6 +// CHECK:Op: 6 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/negate.carbon b/explorer/testdata/operators/negate.carbon index 2b2a32c93421..b48ffa6970fc 100644 --- a/explorer/testdata/operators/negate.carbon +++ b/explorer/testdata/operators/negate.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: -5 +// CHECK:result: -5 package ExplorerTest api; diff --git a/explorer/testdata/operators/negate_builtin.carbon b/explorer/testdata/operators/negate_builtin.carbon index a9999d717118..de13666db2fc 100644 --- a/explorer/testdata/operators/negate_builtin.carbon +++ b/explorer/testdata/operators/negate_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: -3 -// CHECK: Op: -3 -// CHECK: result: 0 +// CHECK:Interface: -3 +// CHECK:Op: -3 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/right_shift.carbon b/explorer/testdata/operators/right_shift.carbon index c539dedac4d6..1a3aae50d4e7 100644 --- a/explorer/testdata/operators/right_shift.carbon +++ b/explorer/testdata/operators/right_shift.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/operators/shift.carbon b/explorer/testdata/operators/shift.carbon index 920e706887ab..fbe571c3db32 100644 --- a/explorer/testdata/operators/shift.carbon +++ b/explorer/testdata/operators/shift.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/operators/shortcircuit_and.carbon b/explorer/testdata/operators/shortcircuit_and.carbon index 0f789bbdc719..91f64db75e88 100644 --- a/explorer/testdata/operators/shortcircuit_and.carbon +++ b/explorer/testdata/operators/shortcircuit_and.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/operators/shortcircuit_and_no_shortcircuit.carbon b/explorer/testdata/operators/shortcircuit_and_no_shortcircuit.carbon index 2d97faa60db9..ad568e46d6f3 100644 --- a/explorer/testdata/operators/shortcircuit_and_no_shortcircuit.carbon +++ b/explorer/testdata/operators/shortcircuit_and_no_shortcircuit.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/operators/shortcircuit_or.carbon b/explorer/testdata/operators/shortcircuit_or.carbon index 1f1e4427e4a2..4572f98195a7 100644 --- a/explorer/testdata/operators/shortcircuit_or.carbon +++ b/explorer/testdata/operators/shortcircuit_or.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/operators/shortcircuit_or_no_shortcircuit.carbon b/explorer/testdata/operators/shortcircuit_or_no_shortcircuit.carbon index d9de7b61770a..3048b03dc4fe 100644 --- a/explorer/testdata/operators/shortcircuit_or_no_shortcircuit.carbon +++ b/explorer/testdata/operators/shortcircuit_or_no_shortcircuit.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 2 +// CHECK:result: 2 package ExplorerTest api; diff --git a/explorer/testdata/operators/sub.carbon b/explorer/testdata/operators/sub.carbon index f9ed3a4438e4..3f3564950018 100644 --- a/explorer/testdata/operators/sub.carbon +++ b/explorer/testdata/operators/sub.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 4 +// CHECK:result: 4 package ExplorerTest api; diff --git a/explorer/testdata/operators/sub_builtin.carbon b/explorer/testdata/operators/sub_builtin.carbon index b328ad394cfc..e7ec8990cb0f 100644 --- a/explorer/testdata/operators/sub_builtin.carbon +++ b/explorer/testdata/operators/sub_builtin.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Interface: 5 -// CHECK: Op: 5 -// CHECK: result: 0 +// CHECK:Interface: 5 +// CHECK:Op: 5 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/optional/init_optional_with_non_value.carbon b/explorer/testdata/optional/init_optional_with_non_value.carbon index 469718cb8a92..ff8f330b1219 100644 --- a/explorer/testdata/optional/init_optional_with_non_value.carbon +++ b/explorer/testdata/optional/init_optional_with_non_value.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/optional/init_optional_with_value.carbon b/explorer/testdata/optional/init_optional_with_value.carbon index a55d5ecab75a..35725424ae5d 100644 --- a/explorer/testdata/optional/init_optional_with_value.carbon +++ b/explorer/testdata/optional/init_optional_with_value.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Hallo Welt -// CHECK: result: 0 +// CHECK:Hallo Welt +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/package/fail_missing.carbon b/explorer/testdata/package/fail_missing.carbon index a12921624381..5f0e0ff6bd96 100644 --- a/explorer/testdata/package/fail_missing.carbon +++ b/explorer/testdata/package/fail_missing.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/package/fail_missing.carbon:[[@LINE+1]]: syntax error, unexpected FN, expecting PACKAGE +// CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/package/fail_missing.carbon:[[@LINE+1]]: syntax error, unexpected FN, expecting PACKAGE fn Main() -> i32 { return 0; } diff --git a/explorer/testdata/package/with_library.carbon b/explorer/testdata/package/with_library.carbon index f24aebab425e..087ee7ea39ff 100644 --- a/explorer/testdata/package/with_library.carbon +++ b/explorer/testdata/package/with_library.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest library "Foo" api; diff --git a/explorer/testdata/pointer/aliasing.carbon b/explorer/testdata/pointer/aliasing.carbon index 9a86d02b0d1d..62139d8697d7 100644 --- a/explorer/testdata/pointer/aliasing.carbon +++ b/explorer/testdata/pointer/aliasing.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/pointer/basic.carbon b/explorer/testdata/pointer/basic.carbon index b970849f83f8..234d510ced62 100644 --- a/explorer/testdata/pointer/basic.carbon +++ b/explorer/testdata/pointer/basic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/pointer/fail_rvalue_addressof.carbon b/explorer/testdata/pointer/fail_rvalue_addressof.carbon index f7ad7fff062c..d6adf7eb8d37 100644 --- a/explorer/testdata/pointer/fail_rvalue_addressof.carbon +++ b/explorer/testdata/pointer/fail_rvalue_addressof.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32 = 5; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/pointer/fail_rvalue_addressof.carbon:[[@LINE+1]]: Argument to & should be an lvalue. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/pointer/fail_rvalue_addressof.carbon:[[@LINE+1]]: Argument to & should be an lvalue. var p: i32* = &5; return 0; } diff --git a/explorer/testdata/pointer/fail_use_after_free.carbon b/explorer/testdata/pointer/fail_use_after_free.carbon index 1ecffecd840d..1ab45be58ed5 100644 --- a/explorer/testdata/pointer/fail_use_after_free.carbon +++ b/explorer/testdata/pointer/fail_use_after_free.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,6 +11,6 @@ package ExplorerTest api; fn Main() -> i32 { var p: i32* = heap.New(5); heap.Delete(p); - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/pointer/fail_use_after_free.carbon:[[@LINE+1]]: undefined behavior: access to dead value 5 + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/pointer/fail_use_after_free.carbon:[[@LINE+1]]: undefined behavior: access to dead value 5 return *p; } diff --git a/explorer/testdata/pointer/heap_alloc_lifetime.carbon b/explorer/testdata/pointer/heap_alloc_lifetime.carbon index 07713afcf98a..c724d96f4e77 100644 --- a/explorer/testdata/pointer/heap_alloc_lifetime.carbon +++ b/explorer/testdata/pointer/heap_alloc_lifetime.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/pointer/intrinsic_new.carbon b/explorer/testdata/pointer/intrinsic_new.carbon index 7e160c26fe68..1887a7d6fe56 100644 --- a/explorer/testdata/pointer/intrinsic_new.carbon +++ b/explorer/testdata/pointer/intrinsic_new.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/pointer/new_and_delete.carbon b/explorer/testdata/pointer/new_and_delete.carbon index 29f578076660..14af052d813c 100644 --- a/explorer/testdata/pointer/new_and_delete.carbon +++ b/explorer/testdata/pointer/new_and_delete.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/pointer/struct_pointer.carbon b/explorer/testdata/pointer/struct_pointer.carbon index 743b3990b7f2..38dd6a04b0ff 100644 --- a/explorer/testdata/pointer/struct_pointer.carbon +++ b/explorer/testdata/pointer/struct_pointer.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/print/associated_constant.carbon b/explorer/testdata/print/associated_constant.carbon index 7d2836f61716..e125227a6314 100644 --- a/explorer/testdata/print/associated_constant.carbon +++ b/explorer/testdata/print/associated_constant.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: i32 -// CHECK: String -// CHECK: result: 0 +// CHECK:i32 +// CHECK:String +// CHECK:result: 0 package Testcase api; diff --git a/explorer/testdata/print/fail_no_args.carbon b/explorer/testdata/print/fail_no_args.carbon index 5a00041da720..a6619e10fb53 100644 --- a/explorer/testdata/print/fail_no_args.carbon +++ b/explorer/testdata/print/fail_no_args.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_no_args.carbon:[[@LINE+1]]: Print takes 1 or 2 arguments, received 0 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_no_args.carbon:[[@LINE+1]]: Print takes 1 or 2 arguments, received 0 Print(); return 0; } diff --git a/explorer/testdata/print/fail_not_str.carbon b/explorer/testdata/print/fail_not_str.carbon index 3a0a13b508bd..933667109f6e 100644 --- a/explorer/testdata/print/fail_not_str.carbon +++ b/explorer/testdata/print/fail_not_str.carbon @@ -2,18 +2,16 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_not_str.carbon:[[@LINE+3]]: type error in Print argument 0 - // CHECK: expected: String - // CHECK: actual: {.x: i32} + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_not_str.carbon:[[@LINE+3]]: type error in Print argument 0 + // CHECK:expected: String + // CHECK:actual: {.x: i32} Print({.x = 1}); return 0; } diff --git a/explorer/testdata/print/fail_too_many_args.carbon b/explorer/testdata/print/fail_too_many_args.carbon index 7d491b49787d..3b44282c33ce 100644 --- a/explorer/testdata/print/fail_too_many_args.carbon +++ b/explorer/testdata/print/fail_too_many_args.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_too_many_args.carbon:[[@LINE+1]]: Print takes 1 or 2 arguments, received 5 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_too_many_args.carbon:[[@LINE+1]]: Print takes 1 or 2 arguments, received 5 Print("too", "many", "args", "to", "print"); return 0; } diff --git a/explorer/testdata/print/fail_type.carbon b/explorer/testdata/print/fail_type.carbon index 4ebabf38501d..d81d27b6b412 100644 --- a/explorer/testdata/print/fail_type.carbon +++ b/explorer/testdata/print/fail_type.carbon @@ -2,18 +2,16 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_type.carbon:[[@LINE+3]]: type error in Print argument 1 - // CHECK: expected: i32 - // CHECK: actual: {.x: i32} + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/print/fail_type.carbon:[[@LINE+3]]: type error in Print argument 1 + // CHECK:expected: i32 + // CHECK:actual: {.x: i32} Print("{0}", {.x = 1}); return 0; } diff --git a/explorer/testdata/print/format_only.carbon b/explorer/testdata/print/format_only.carbon index e7a9cc347083..f8f4b52d6209 100644 --- a/explorer/testdata/print/format_only.carbon +++ b/explorer/testdata/print/format_only.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Hello world! -// CHECK: result: 0 +// CHECK:Hello world! +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/print/i32.carbon b/explorer/testdata/print/i32.carbon index d309cc9022eb..12cbcf9306a6 100644 --- a/explorer/testdata/print/i32.carbon +++ b/explorer/testdata/print/i32.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Printing 1 -// CHECK: result: 0 +// CHECK:Printing 1 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/random/random.carbon b/explorer/testdata/random/random.carbon index ee99e7c88651..00b612ec6fcc 100644 --- a/explorer/testdata/random/random.carbon +++ b/explorer/testdata/random/random.carbon @@ -2,13 +2,11 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: Nice! -// CHECK: result: 0 +// CHECK:Nice! +// CHECK:result: 0 package ExplorerTest api; fn test(para: i32)->bool{ diff --git a/explorer/testdata/return/convert_return_value.carbon b/explorer/testdata/return/convert_return_value.carbon index d18fc47720bc..639e1661a7d4 100644 --- a/explorer/testdata/return/convert_return_value.carbon +++ b/explorer/testdata/return/convert_return_value.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 42 +// CHECK:result: 42 package ExplorerTest api; diff --git a/explorer/testdata/return/explicit_empty.carbon b/explorer/testdata/return/explicit_empty.carbon index 075c9bf490f6..87ad498bc9b5 100644 --- a/explorer/testdata/return/explicit_empty.carbon +++ b/explorer/testdata/return/explicit_empty.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/return/fail_explicit_with_no_return.carbon b/explorer/testdata/return/fail_explicit_with_no_return.carbon index 4ab9407e50c9..c768289f03d7 100644 --- a/explorer/testdata/return/fail_explicit_with_no_return.carbon +++ b/explorer/testdata/return/fail_explicit_with_no_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn F() -> () { -// CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_explicit_with_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement +// CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_explicit_with_no_return.carbon:[[@LINE+1]]: control-flow reaches end of function that provides a `->` return type without reaching a return statement } fn Main() -> i32 { diff --git a/explorer/testdata/return/fail_explicit_with_plain_return.carbon b/explorer/testdata/return/fail_explicit_with_plain_return.carbon index d6beb5242d58..569130c437ce 100644 --- a/explorer/testdata/return/fail_explicit_with_plain_return.carbon +++ b/explorer/testdata/return/fail_explicit_with_plain_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn F() -> () { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_explicit_with_plain_return.carbon:[[@LINE+1]]: return; should provide a return value, to match the function's signature. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_explicit_with_plain_return.carbon:[[@LINE+1]]: return; should provide a return value, to match the function's signature. return; } diff --git a/explorer/testdata/return/fail_implicit_with_explicit_return.carbon b/explorer/testdata/return/fail_implicit_with_explicit_return.carbon index ef4fc3b3c35e..43078f13232b 100644 --- a/explorer/testdata/return/fail_implicit_with_explicit_return.carbon +++ b/explorer/testdata/return/fail_implicit_with_explicit_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn F() { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_implicit_with_explicit_return.carbon:[[@LINE+1]]: return (); should not provide a return value, to match the function's signature. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/return/fail_implicit_with_explicit_return.carbon:[[@LINE+1]]: return (); should not provide a return value, to match the function's signature. return (); } diff --git a/explorer/testdata/return/implicit_with_no_return.carbon b/explorer/testdata/return/implicit_with_no_return.carbon index d0445fbfb2c0..f9469bc270bb 100644 --- a/explorer/testdata/return/implicit_with_no_return.carbon +++ b/explorer/testdata/return/implicit_with_no_return.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/return/implicit_with_plain_return.carbon b/explorer/testdata/return/implicit_with_plain_return.carbon index ef4330c9b764..397c0f39814d 100644 --- a/explorer/testdata/return/implicit_with_plain_return.carbon +++ b/explorer/testdata/return/implicit_with_plain_return.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/fail_duplicate_return_var.carbon b/explorer/testdata/returned_var/fail_duplicate_return_var.carbon index 2ed9ef9b661e..7aa9da9c5932 100644 --- a/explorer/testdata/returned_var/fail_duplicate_return_var.carbon +++ b/explorer/testdata/returned_var/fail_duplicate_return_var.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn AddInt(a: i32, b: i32) -> i32 { returned var ret: i32 = a + b; if (a == b) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_duplicate_return_var.carbon:[[@LINE+1]]: Duplicate definition of returned var also found at {{.*}}/explorer/testdata/returned_var/fail_duplicate_return_var.carbon:14 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_duplicate_return_var.carbon:[[@LINE+1]]: Duplicate definition of returned var also found at {{.*}}/explorer/testdata/returned_var/fail_duplicate_return_var.carbon:12 returned var ret2: i32 = a + b; } return var; diff --git a/explorer/testdata/returned_var/fail_missing_declaration.carbon b/explorer/testdata/returned_var/fail_missing_declaration.carbon index 3b453b53a3c2..1b64d3b81c73 100644 --- a/explorer/testdata/returned_var/fail_missing_declaration.carbon +++ b/explorer/testdata/returned_var/fail_missing_declaration.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn AddInt(a: i32, b: i32) -> i32 { var ret: i32 = a + b; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_missing_declaration.carbon:[[@LINE+1]]: `return var` is not allowed without a returned var defined in scope. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_missing_declaration.carbon:[[@LINE+1]]: `return var` is not allowed without a returned var defined in scope. return var; } diff --git a/explorer/testdata/returned_var/fail_missing_return.carbon b/explorer/testdata/returned_var/fail_missing_return.carbon index 3546566c0403..e2b3c1c2b5f5 100644 --- a/explorer/testdata/returned_var/fail_missing_return.carbon +++ b/explorer/testdata/returned_var/fail_missing_return.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn AddInt(a: i32, b: i32) -> i32 { returned var ret: i32 = a + b; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_missing_return.carbon:[[@LINE+1]]: `return ` is not allowed with a returned var defined in scope: {{.*}}/explorer/testdata/returned_var/fail_missing_return.carbon:14 + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_missing_return.carbon:[[@LINE+1]]: `return ` is not allowed with a returned var defined in scope: {{.*}}/explorer/testdata/returned_var/fail_missing_return.carbon:12 return ret; } diff --git a/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon b/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon index 2761a053a151..ebe72f801ac0 100644 --- a/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon +++ b/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Foo() { returned var x: () = (); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon:[[@LINE+1]]: return var; should not provide a return value, to match the function's signature. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_mismatch_signature.carbon:[[@LINE+1]]: return var; should not provide a return value, to match the function's signature. return var; } diff --git a/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon b/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon index 3c132c29da88..7cc4ec015d46 100644 --- a/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon +++ b/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ fn Foo(a: i32, b: i32) -> auto { return var; } ret = a - b; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon:[[@LINE+1]]: Only one return is allowed in a function with an `auto` return type. + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_multi_auto.carbon:[[@LINE+1]]: Only one return is allowed in a function with an `auto` return type. return var; } diff --git a/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon b/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon index 8c95bd40d330..05f45632666d 100644 --- a/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon +++ b/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn AddInt(a: i32, b: i32) -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon:[[@LINE+1]]: type of returned var `bool` does not match return type `i32` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/returned_var/fail_returned_var_type_mismatch.carbon:[[@LINE+1]]: type of returned var `bool` does not match return type `i32` returned var ret: bool = true; return var; } diff --git a/explorer/testdata/returned_var/multiple_returned_var_control_flow.carbon b/explorer/testdata/returned_var/multiple_returned_var_control_flow.carbon index fa04b9ad2986..d0ee4c0becce 100644 --- a/explorer/testdata/returned_var/multiple_returned_var_control_flow.carbon +++ b/explorer/testdata/returned_var/multiple_returned_var_control_flow.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/normal_return_control_flow.carbon b/explorer/testdata/returned_var/normal_return_control_flow.carbon index bc6c26aad3d9..dcb85df3be6c 100644 --- a/explorer/testdata/returned_var/normal_return_control_flow.carbon +++ b/explorer/testdata/returned_var/normal_return_control_flow.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/returned_var_auto.carbon b/explorer/testdata/returned_var/returned_var_auto.carbon index 8234d2ba81ae..26e30ca6ac99 100644 --- a/explorer/testdata/returned_var/returned_var_auto.carbon +++ b/explorer/testdata/returned_var/returned_var_auto.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/returned_var_basic.carbon b/explorer/testdata/returned_var/returned_var_basic.carbon index 83843f87ac0d..f5277918f4b5 100644 --- a/explorer/testdata/returned_var/returned_var_basic.carbon +++ b/explorer/testdata/returned_var/returned_var_basic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/returned_var_name_lookup.carbon b/explorer/testdata/returned_var/returned_var_name_lookup.carbon index 5543562711e3..b512fd71c5a3 100644 --- a/explorer/testdata/returned_var/returned_var_name_lookup.carbon +++ b/explorer/testdata/returned_var/returned_var_name_lookup.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/returned_var/returned_var_omitted_expression.carbon b/explorer/testdata/returned_var/returned_var_omitted_expression.carbon index bc21a1e5ad25..2087e12e2378 100644 --- a/explorer/testdata/returned_var/returned_var_omitted_expression.carbon +++ b/explorer/testdata/returned_var/returned_var_omitted_expression.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/basic.carbon b/explorer/testdata/string/basic.carbon index bdfc92c0a503..2c598952df93 100644 --- a/explorer/testdata/string/basic.carbon +++ b/explorer/testdata/string/basic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/block.carbon b/explorer/testdata/string/block.carbon index 3896c18552b8..9755f11afffe 100644 --- a/explorer/testdata/string/block.carbon +++ b/explorer/testdata/string/block.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/block_escaped_triple_quotes.carbon b/explorer/testdata/string/block_escaped_triple_quotes.carbon index 9ea46d4fdf42..112cf460caae 100644 --- a/explorer/testdata/string/block_escaped_triple_quotes.carbon +++ b/explorer/testdata/string/block_escaped_triple_quotes.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/block_file_type_indicator.carbon b/explorer/testdata/string/block_file_type_indicator.carbon index 341addae6b3a..f30cfe03241f 100644 --- a/explorer/testdata/string/block_file_type_indicator.carbon +++ b/explorer/testdata/string/block_file_type_indicator.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon b/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon index cf4e2d98f2e0..2e3d4aea913d 100644 --- a/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon +++ b/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon:[[@LINE+1]]: Invalid block string: Should end with triple quotes: error: closing """ + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_block_quotes_not_on_own_line.carbon:[[@LINE+1]]: Invalid block string: Should end with triple quotes: error: closing """ var s: String = """ error: closing """ is not on its own line. """; diff --git a/explorer/testdata/string/fail_hex_lower.carbon b/explorer/testdata/string/fail_hex_lower.carbon index 77ce13270640..1bf1501eecd2 100644 --- a/explorer/testdata/string/fail_hex_lower.carbon +++ b/explorer/testdata/string/fail_hex_lower.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_hex_lower.carbon:[[@LINE+1]]: Invalid escaping in string: "str\xaa" + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_hex_lower.carbon:[[@LINE+1]]: Invalid escaping in string: "str\xaa" Print("str\xaa"); return 0; } diff --git a/explorer/testdata/string/fail_hex_truncated.carbon b/explorer/testdata/string/fail_hex_truncated.carbon index db532d87c583..196d09defec1 100644 --- a/explorer/testdata/string/fail_hex_truncated.carbon +++ b/explorer/testdata/string/fail_hex_truncated.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_hex_truncated.carbon:[[@LINE+1]]: Invalid escaping in string: "str\x" + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_hex_truncated.carbon:[[@LINE+1]]: Invalid escaping in string: "str\x" Print("str\x"); return 0; } diff --git a/explorer/testdata/string/fail_invalid_escape.carbon b/explorer/testdata/string/fail_invalid_escape.carbon index dad9bd663c8a..6326c1665e7c 100644 --- a/explorer/testdata/string/fail_invalid_escape.carbon +++ b/explorer/testdata/string/fail_invalid_escape.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_invalid_escape.carbon:[[@LINE+1]]: Invalid escaping in string: "str\e" + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_invalid_escape.carbon:[[@LINE+1]]: Invalid escaping in string: "str\e" Print("str\e"); return 0; } diff --git a/explorer/testdata/string/fail_newline.carbon b/explorer/testdata/string/fail_newline.carbon index 0c4657ad00e5..f5446d579944 100644 --- a/explorer/testdata/string/fail_newline.carbon +++ b/explorer/testdata/string/fail_newline.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_newline.carbon:[[@LINE+2]]: missing closing quote in single-line string: "new + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_newline.carbon:[[@LINE+2]]: missing closing quote in single-line string: "new // CHECK-EMPTY: Print("new line"); diff --git a/explorer/testdata/string/fail_octal.carbon b/explorer/testdata/string/fail_octal.carbon index 5ecb54f0df65..5500266a4377 100644 --- a/explorer/testdata/string/fail_octal.carbon +++ b/explorer/testdata/string/fail_octal.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_octal.carbon:[[@LINE+1]]: Invalid escaping in string: "str\01" + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_octal.carbon:[[@LINE+1]]: Invalid escaping in string: "str\01" Print("str\01"); return 0; } diff --git a/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon b/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon index 5ecd5defcc6f..f9c0fa7e36cd 100644 --- a/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon +++ b/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon:[[@LINE+1]]: Unexpected end of file + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_more_hash_tags_on_left.carbon:[[@LINE+1]]: Unexpected end of file var s: String = ##""" error: there are more #s on the left than the right. """#; diff --git a/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon b/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon index 8575aee07ca7..3300c40b5827 100644 --- a/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon +++ b/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon:[[@LINE+1]]: invalid character '\x23' in source file. + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_more_hash_tags_on_right.carbon:[[@LINE+1]]: invalid character '\x23' in source file. var s: String = #""" error: there are more #s on the right than the left. """##; diff --git a/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon b/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon index 245937c9fcd6..da754c84affc 100644 --- a/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon +++ b/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon:[[@LINE+1]]: Invalid block string: Should end with triple quotes: error: closing """ + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_quotes_not_on_own_line.carbon:[[@LINE+1]]: Invalid block string: Should end with triple quotes: error: closing """ var s: String = #""" error: closing """# is not on its own line. """#; diff --git a/explorer/testdata/string/fail_raw_block_single_line.carbon b/explorer/testdata/string/fail_raw_block_single_line.carbon index a858b8a5debe..4a0a427cd84f 100644 --- a/explorer/testdata/string/fail_raw_block_single_line.carbon +++ b/explorer/testdata/string/fail_raw_block_single_line.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn CompareStr(s: String) -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_single_line.carbon:[[@LINE+1]]: Invalid block string: Too few lines + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_block_single_line.carbon:[[@LINE+1]]: Invalid block string: Too few lines if (s == #"""raw string literal starting with """#) { return 0; } diff --git a/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon b/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon index 5013d8e6f5cc..3eb44ae759fd 100644 --- a/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon +++ b/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn CompareStr(s: String) -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon:[[@LINE+2]]: missing closing quote in single-line string: ##"str"#) { + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_more_hash_tags_on_left.carbon:[[@LINE+2]]: missing closing quote in single-line string: ##"str"#) { // CHECK-EMPTY: if (s == ##"str"#) { return 0; diff --git a/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon b/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon index 669e9dea6ea0..deca2950e19a 100644 --- a/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon +++ b/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn CompareStr(s: String) -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon:[[@LINE+1]]: invalid character '\x23' in source file. + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_raw_more_hash_tags_on_right.carbon:[[@LINE+1]]: invalid character '\x23' in source file. if (s == "str"#) { return 0; } diff --git a/explorer/testdata/string/fail_tab.carbon b/explorer/testdata/string/fail_tab.carbon index 9ec19fddb8da..bf71e9c5f629 100644 --- a/explorer/testdata/string/fail_tab.carbon +++ b/explorer/testdata/string/fail_tab.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_tab.carbon:[[@LINE+1]]: Invalid escaping in string: "new line" + // CHECK:SYNTAX ERROR: {{.*}}/explorer/testdata/string/fail_tab.carbon:[[@LINE+1]]: Invalid escaping in string: "new line" Print("new line"); return 0; } diff --git a/explorer/testdata/string/hex.carbon b/explorer/testdata/string/hex.carbon index 173edd6a8619..d94474b364b3 100644 --- a/explorer/testdata/string/hex.carbon +++ b/explorer/testdata/string/hex.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/newline.carbon b/explorer/testdata/string/newline.carbon index 3762a73072b7..27f0f6fec070 100644 --- a/explorer/testdata/string/newline.carbon +++ b/explorer/testdata/string/newline.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_basic.carbon b/explorer/testdata/string/raw_basic.carbon index 2749ada7719f..0c33d1bcce2a 100644 --- a/explorer/testdata/string/raw_basic.carbon +++ b/explorer/testdata/string/raw_basic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_basic_multi_hashtag.carbon b/explorer/testdata/string/raw_basic_multi_hashtag.carbon index 9cbe6c608d94..7a508c74c633 100644 --- a/explorer/testdata/string/raw_basic_multi_hashtag.carbon +++ b/explorer/testdata/string/raw_basic_multi_hashtag.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_block.carbon b/explorer/testdata/string/raw_block.carbon index fd19c490c437..4b12eb2460f0 100644 --- a/explorer/testdata/string/raw_block.carbon +++ b/explorer/testdata/string/raw_block.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_block_escaped_back_slash.carbon b/explorer/testdata/string/raw_block_escaped_back_slash.carbon index f22a71636f89..76eaf4ff268e 100644 --- a/explorer/testdata/string/raw_block_escaped_back_slash.carbon +++ b/explorer/testdata/string/raw_block_escaped_back_slash.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_block_escaped_triple_quotes.carbon b/explorer/testdata/string/raw_block_escaped_triple_quotes.carbon index 53d2306a3db1..9da98e9efccf 100644 --- a/explorer/testdata/string/raw_block_escaped_triple_quotes.carbon +++ b/explorer/testdata/string/raw_block_escaped_triple_quotes.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/raw_nesting.carbon b/explorer/testdata/string/raw_nesting.carbon index 054e4a622c15..eefec8b29007 100644 --- a/explorer/testdata/string/raw_nesting.carbon +++ b/explorer/testdata/string/raw_nesting.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/string/unicode.carbon b/explorer/testdata/string/unicode.carbon index d4cd296e3a4f..7c8c0113aac5 100644 --- a/explorer/testdata/string/unicode.carbon +++ b/explorer/testdata/string/unicode.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/assign.carbon b/explorer/testdata/struct/assign.carbon index 113c2746489f..00894ce9bd5b 100644 --- a/explorer/testdata/struct/assign.carbon +++ b/explorer/testdata/struct/assign.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/assign_member.carbon b/explorer/testdata/struct/assign_member.carbon index f0768b476a14..77c6dd6d4fc1 100644 --- a/explorer/testdata/struct/assign_member.carbon +++ b/explorer/testdata/struct/assign_member.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/empty.carbon b/explorer/testdata/struct/empty.carbon index 658c7eb8ef58..9254e06850d1 100644 --- a/explorer/testdata/struct/empty.carbon +++ b/explorer/testdata/struct/empty.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/ending_comma.carbon b/explorer/testdata/struct/ending_comma.carbon index 72b4830507ba..0a5e1544f5ca 100644 --- a/explorer/testdata/struct/ending_comma.carbon +++ b/explorer/testdata/struct/ending_comma.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/equality.carbon b/explorer/testdata/struct/equality.carbon index cfee857cdd81..5cbb5111b03d 100644 --- a/explorer/testdata/struct/equality.carbon +++ b/explorer/testdata/struct/equality.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: t1 == t2: 1 -// CHECK: t1 != t2: 0 -// CHECK: result: 0 +// CHECK:t1 == t2: 1 +// CHECK:t1 != t2: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/equality_false.carbon b/explorer/testdata/struct/equality_false.carbon index 7146e053295c..d6bc27076802 100644 --- a/explorer/testdata/struct/equality_false.carbon +++ b/explorer/testdata/struct/equality_false.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/fail_equality_type.carbon b/explorer/testdata/struct/fail_equality_type.carbon index 8dbbd0438ffd..aeec008cff7c 100644 --- a/explorer/testdata/struct/fail_equality_type.carbon +++ b/explorer/testdata/struct/fail_equality_type.carbon @@ -2,7 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 2>&1 | %{FileCheck} %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,7 +21,7 @@ external impl {.x: i32, .y: i32} as EqWith(Self) { fn Main() -> i32 { var t1: {.x: i32, .y: i32} = {.x = 5, .y = 2}; var t2: {.x: i32,} = {.x = 5,}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/struct/fail_equality_type.carbon:[[@LINE+1]]: {.x: i32, .y: i32} is not equality comparable with {.x: i32} (could not find implementation of interface EqWith(U = {.x: i32}) for {.x: i32, .y: i32}) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/struct/fail_equality_type.carbon:[[@LINE+1]]: {.x: i32, .y: i32} is not equality comparable with {.x: i32} (could not find implementation of interface EqWith(U = {.x: i32}) for {.x: i32, .y: i32}) if (t1 == t2) { return 1; } else { diff --git a/explorer/testdata/struct/fail_field_access_mismatch.carbon b/explorer/testdata/struct/fail_field_access_mismatch.carbon index 67eba881dfad..1c6fecf57d8a 100644 --- a/explorer/testdata/struct/fail_field_access_mismatch.carbon +++ b/explorer/testdata/struct/fail_field_access_mismatch.carbon @@ -2,15 +2,13 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/struct/fail_field_access_mismatch.carbon:[[@LINE+1]]: struct {.x: i32, .y: i32} does not have a field named z + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/struct/fail_field_access_mismatch.carbon:[[@LINE+1]]: struct {.x: i32, .y: i32} does not have a field named z return {.x = 1, .y = 2}.z - 1; } diff --git a/explorer/testdata/struct/name_order.carbon b/explorer/testdata/struct/name_order.carbon index 2535bcaa13d7..420903be6422 100644 --- a/explorer/testdata/struct/name_order.carbon +++ b/explorer/testdata/struct/name_order.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/temp.carbon b/explorer/testdata/struct/temp.carbon index c12cfdcd02c5..773d8162a237 100644 --- a/explorer/testdata/struct/temp.carbon +++ b/explorer/testdata/struct/temp.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/struct/var.carbon b/explorer/testdata/struct/var.carbon index 49b66a53f819..35fd41a84edb 100644 --- a/explorer/testdata/struct/var.carbon +++ b/explorer/testdata/struct/var.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/ending_comma.carbon b/explorer/testdata/tuple/ending_comma.carbon index 5182b347212c..d560804befc2 100644 --- a/explorer/testdata/tuple/ending_comma.carbon +++ b/explorer/testdata/tuple/ending_comma.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/equality.carbon b/explorer/testdata/tuple/equality.carbon index 5d6da7823507..a9b06b23708d 100644 --- a/explorer/testdata/tuple/equality.carbon +++ b/explorer/testdata/tuple/equality.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/equality_false.carbon b/explorer/testdata/tuple/equality_false.carbon index f441d27458b2..ac7f577d1b19 100644 --- a/explorer/testdata/tuple/equality_false.carbon +++ b/explorer/testdata/tuple/equality_false.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/fail_equality_type.carbon b/explorer/testdata/tuple/fail_equality_type.carbon index ca36dd98a74f..f92c75d5bc73 100644 --- a/explorer/testdata/tuple/fail_equality_type.carbon +++ b/explorer/testdata/tuple/fail_equality_type.carbon @@ -2,7 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 2>&1 | %{FileCheck} %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -10,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var t1: (i32, i32) = (5, 2); var t2: (i32,) = (5,); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_equality_type.carbon:[[@LINE+1]]: (i32, i32) is not equality comparable with (i32) (could not find implementation of interface EqWith(U = (i32)) for (i32, i32)) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_equality_type.carbon:[[@LINE+1]]: (i32, i32) is not equality comparable with (i32) (could not find implementation of interface EqWith(U = (i32)) for (i32, i32)) if (t1 == t2) { return 1; } else { diff --git a/explorer/testdata/tuple/fail_index.carbon b/explorer/testdata/tuple/fail_index.carbon index fa0ef77faf77..d9267d25c667 100644 --- a/explorer/testdata/tuple/fail_index.carbon +++ b/explorer/testdata/tuple/fail_index.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: auto = (0, 1); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_index.carbon:[[@LINE+1]]: index 2 is out of range for type (i32, i32) + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_index.carbon:[[@LINE+1]]: index 2 is out of range for type (i32, i32) return x[2]; } diff --git a/explorer/testdata/tuple/fail_index_var.carbon b/explorer/testdata/tuple/fail_index_var.carbon index 31c86765d248..fcf97a325ff7 100644 --- a/explorer/testdata/tuple/fail_index_var.carbon +++ b/explorer/testdata/tuple/fail_index_var.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,6 +11,6 @@ package ExplorerTest api; fn Main() -> i32 { var x: auto = (0, 1); var index: i32 = 0; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_index_var.carbon:[[@LINE+1]]: could not find `index: i32` + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_index_var.carbon:[[@LINE+1]]: could not find `index: i32` return x[index]; } diff --git a/explorer/testdata/tuple/fail_to_array.carbon b/explorer/testdata/tuple/fail_to_array.carbon index 97c055b69b7b..436f6d6151c6 100644 --- a/explorer/testdata/tuple/fail_to_array.carbon +++ b/explorer/testdata/tuple/fail_to_array.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var t: auto = (1, 2); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_to_array.carbon:[[@LINE+1]]: type error in name binding: '(i32, i32)' is not implicitly convertible to '[i32; 3]' + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/tuple/fail_to_array.carbon:[[@LINE+1]]: type error in name binding: '(i32, i32)' is not implicitly convertible to '[i32; 3]' var a: [i32; 3] = t; } diff --git a/explorer/testdata/tuple/index.carbon b/explorer/testdata/tuple/index.carbon index c0b9b7e3017e..ec0571ce6c2c 100644 --- a/explorer/testdata/tuple/index.carbon +++ b/explorer/testdata/tuple/index.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/match.carbon b/explorer/testdata/tuple/match.carbon index 5744c60a72d0..e9d9ad446661 100644 --- a/explorer/testdata/tuple/match.carbon +++ b/explorer/testdata/tuple/match.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/match_nested.carbon b/explorer/testdata/tuple/match_nested.carbon index d557a0b672ef..04892b4c5aed 100644 --- a/explorer/testdata/tuple/match_nested.carbon +++ b/explorer/testdata/tuple/match_nested.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/no_ending_comma.carbon b/explorer/testdata/tuple/no_ending_comma.carbon index 0058f95ef6fc..c8c66cfc1f25 100644 --- a/explorer/testdata/tuple/no_ending_comma.carbon +++ b/explorer/testdata/tuple/no_ending_comma.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/tuple/to_array.carbon b/explorer/testdata/tuple/to_array.carbon index 250b3ec31bca..d7c95fa7ac76 100644 --- a/explorer/testdata/tuple/to_array.carbon +++ b/explorer/testdata/tuple/to_array.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 3 +// CHECK:result: 3 package ExplorerTest api; diff --git a/explorer/testdata/unformed/control_flow_defer_to_dynamic.carbon b/explorer/testdata/unformed/control_flow_defer_to_dynamic.carbon index 8c27b6f79969..a02d5b40933f 100644 --- a/explorer/testdata/unformed/control_flow_defer_to_dynamic.carbon +++ b/explorer/testdata/unformed/control_flow_defer_to_dynamic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/unformed/dynamic/fail_global.carbon b/explorer/testdata/unformed/dynamic/fail_global.carbon index 49e6eed20958..1918c7ab3165 100644 --- a/explorer/testdata/unformed/dynamic/fail_global.carbon +++ b/explorer/testdata/unformed/dynamic/fail_global.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,6 +11,6 @@ package ExplorerTest api; var x: i32; fn Main() -> i32 { - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_global.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_global.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> return x; } diff --git a/explorer/testdata/unformed/dynamic/fail_param.carbon b/explorer/testdata/unformed/dynamic/fail_param.carbon index 865e921dcb93..8f37ffd5e05c 100644 --- a/explorer/testdata/unformed/dynamic/fail_param.carbon +++ b/explorer/testdata/unformed/dynamic/fail_param.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -20,6 +18,6 @@ fn Main() -> i32 { x = 0; } // Static analysis thinks `x` may be formed, defer the check to run-time. - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_param.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_param.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> return AddInt(x, 2); } diff --git a/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon b/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon index f72cc8605199..f9220d702ab8 100644 --- a/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon +++ b/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,6 +15,6 @@ fn Main() -> i32 { y = 0; } // Static analysis thinks `y` may be formed, defer the check to run-time. - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_pattern_declare.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> return y; } diff --git a/explorer/testdata/unformed/dynamic/fail_return.carbon b/explorer/testdata/unformed/dynamic/fail_return.carbon index 499d47c6eeaa..c91452716973 100644 --- a/explorer/testdata/unformed/dynamic/fail_return.carbon +++ b/explorer/testdata/unformed/dynamic/fail_return.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,6 +14,6 @@ fn Main() -> i32 { x = 0; } // Static analysis thinks `x` may be formed, defer the check to run-time. - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_return.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_return.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> return x; } diff --git a/explorer/testdata/unformed/dynamic/fail_returned_var.carbon b/explorer/testdata/unformed/dynamic/fail_returned_var.carbon index e83995cc2ca2..a1962aa3b542 100644 --- a/explorer/testdata/unformed/dynamic/fail_returned_var.carbon +++ b/explorer/testdata/unformed/dynamic/fail_returned_var.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,6 +14,6 @@ fn Main() -> i32 { x = 0; } // Static analysis thinks `x` may be formed, defer the check to run-time. - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_returned_var.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_returned_var.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> return var; } diff --git a/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon b/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon index 39761c33c4e3..8c53f694b4b8 100644 --- a/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon +++ b/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ fn Main() -> i32 { x = 0; } // Static analysis thinks `x` may be formed, defer the check to run-time. - // CHECK: RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> + // CHECK:RUNTIME ERROR: {{.*}}/explorer/testdata/unformed/dynamic/fail_rhs_assign.carbon:[[@LINE+1]]: undefined behavior: access to uninitialized value Uninit> y = x; return y; } diff --git a/explorer/testdata/unformed/global_assign_before_use.carbon b/explorer/testdata/unformed/global_assign_before_use.carbon index 561e842ba908..0626bd56368b 100644 --- a/explorer/testdata/unformed/global_assign_before_use.carbon +++ b/explorer/testdata/unformed/global_assign_before_use.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/global_escape.carbon b/explorer/testdata/unformed/global_escape.carbon index 8acbb6ed9e27..1175ec1778f8 100644 --- a/explorer/testdata/unformed/global_escape.carbon +++ b/explorer/testdata/unformed/global_escape.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 42 +// CHECK:result: 42 package ExplorerTest api; diff --git a/explorer/testdata/unformed/global_unformed_without_use.carbon b/explorer/testdata/unformed/global_unformed_without_use.carbon index 8d334acdfea5..cdd0cea1f1fb 100644 --- a/explorer/testdata/unformed/global_unformed_without_use.carbon +++ b/explorer/testdata/unformed/global_unformed_without_use.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/local_assign_before_use.carbon b/explorer/testdata/unformed/local_assign_before_use.carbon index f5e9d9592e55..39100eb60d17 100644 --- a/explorer/testdata/unformed/local_assign_before_use.carbon +++ b/explorer/testdata/unformed/local_assign_before_use.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/local_escape.carbon b/explorer/testdata/unformed/local_escape.carbon index 699d54a547ef..29ea8ba0580b 100644 --- a/explorer/testdata/unformed/local_escape.carbon +++ b/explorer/testdata/unformed/local_escape.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 42 +// CHECK:result: 42 package ExplorerTest api; diff --git a/explorer/testdata/unformed/local_unformed_without_use.carbon b/explorer/testdata/unformed/local_unformed_without_use.carbon index a4f69675a5ef..0c96fdafcc88 100644 --- a/explorer/testdata/unformed/local_unformed_without_use.carbon +++ b/explorer/testdata/unformed/local_unformed_without_use.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/pattern_declare.carbon b/explorer/testdata/unformed/pattern_declare.carbon index 19311799c736..496ec6d8e520 100644 --- a/explorer/testdata/unformed/pattern_declare.carbon +++ b/explorer/testdata/unformed/pattern_declare.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/returned_var_assign_before_use.carbon b/explorer/testdata/unformed/returned_var_assign_before_use.carbon index 585bed71ff8e..83f4677b2beb 100644 --- a/explorer/testdata/unformed/returned_var_assign_before_use.carbon +++ b/explorer/testdata/unformed/returned_var_assign_before_use.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 1 +// CHECK:result: 1 package ExplorerTest api; diff --git a/explorer/testdata/unformed/static/fail_field_value.carbon b/explorer/testdata/unformed/static/fail_field_value.carbon index e30c47ca17f0..7d8df13dae40 100644 --- a/explorer/testdata/unformed/static/fail_field_value.carbon +++ b/explorer/testdata/unformed/static/fail_field_value.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_field_value.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_field_value.carbon:[[@LINE+1]]: use of uninitialized variable x var p: auto = {.x = x,}; return 0; } diff --git a/explorer/testdata/unformed/static/fail_if_cond.carbon b/explorer/testdata/unformed/static/fail_if_cond.carbon index 41a87960a56e..12d1193b0a30 100644 --- a/explorer/testdata/unformed/static/fail_if_cond.carbon +++ b/explorer/testdata/unformed/static/fail_if_cond.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_cond.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_cond.carbon:[[@LINE+1]]: use of uninitialized variable x if (x == 0) { return 0; } diff --git a/explorer/testdata/unformed/static/fail_if_else.carbon b/explorer/testdata/unformed/static/fail_if_else.carbon index 5374c92ff372..04a4cd4e1f95 100644 --- a/explorer/testdata/unformed/static/fail_if_else.carbon +++ b/explorer/testdata/unformed/static/fail_if_else.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -17,7 +15,7 @@ fn Main() -> i32 { if (Foo() == 0) { return 0; } else { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_else.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_else.carbon:[[@LINE+1]]: use of uninitialized variable x return x; } } diff --git a/explorer/testdata/unformed/static/fail_if_then.carbon b/explorer/testdata/unformed/static/fail_if_then.carbon index 063494008c1b..af9258da65fe 100644 --- a/explorer/testdata/unformed/static/fail_if_then.carbon +++ b/explorer/testdata/unformed/static/fail_if_then.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ fn Foo() -> i32; fn Main() -> i32 { var x: i32; if (Foo() == 0) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_then.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_if_then.carbon:[[@LINE+1]]: use of uninitialized variable x return x; } return 1; diff --git a/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon b/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon index 214919bdf134..81d9477ff4b4 100644 --- a/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon +++ b/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,6 +11,6 @@ package ExplorerTest api; fn Main() -> i32 { var (x: i32, y: i32); x = 1; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon:[[@LINE+1]]: use of uninitialized variable y + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_local_pattern_declare.carbon:[[@LINE+1]]: use of uninitialized variable y return y; } diff --git a/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon b/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon index 099d581f1474..c7ab8e006cab 100644 --- a/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon +++ b/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -13,7 +11,7 @@ package ExplorerTest api; fn Main() -> i32 { var x: i32; var y: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_local_rhs_assign.carbon:[[@LINE+1]]: use of uninitialized variable x y = x; return y; } diff --git a/explorer/testdata/unformed/static/fail_match_clause.carbon b/explorer/testdata/unformed/static/fail_match_clause.carbon index 5813f605f111..213b19a62e4c 100644 --- a/explorer/testdata/unformed/static/fail_match_clause.carbon +++ b/explorer/testdata/unformed/static/fail_match_clause.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -19,7 +17,7 @@ fn Main() -> i32 { return 2; } case 1 => { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_match_clause.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_match_clause.carbon:[[@LINE+1]]: use of uninitialized variable x return x; } default => { diff --git a/explorer/testdata/unformed/static/fail_match_expression.carbon b/explorer/testdata/unformed/static/fail_match_expression.carbon index dd449ad548b5..6fd85fb39d3f 100644 --- a/explorer/testdata/unformed/static/fail_match_expression.carbon +++ b/explorer/testdata/unformed/static/fail_match_expression.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x : i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_match_expression.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_match_expression.carbon:[[@LINE+1]]: use of uninitialized variable x match (x) { case 0 => { return 1; diff --git a/explorer/testdata/unformed/static/fail_param.carbon b/explorer/testdata/unformed/static/fail_param.carbon index eac6e7dfac96..4eabadec7ab7 100644 --- a/explorer/testdata/unformed/static/fail_param.carbon +++ b/explorer/testdata/unformed/static/fail_param.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -16,6 +14,6 @@ fn AddInt(a: i32, b: i32) -> auto { fn Main() -> i32 { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_param.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_param.carbon:[[@LINE+1]]: use of uninitialized variable x return AddInt(x, 2); } diff --git a/explorer/testdata/unformed/static/fail_return.carbon b/explorer/testdata/unformed/static/fail_return.carbon index 3a2f5a0b03ef..b872e2257dfb 100644 --- a/explorer/testdata/unformed/static/fail_return.carbon +++ b/explorer/testdata/unformed/static/fail_return.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_return.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_return.carbon:[[@LINE+1]]: use of uninitialized variable x return x; } diff --git a/explorer/testdata/unformed/static/fail_returned_var.carbon b/explorer/testdata/unformed/static/fail_returned_var.carbon index 6d42d83e8831..dae83edcca1f 100644 --- a/explorer/testdata/unformed/static/fail_returned_var.carbon +++ b/explorer/testdata/unformed/static/fail_returned_var.carbon @@ -2,16 +2,14 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { returned var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_returned_var.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_returned_var.carbon:[[@LINE+1]]: use of uninitialized variable x return var; } diff --git a/explorer/testdata/unformed/static/fail_rhs_def.carbon b/explorer/testdata/unformed/static/fail_rhs_def.carbon index 274c2943249e..463009fac440 100644 --- a/explorer/testdata/unformed/static/fail_rhs_def.carbon +++ b/explorer/testdata/unformed/static/fail_rhs_def.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var x: i32; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_rhs_def.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_rhs_def.carbon:[[@LINE+1]]: use of uninitialized variable x var y: i32 = x; return x; } diff --git a/explorer/testdata/unformed/static/fail_struct_member_access.carbon b/explorer/testdata/unformed/static/fail_struct_member_access.carbon index 0d8b42f1be1e..6587c9ad65af 100644 --- a/explorer/testdata/unformed/static/fail_struct_member_access.carbon +++ b/explorer/testdata/unformed/static/fail_struct_member_access.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var p: {.x: i32, .y: i32}; - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_struct_member_access.carbon:[[@LINE+1]]: use of uninitialized variable p + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_struct_member_access.carbon:[[@LINE+1]]: use of uninitialized variable p p.x = p.y; return 0; } diff --git a/explorer/testdata/unformed/static/fail_while_body.carbon b/explorer/testdata/unformed/static/fail_while_body.carbon index 40025f99e85c..d66d70986676 100644 --- a/explorer/testdata/unformed/static/fail_while_body.carbon +++ b/explorer/testdata/unformed/static/fail_while_body.carbon @@ -2,10 +2,8 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; @@ -15,7 +13,7 @@ fn Foo() -> i32; fn Main() -> i32 { var (x: i32, y: i32); while (Foo() == 0) { - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_while_body.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_while_body.carbon:[[@LINE+1]]: use of uninitialized variable x y = x; } return 1; diff --git a/explorer/testdata/unformed/static/fail_while_cond.carbon b/explorer/testdata/unformed/static/fail_while_cond.carbon index f34c3f0dd1fd..5711ef2651bc 100644 --- a/explorer/testdata/unformed/static/fail_while_cond.carbon +++ b/explorer/testdata/unformed/static/fail_while_cond.carbon @@ -2,17 +2,15 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{not} %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{not} %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{not} %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s package ExplorerTest api; fn Main() -> i32 { var (x: i32, y: i32); - // CHECK: COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_while_cond.carbon:[[@LINE+1]]: use of uninitialized variable x + // CHECK:COMPILATION ERROR: {{.*}}/explorer/testdata/unformed/static/fail_while_cond.carbon:[[@LINE+1]]: use of uninitialized variable x while (x == 0) { y = 1; } diff --git a/explorer/testdata/while/basic.carbon b/explorer/testdata/while/basic.carbon index d3166fa2b8c2..12c89e4dbaba 100644 --- a/explorer/testdata/while/basic.carbon +++ b/explorer/testdata/while/basic.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/while/break.carbon b/explorer/testdata/while/break.carbon index 285f613ab7dd..402fc8ebd522 100644 --- a/explorer/testdata/while/break.carbon +++ b/explorer/testdata/while/break.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/while/continue.carbon b/explorer/testdata/while/continue.carbon index d92a066c884b..1b57e7060db0 100644 --- a/explorer/testdata/while/continue.carbon +++ b/explorer/testdata/while/continue.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/testdata/while/convert_condition.carbon b/explorer/testdata/while/convert_condition.carbon index 30218d99dbc9..9ee13ae871b2 100644 --- a/explorer/testdata/while/convert_condition.carbon +++ b/explorer/testdata/while/convert_condition.carbon @@ -2,12 +2,10 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{explorer} %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s -// RUN: %{explorer} --parser_debug --trace_file=- %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes %s +// RUN: %{explorer} %s 2>&1 | %{FileCheck-strict} %s +// RUN: %{explorer-trace} %s 2>&1 | %{FileCheck-allow-unmatched} %s // AUTOUPDATE: %{explorer} %s -// CHECK: result: 0 +// CHECK:result: 0 package ExplorerTest api; diff --git a/explorer/update_checks.py b/explorer/update_checks.py index 26dcb0476d8c..7100b1e6ba3d 100755 --- a/explorer/update_checks.py +++ b/explorer/update_checks.py @@ -93,7 +93,7 @@ class SimpleCheckLine(CheckLine): def format(self, **kwargs: Any) -> str: if self.expected: - return f"{self.indent}// CHECK: {self.expected}\n" + return f"{self.indent}// CHECK:{self.expected}\n" else: return f"{self.indent}// CHECK-EMPTY:\n" @@ -118,7 +118,7 @@ class CheckLineWithLineNumber(CheckLine): delta = line_number_remap[self.line_number] - output_line_number # We use `:+d` here to produce `LINE-n` or `LINE+n` as appropriate. return ( - f"{self.indent}// CHECK: {self.before}[[@LINE{delta:+d}]]" + f"{self.indent}// CHECK:{self.before}[[@LINE{delta:+d}]]" + f"{self.after}\n" ) diff --git a/toolchain/driver/testdata/carbon_test.carbon b/toolchain/driver/testdata/carbon_test.carbon index 415263c2b5c6..1ab7e1cc7116 100644 --- a/toolchain/driver/testdata/carbon_test.carbon +++ b/toolchain/driver/testdata/carbon_test.carbon @@ -2,22 +2,20 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump tokens %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s +// RUN: %{carbon} dump tokens %s 2>&1 | %{FileCheck-strict} %s +// CHECK:token: { index: 0, kind: 'Fn', line: {{ *}}[[@LINE+7]], column: 1, indent: 1, spelling: 'fn', has_trailing_space: true } +// CHECK:token: { index: 1, kind: 'Identifier', line: {{ *}}[[@LINE+6]], column: 4, indent: 1, spelling: 'run', identifier: 0 } +// CHECK:token: { index: 2, kind: 'OpenParen', line: {{ *}}[[@LINE+5]], column: 7, indent: 1, spelling: '(', closing_token: 5 } +// CHECK:token: { index: 3, kind: 'Identifier', line: {{ *}}[[@LINE+4]], column: 8, indent: 1, spelling: 'String', identifier: 1, has_trailing_space: true } +// CHECK:token: { index: 4, kind: 'Identifier', line: {{ *}}[[@LINE+3]], column: 15, indent: 1, spelling: 'program', identifier: 2 } +// CHECK:token: { index: 5, kind: 'CloseParen', line: {{ *}}[[@LINE+2]], column: 22, indent: 1, spelling: ')', opening_token: 2, has_trailing_space: true } +// CHECK:token: { index: 6, kind: 'OpenCurlyBrace', line: {{ *}}[[@LINE+1]], column: 24, indent: 1, spelling: '{', closing_token: 10, has_trailing_space: true } fn run(String program) { + // CHECK:token: { index: 7, kind: 'Return', line: {{ *}}[[@LINE+3]], column: 3, indent: 3, spelling: 'return', has_trailing_space: true } + // CHECK:token: { index: 8, kind: 'Identifier', line: {{ *}}[[@LINE+2]], column: 10, indent: 3, spelling: 'True', identifier: 3 } + // CHECK:token: { index: 9, kind: 'Semi', line: {{ *}}[[@LINE+1]], column: 14, indent: 3, spelling: ';', has_trailing_space: true } return True; +// CHECK:token: { index: 10, kind: 'CloseCurlyBrace', line: {{ *}}[[@LINE+1]], column: 1, indent: 1, spelling: '}', opening_token: 6, has_trailing_space: true } } - -// CHECK: token: { index: 0, kind: 'Fn', line: 8, column: 1, indent: 1, spelling: 'fn', has_trailing_space: true } -// CHECK: token: { index: 1, kind: 'Identifier', line: 8, column: 4, indent: 1, spelling: 'run', identifier: 0 } -// CHECK: token: { index: 2, kind: 'OpenParen', line: 8, column: 7, indent: 1, spelling: '(', closing_token: 5 } -// CHECK: token: { index: 3, kind: 'Identifier', line: 8, column: 8, indent: 1, spelling: 'String', identifier: 1, has_trailing_space: true } -// CHECK: token: { index: 4, kind: 'Identifier', line: 8, column: 15, indent: 1, spelling: 'program', identifier: 2 } -// CHECK: token: { index: 5, kind: 'CloseParen', line: 8, column: 22, indent: 1, spelling: ')', opening_token: 2, has_trailing_space: true } -// CHECK: token: { index: 6, kind: 'OpenCurlyBrace', line: 8, column: 24, indent: 1, spelling: '{', closing_token: 10, has_trailing_space: true } -// CHECK: token: { index: 7, kind: 'Return', line: 9, column: 3, indent: 3, spelling: 'return', has_trailing_space: true } -// CHECK: token: { index: 8, kind: 'Identifier', line: 9, column: 10, indent: 3, spelling: 'True', identifier: 3 } -// CHECK: token: { index: 9, kind: 'Semi', line: 9, column: 14, indent: 3, spelling: ';', has_trailing_space: true } -// CHECK: token: { index: 10, kind: 'CloseCurlyBrace', line: 10, column: 1, indent: 1, spelling: '}', opening_token: 6, has_trailing_space: true } -// CHECK: token: { index: 11, kind: 'EndOfFile', line: 23, column: 104, indent: 1, spelling: '' } +// CHECK:token: { index: 11, kind: 'EndOfFile', line: {{ *}}[[@LINE]], column: {{[0-9]+}}, indent: 1, spelling: '' } diff --git a/toolchain/driver/testdata/errors_sorted_test.carbon b/toolchain/driver/testdata/errors_sorted_test.carbon index 11360c0dd6c5..cf76cc2a4181 100644 --- a/toolchain/driver/testdata/errors_sorted_test.carbon +++ b/toolchain/driver/testdata/errors_sorted_test.carbon @@ -2,14 +2,12 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{not} %{carbon} dump tokens %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s +// RUN: %{not} %{carbon} dump tokens %s 2>&1 | %{FileCheck-strict} %s +// CHECK:{{.*}}/errors_sorted_test.carbon:[[@LINE+1]]:24: Closing symbol does not match most recent opening symbol. fn run(String program) { return True; +// CHECK:{{.*}}/errors_sorted_test.carbon:[[@LINE+1]]:10: Invalid digit 'a' in decimal numeric literal. var x = 3a; - -// CHECK: {{.*}}/errors_sorted_test.carbon:8:24: Closing symbol does not match most recent opening symbol. -// CHECK: {{.*}}/errors_sorted_test.carbon:11:10: Invalid digit 'a' in decimal numeric literal. -// CHECK-COUNT-17: token: {{.*}} +// CHECK-COUNT-17:token: {{.*}} diff --git a/toolchain/driver/testdata/errors_streamed_test.carbon b/toolchain/driver/testdata/errors_streamed_test.carbon index 340c819d8a17..040ad8cf24f4 100644 --- a/toolchain/driver/testdata/errors_streamed_test.carbon +++ b/toolchain/driver/testdata/errors_streamed_test.carbon @@ -3,13 +3,13 @@ // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // // RUN: %{not} %{carbon} --print-errors=streamed dump tokens %s 2>&1 | \ -// RUN: %{FileCheck} --match-full-lines --allow-unused-prefixes=false %s +// RUN: %{FileCheck-strict} %s fn run(String program) { return True; var x = 3a; -// CHECK: {{.*}}/errors_streamed_test.carbon:11:10: Invalid digit 'a' in decimal numeric literal. -// CHECK: {{.*}}/errors_streamed_test.carbon:8:24: Closing symbol does not match most recent opening symbol. -// CHECK-COUNT-17: token: {{.*}} +// CHECK:{{.*}}/errors_streamed_test.carbon:[[@LINE-2]]:10: Invalid digit 'a' in decimal numeric literal. +// CHECK:{{.*}}/errors_streamed_test.carbon:[[@LINE-6]]:24: Closing symbol does not match most recent opening symbol. +// CHECK-COUNT-17:token: {{.*}} diff --git a/toolchain/driver/testdata/lit.cfg.py b/toolchain/driver/testdata/lit.cfg.py deleted file mode 100644 index e975c265d658..000000000000 --- a/toolchain/driver/testdata/lit.cfg.py +++ /dev/null @@ -1,35 +0,0 @@ -__copyright__ = """ -Part of the Carbon Language project, under the Apache License v2.0 with LLVM -Exceptions. See /LICENSE for license information. -SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -""" - -import lit.formats -import os - - -# This is a provided variable, ignore the undefined name warning. -config = config # noqa: F821 - - -def fullpath(relative_path): - return os.path.join(os.environ["TEST_SRCDIR"], relative_path) - - -config.name = "lit" -config.suffixes = [".carbon"] -config.test_format = lit.formats.ShTest() - -config.substitutions.append( - ( - "%{carbon}", - fullpath("carbon/toolchain/driver/carbon"), - ) -) -config.substitutions.append(("%{not}", fullpath("llvm-project/llvm/not"))) -config.substitutions.append( - ( - "%{FileCheck}", - fullpath("llvm-project/llvm/FileCheck --dump-input-filter=all"), - ) -) diff --git a/toolchain/driver/testdata/lit.cfg.py b/toolchain/driver/testdata/lit.cfg.py new file mode 120000 index 000000000000..c323f8a5e8da --- /dev/null +++ b/toolchain/driver/testdata/lit.cfg.py @@ -0,0 +1 @@ +../../../bazel/testing/lit.cfg.py \ No newline at end of file diff --git a/toolchain/semantics/testdata/empty.carbon b/toolchain/semantics/testdata/empty.carbon index 5aac04177ef9..3e30c0bf745c 100644 --- a/toolchain/semantics/testdata/empty.carbon +++ b/toolchain/semantics/testdata/empty.carbon @@ -2,6 +2,6 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK:} diff --git a/toolchain/semantics/testdata/function/basic.carbon b/toolchain/semantics/testdata/function/basic.carbon index 982a692ac806..317975b3919d 100644 --- a/toolchain/semantics/testdata/function/basic.carbon +++ b/toolchain/semantics/testdata/function/basic.carbon @@ -2,7 +2,7 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK: Function( // CHECK: %[[ID0:[0-9]+]], diff --git a/toolchain/semantics/testdata/function/order.carbon b/toolchain/semantics/testdata/function/order.carbon index fc2124cbd2b4..e28cde54b917 100644 --- a/toolchain/semantics/testdata/function/order.carbon +++ b/toolchain/semantics/testdata/function/order.carbon @@ -2,7 +2,7 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK: Function( // CHECK: %[[ID0:[0-9]+]], diff --git a/toolchain/semantics/testdata/lit.cfg.py b/toolchain/semantics/testdata/lit.cfg.py deleted file mode 100644 index 91efb7e33f98..000000000000 --- a/toolchain/semantics/testdata/lit.cfg.py +++ /dev/null @@ -1,43 +0,0 @@ -__copyright__ = """ -Part of the Carbon Language project, under the Apache License v2.0 with LLVM -Exceptions. See /LICENSE for license information. -SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -""" - -import lit.formats -import os - - -# This is a provided variable, ignore the undefined name warning. -config = config # noqa: F821 - - -def fullpath(relative_path): - return os.path.join(os.environ["TEST_SRCDIR"], relative_path) - - -config.name = "lit" -config.suffixes = [".carbon"] -config.test_format = lit.formats.ShTest() - -config.substitutions.append( - ( - "%{carbon}", - fullpath("carbon/toolchain/driver/carbon"), - ) -) -config.substitutions.append(("%{not}", fullpath("llvm-project/llvm/not"))) -config.substitutions.append( - ( - "%{FileCheckStrict}", - " ".join( - [ - fullpath("llvm-project/llvm/FileCheck"), - "--dump-input-filter=all", - "--implicit-check-not={{.}}", - "--match-full-lines", - "--strict-whitespace", - ] - ), - ) -) diff --git a/toolchain/semantics/testdata/lit.cfg.py b/toolchain/semantics/testdata/lit.cfg.py new file mode 120000 index 000000000000..c323f8a5e8da --- /dev/null +++ b/toolchain/semantics/testdata/lit.cfg.py @@ -0,0 +1 @@ +../../../bazel/testing/lit.cfg.py \ No newline at end of file diff --git a/toolchain/semantics/testdata/return/binary_op.carbon b/toolchain/semantics/testdata/return/binary_op.carbon index 624d8d5d0d44..28ed95fe67b7 100644 --- a/toolchain/semantics/testdata/return/binary_op.carbon +++ b/toolchain/semantics/testdata/return/binary_op.carbon @@ -2,7 +2,7 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK: Function( // CHECK: %[[ID0:[0-9]+]], diff --git a/toolchain/semantics/testdata/return/literal.carbon b/toolchain/semantics/testdata/return/literal.carbon index e68b654a94ea..4a9690acd975 100644 --- a/toolchain/semantics/testdata/return/literal.carbon +++ b/toolchain/semantics/testdata/return/literal.carbon @@ -2,7 +2,7 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK: Function( // CHECK: %[[ID0:[0-9]+]], diff --git a/toolchain/semantics/testdata/return/trivial.carbon b/toolchain/semantics/testdata/return/trivial.carbon index 222e0aa759eb..91d029477a5b 100644 --- a/toolchain/semantics/testdata/return/trivial.carbon +++ b/toolchain/semantics/testdata/return/trivial.carbon @@ -2,7 +2,7 @@ // Exceptions. See /LICENSE for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // -// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheckStrict} %s +// RUN: %{carbon} dump semantics-ir %s 2>&1 | %{FileCheck-strict} %s // CHECK:{ // CHECK: Function( // CHECK: %[[ID0:[0-9]+]],