diff options
author | fxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-09-17 18:58:01 +0000 |
---|---|---|
committer | fxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-09-17 18:58:01 +0000 |
commit | 41481754c30dea84669a0cf470cce266af0df21c (patch) | |
tree | 359a816dbf10dd679ca548628aef0b485522372a /gcc/fortran/primary.c | |
parent | 80e467e287ab9691aebede717bef9ff519a743f8 (diff) | |
download | ppe42-gcc-41481754c30dea84669a0cf470cce266af0df21c.tar.gz ppe42-gcc-41481754c30dea84669a0cf470cce266af0df21c.zip |
PR fortran/15586
* arith.c (gfc_arith_error): Add translation support
for error messages.
* array.c (gfc_match_array_ref): Likewise.
(gfc_match_array_spec): Likewise.
* check.c (must_be): Add msgid convention to third argument.
(same_type_check): Add translation support for error message.
(rank_check): Likewise.
(kind_value_check): Likewise.
(gfc_check_associated): Correct typo.
(gfc_check_reshape): Add translation support for error message.
(gfc_check_spread): Likewise.
* error.c (error_printf): Add nocmsgid convention to argument.
(gfc_warning, gfc_notify_std, gfc_warning_now, gfc_warning_check)
(gfc_error, gfc_error_now): Likewise.
(gfc_status): Add cmsgid convention to argument.
* expr.c (gfc_extract_int): Add translation support
for error messages.
(gfc_check_conformance): Add msgid convention to argument.
(gfc_check_pointer_assign): Correct tabbing.
* gfortran.h: Include intl.h header. Remove prototype
for gfc_article.
* gfortranspec.c: Include intl.h header.
(lang_specific_driver): Add translation support for --version.
* io.c (check_format): Add translation support for
error message.
(format_item_1): Likewise.
(data_desc): Likewise.
* matchexp.c: Likewise.
* misc.c (gfc_article): Remove function.
* module.c (bad_module): Use msgid convention. Add
translation support for error messages.
(require_atom): Add translation support for error messages.
* parse.c (gfc_ascii_statement): Likewise.
(gfc_state_name): Likewise.
* primary.c (match_boz_constant): Reorganise error
messages for translations.
* resolve.c (resolve_entries): Likewise.
(resolve_operator): Add translation support for error messages.
(gfc_resolve_expr): Use msgid convention. Reorganise error
messages for translations.
(resolve_symbol): Add translation support for error messages.
* symbol.c (gfc_add_procedure): Remove use of gfc_article function.
* trans-const.c (gfc_build_string_const): Use msgid convention.
* exgettext: Add a new nocmsgid convention for arguments
that should be marked as no-c-format.
* gcc.pot: Regenerate.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@104372 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/fortran/primary.c')
-rw-r--r-- | gcc/fortran/primary.c | 28 |
1 files changed, 22 insertions, 6 deletions
diff --git a/gcc/fortran/primary.c b/gcc/fortran/primary.c index 48a5f347d9c..3ef8d4e376b 100644 --- a/gcc/fortran/primary.c +++ b/gcc/fortran/primary.c @@ -307,7 +307,6 @@ match_boz_constant (gfc_expr ** result) locus old_loc; char *buffer; gfc_expr *e; - const char *rname; old_loc = gfc_current_locus; gfc_gobble_whitespace (); @@ -317,18 +316,15 @@ match_boz_constant (gfc_expr ** result) { case 'b': radix = 2; - rname = "binary"; break; case 'o': radix = 8; - rname = "octal"; break; case 'x': x_hex = 1; /* Fall through. */ case 'z': radix = 16; - rname = "hexadecimal"; break; default: goto backup; @@ -351,13 +347,33 @@ match_boz_constant (gfc_expr ** result) length = match_digits (0, radix, NULL); if (length == -1) { - gfc_error ("Empty set of digits in %s constants at %C", rname); + switch (radix) + { + case 2: + gfc_error ("Empty set of digits in binary constant at %C"); + case 8: + gfc_error ("Empty set of digits in octal constant at %C"); + case 16: + gfc_error ("Empty set of digits in hexadecimal constant at %C"); + default: + gcc_unreachable (); + } return MATCH_ERROR; } if (gfc_next_char () != delim) { - gfc_error ("Illegal character in %s constant at %C.", rname); + switch (radix) + { + case 2: + gfc_error ("Illegal character in binary constant at %C"); + case 8: + gfc_error ("Illegal character in octal constant at %C"); + case 16: + gfc_error ("Illegal character in hexadecimal constant at %C"); + default: + gcc_unreachable (); + } return MATCH_ERROR; } |