8sa1-gcc/gcc/f/bad.h

109 lines
3.1 KiB
C
Raw Normal View History

1997-08-12 03:47:32 -04:00
/* bad.h -- Public #include File (module.h template V1.0)
Copyright (C) 1995 Free Software Foundation, Inc.
Contributed by James Craig Burley.
1997-08-12 03:47:32 -04:00
This file is part of GNU Fortran.
GNU Fortran is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU Fortran is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Fortran; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA.
Owning Modules:
bad.c
Modifications:
*/
/* Allow multiple inclusion to work. */
#ifndef _H_f_bad
#define _H_f_bad
/* Simple definitions and enumerations. */
typedef enum
{
#define FFEBAD_MSGS1(KWD,SEV,MSG) KWD,
#define FFEBAD_MSGS2(KWD,SEV,LMSG,SMSG) KWD,
#include "bad.def"
#undef FFEBAD_MSGS1
#undef FFEBAD_MSGS2
FFEBAD
} ffebad;
typedef enum
{
/* Order important; must be increasing severity. */
FFEBAD_severityINFORMATIONAL, /* User notice. */
FFEBAD_severityTRIVIAL, /* Internal notice. */
FFEBAD_severityWARNING, /* User warning. */
FFEBAD_severityPECULIAR, /* Internal warning. */
FFEBAD_severityPEDANTIC, /* Pedantic, could be warning or error. */
FFEBAD_severityFATAL, /* User error. */
FFEBAD_severityWEIRD, /* Internal error. */
FFEBAD_severitySEVERE, /* User error, cannot continue. */
FFEBAD_severityDISASTER, /* Internal error, cannot continue. */
FFEBAD_severity
} ffebadSeverity;
/* Typedefs. */
typedef unsigned char ffebadIndex;
/* Include files needed by this one. */
#include "where.h"
/* Structure definitions. */
/* Global objects accessed by users of this module. */
extern bool ffebad_is_inhibited_;
/* Declare functions with prototypes. */
void ffebad_finish (void);
void ffebad_here (ffebadIndex i, ffewhereLine wl, ffewhereColumn wc);
void ffebad_init_0 (void);
bool ffebad_is_fatal (ffebad errnum);
ffebadSeverity ffebad_severity (ffebad errnum);
bool ffebad_start_ (bool lex_override, ffebad errnum, ffebadSeverity sev,
Warning fixes: * bad.c (_ffebad_message_, ffebad_string_, ffebad_message_, ffebad_bufputs_, ffebad_bufputs_, ffebad_start_, ffebad_string, ffebad_finish): Const-ify a char*. * bld.c (ffebld_op_string_, ffebld_op_string): Likewise. * bld.h (ffebld_op_string): Likewise. * com.c (ffecom_arglist_expr_, ffecom_build_f2c_string_, ffecom_debug_kludge_, ffecom_f2c_make_type_, ffecom_get_appended_identifier_, ffecom_get_identifier_, ffecom_gfrt_args_): Likewise. (ffecom_convert_narrow_, ffecom_convert_widen_): Add prototype. (builtin_function, ffecom_gfrt_name_, ffecom_gfrt_argstring_, ffecom_arglist_expr_, ffecom_build_f2c_string_, ffecom_debug_kludge_, ffecom_f2c_make_type_, ffecom_get_appended_identifier_, ffecom_get_external_identifier_, ffecom_get_identifier_, ffecom_decl_field, ffecom_get_invented_identifier, lang_print_error_function, skip_redundant_dir_prefix, read_name_map, print_containing_files): Const-ify a char*. (savestring): Remove, use `xstrdup' instead. * com.h (ffecom_decl_field, ffecom_get_invented_identifier): Const-ify a char*. * data.c (ffebld, ffedata_gather_): Make explicitly static. * expr.c (ffeexpr_isdigits_, ffeexpr_percent_, ffeexpr_reduced_concatenate_, ffeexpr_nil_real_, ffeexpr_nil_number_, ffeexpr_nil_number_period_, ffeexpr_nil_number_real_, ffeexpr_token_real_, ffeexpr_token_number_, ffeexpr_token_number_period_, ffeexpr_token_number_real_): Const-ify a char*. * fini.c (xspaces): Likewise. * global.c (ffeglobal_type_string_): Likewise. (ffeglobal_drive): Protoize. (ffeglobal_proc_def_arg): Const-ify a char*. * global.h (ffeglobal_drive): Protoize. (ffeglobal_proc_def_arg): Const-ify a char*. * implic.c (ffeimplic_none, ffeimplic_peek_symbol_type): Likewise. * implic.h (ffeimplic_peek_symbol_type): Likewise. * info.c (ffeinfo_basictype_string_, ffeinfo_kind_message_, ffeinfo_kind_string_, ffeinfo_kindtype_string_, ffeinfo_where_string_, ffeinfo_basictype_string, ffeinfo_kind_message, ffeinfo_kind_string, ffeinfo_kindtype_string, ffeinfo_where_string): Likewise. * info.h (ffeinfo_basictype_string, ffeinfo_kind_message, ffeinfo_kind_string, ffeinfo_kindtype_string, ffeinfo_where_string): Likewise. * intrin.c (_ffeintrin_name_, _ffeintrin_gen_, _ffeintrin_spec_, _ffeintrin_imp_, ffeintrin_check_, ffeintrin_cmp_name_, ffeintrin_fulfill_specific, ffeintrin_init_0, ffeintrin_is_actualarg, ffeintrin_is_intrinsic, ffeintrin_name_generic, ffeintrin_name_implementation, ffeintrin_name_specific): Likewise. * intrin.h (ffeintrin_is_intrinsic, ffeintrin_name_generic, ffeintrin_name_implementation, ffeintrin_name_specific): Likewise. * lex.c (ffelex_type_string_, ffelex_token_new_character, ffelex_token_new_name, ffelex_token_new_names, ffelex_token_new_number): Likewise. * lex.h (ffelex_token_new_character, ffelex_token_new_name, ffelex_token_new_names, ffelex_token_new_number): Likewise. * malloc.c (malloc_types_, malloc_pool_new, malloc_new_inpool_, malloc_new_zinpool_): Likewise. * malloc.h (malloc_new_inpool_, malloc_new_zinpool_, malloc_pool_new): Likewise. * name.c (ffename_space_drive_global, ffename_space_drive_symbol): Protoize. * name.h (ffename_space_drive_global, ffename_space_drive_symbol): Likewise. * symbol.c (ffesymbol_state_name_, ffesymbol_attr_name_, ffesymbol_attrs_string): Const-ify a char*. (ffesymbol_drive, ffesymbol_drive_sfnames): Protoize. (ffesymbol_state_string): Const-ify a char*. * symbol.h (ffesymbol_attrs_string): Likewise. (ffesymbol_drive, ffesymbol_drive_sfnames): Protoize. (ffesymbol_state_string): Const-ify a char*. * target.c (ffetarget_layout): Likewise. * target.h (ffetarget_layout): Likewise. From-SVN: r26013
1999-03-27 05:24:06 -05:00
const char *message);
void ffebad_string (const char *string);
1997-08-12 03:47:32 -04:00
/* Define macros. */
#define ffebad_inhibit() (ffebad_is_inhibited_)
#define ffebad_init_1()
#define ffebad_init_2()
#define ffebad_init_3()
#define ffebad_init_4()
#define ffebad_set_inhibit(f) (ffebad_is_inhibited_ = (f))
#define ffebad_start(e) ffebad_start_ (FALSE, (e), FFEBAD_severity, NULL)
#define ffebad_start_lex(e) ffebad_start_ (TRUE, (e), FFEBAD_severity, NULL)
#define ffebad_start_msg(m,s) ffebad_start_ (FALSE, FFEBAD, (s), (m))
#define ffebad_start_msg_lex(m,s) ffebad_start_ (TRUE, FFEBAD, (s), (m))
#define ffebad_terminate_0()
#define ffebad_terminate_1()
#define ffebad_terminate_2()
#define ffebad_terminate_3()
#define ffebad_terminate_4()
/* End of #include file. */
#endif