aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/expr.c
diff options
context:
space:
mode:
authorJason Merrill <jason@gcc.gnu.org>1998-09-07 10:25:35 -0400
committerJason Merrill <jason@gcc.gnu.org>1998-09-07 10:25:35 -0400
commit8251199e44be354aafd37dd69b56a4b1f9620120 (patch)
tree4f332f822cd36c92b7c27eee6c003577c1fec279 /gcc/cp/expr.c
parent5db17173c6fbef5fd203e486fe8407347edd7142 (diff)
downloadgcc-8251199e44be354aafd37dd69b56a4b1f9620120.zip
gcc-8251199e44be354aafd37dd69b56a4b1f9620120.tar.gz
gcc-8251199e44be354aafd37dd69b56a4b1f9620120.tar.bz2
revert error reporting patch
From-SVN: r22310
Diffstat (limited to 'gcc/cp/expr.c')
-rw-r--r--gcc/cp/expr.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/gcc/cp/expr.c b/gcc/cp/expr.c
index 8994891..4c3d8b6 100644
--- a/gcc/cp/expr.c
+++ b/gcc/cp/expr.c
@@ -331,10 +331,10 @@ do_case (start, end)
if (start != NULL_TREE && TREE_TYPE (start) != NULL_TREE
&& POINTER_TYPE_P (TREE_TYPE (start)))
- cp_error (ec_pointers_are_not_permitted_as_case_values);
+ error ("pointers are not permitted as case values");
if (end && pedantic)
- cp_pedwarn (ec_forbids_range_expressions_in_switch_statement);
+ pedwarn ("ANSI C++ forbids range expressions in switch statement");
if (processing_template_decl)
{
@@ -366,43 +366,43 @@ do_case (start, end)
if (success == 1)
{
if (end)
- cp_error (ec_case_label_not_within_a_switch_statement);
+ error ("case label not within a switch statement");
else if (start)
- cp_error (ec_case_label_not_within_a_switch_statement, start);
+ cp_error ("case label `%E' not within a switch statement", start);
else
- cp_error (ec_default_label_not_within_a_switch_statement);
+ error ("default label not within a switch statement");
}
else if (success == 2)
{
if (end)
{
- cp_error (ec_duplicate_or_overlapping_case_value);
- cp_error_at (ec_this_is_the_first_entry_overlapping_that_value,
+ error ("duplicate (or overlapping) case value");
+ cp_error_at ("this is the first entry overlapping that value",
duplicate);
}
else if (start)
{
- cp_error (ec_duplicate_case_value, start);
- cp_error_at (ec_previously_used_here, duplicate);
+ cp_error ("duplicate case value `%E'", start);
+ cp_error_at ("previously used here", duplicate);
}
else
{
- cp_error (ec_multiple_default_labels_in_one_switch);
- cp_error_at (ec_this_is_the_first_default_label, duplicate);
+ error ("multiple default labels in one switch");
+ cp_error_at ("this is the first default label", duplicate);
}
}
else if (success == 3)
- cp_warning (ec_case_value_out_of_range);
+ warning ("case value out of range");
else if (success == 4)
- cp_warning (ec_empty_range_specified);
+ warning ("empty range specified");
else if (success == 5)
{
if (end)
- cp_error (ec_case_label_within_scope_of_cleanup_or_variable_array);
+ error ("case label within scope of cleanup or variable array");
else if (! start)
- cp_error (ec_default_label_within_scope_of_cleanup_or_variable_array);
+ error ("`default' label within scope of cleanup or variable array");
else
- cp_error (ec_case_label_within_scope_of_cleanup_or_variable_array, start);
+ cp_error ("case label `%E' within scope of cleanup or variable array", start);
}
}
if (start)