![]() |
GnuCOBOL
2.0
A free COBOL compiler
|
#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <ctype.h>
#include <stdarg.h>
#include "cobc.h"
#include "tree.h"
Functions | |
static void | print_error (const char *file, int line, const char *prefix, const char *fmt, va_list ap) |
void | cb_warning (const char *fmt,...) |
void | cb_error (const char *fmt,...) |
void | cb_plex_warning (const size_t sline, const char *fmt,...) |
void | cb_plex_error (const size_t sline, const char *fmt,...) |
void | configuration_error (const char *fname, const int line, const char *fmt,...) |
void | cb_warning_x (cb_tree x, const char *fmt,...) |
void | cb_error_x (cb_tree x, const char *fmt,...) |
unsigned int | cb_verify (const enum cb_support tag, const char *feature) |
void | redefinition_error (cb_tree x) |
void | redefinition_warning (cb_tree x, cb_tree y) |
void | undefined_error (cb_tree x) |
void | ambiguous_error (cb_tree x) |
void | group_error (cb_tree x, const char *clause) |
void | level_redundant_error (cb_tree x, const char *clause) |
void | level_require_error (cb_tree x, const char *clause) |
void | level_except_error (cb_tree x, const char *clause) |
Variables | |
static char * | errnamebuff = NULL |
static struct cb_label * | last_section = NULL |
static struct cb_label * | last_paragraph = NULL |
static unsigned int | conf_error_displayed = 0 |
size_t | cb_msg_style |
void ambiguous_error | ( | cb_tree | x | ) |
References _, CB_CHAIN, cb_error_x(), CB_FIELD, CB_LABEL, CB_NAME, cb_name(), CB_REFERENCE, CB_TAG_FIELD, CB_TAG_LABEL, CB_TREE, CB_TREE_TAG, CB_VALUE, COB_NORMAL_BUFF, COB_NORMAL_MAX, cobc_main_malloc(), errnamebuff, cb_word::error, cb_word::items, cb_label::name, cb_word::name, p, cb_field::parent, and cb_label::section.
Referenced by cb_ref().
void cb_error | ( | const char * | fmt, |
... | |||
) |
References _, cobc_cs_check, cobc_in_repository, cobc_too_many_errors(), errorcount, NULL, and print_error().
Referenced by build_evaluate(), cb_build_const_length(), cb_build_locale_name(), cb_build_picture(), cb_expr_finish(), cb_validate_program_data(), cb_verify(), check_comp_repeated(), check_pic_repeated(), check_relaxed_syntax(), check_repeated(), check_screen_attr(), cobc_error_name(), finalize_file(), if(), increment_depth(), lookup_reserved_word(), make_intrinsic(), ppcopy(), ppopen(), ppp_define_add(), scan_define_options(), scan_floating_numeric(), scan_h(), scan_numeric(), scan_x(), setup_use_file(), and while().
void cb_error_x | ( | cb_tree | x, |
const char * | fmt, | ||
... | |||
) |
References _, cobc_too_many_errors(), errorcount, print_error(), cb_tree_common::source_file, and cb_tree_common::source_line.
Referenced by ambiguous_error(), cb_build_address(), cb_build_binary_op(), cb_build_cond(), cb_build_display_mnemonic(), cb_build_display_name(), cb_build_field_tree(), cb_build_identifier(), cb_build_intrinsic(), cb_build_replacing_characters(), cb_build_tallying_all(), cb_build_tallying_characters(), cb_build_tallying_leading(), cb_build_tallying_trailing(), cb_build_tallying_value(), cb_build_write_advancing_mnemonic(), cb_check_group_name(), cb_check_integer_value(), cb_check_numeric_edited_name(), cb_check_numeric_name(), cb_check_numeric_value(), cb_define_switch_name(), cb_emit_accept(), cb_emit_accept_mnemonic(), cb_emit_accept_name(), cb_emit_allocate(), cb_emit_call(), cb_emit_close(), cb_emit_delete(), cb_emit_delete_file(), cb_emit_display(), cb_emit_free(), cb_emit_goto(), cb_emit_inspect(), cb_emit_move(), cb_emit_open(), cb_emit_read(), cb_emit_release(), cb_emit_rewrite(), cb_emit_set_attribute(), cb_emit_set_false(), cb_emit_set_to(), cb_emit_set_true(), cb_emit_sort_giving(), cb_emit_sort_init(), cb_emit_sort_using(), cb_emit_start(), cb_emit_write(), cb_get_level(), cb_resolve_redefines(), cb_validate_88_item(), cb_validate_collating(), cb_validate_one(), cb_validate_program_body(), cb_validate_program_data(), cb_validate_program_environment(), check_picture_item(), check_valid_key(), compute_size(), emit_entry(), evaluate_test(), file_error(), group_error(), level_except_error(), level_redundant_error(), level_require_error(), redefinition_error(), search_set_keys(), terminator_error(), undefined_error(), valid_const_date_time_args(), validate_field_1(), validate_field_clauses(), validate_inspect(), and validate_move().
void cb_plex_error | ( | const size_t | sline, |
const char * | fmt, | ||
... | |||
) |
References _, cb_source_line, cobc_too_many_errors(), errorcount, NULL, and print_error().
Referenced by plex_action_directive(), ppinput(), and ppparse_error().
void cb_plex_warning | ( | const size_t | sline, |
const char * | fmt, | ||
... | |||
) |
References _, cb_source_line, NULL, print_error(), and warningcount.
Referenced by ppinput(), and while().
unsigned int cb_verify | ( | const enum cb_support | tag, |
const char * | feature | ||
) |
References _, CB_ARCHAIC, CB_ERROR, cb_error(), CB_IGNORE, CB_OBSOLETE, CB_OK, CB_SKIP, CB_UNCONFORMABLE, CB_WARNING, cb_warning(), and warningopt.
Referenced by cb_emit_goto(), check_comments(), compute_size(), validate_field_1(), and while().
void cb_warning | ( | const char * | fmt, |
... | |||
) |
References _, NULL, print_error(), and warningcount.
Referenced by begin_statement(), cb_build_assignment_name(), cb_emit_call(), cb_emit_read(), cb_validate_program_data(), cb_verify(), check_comp_repeated(), check_pic_repeated(), check_relaxed_syntax(), check_repeated(), check_screen_attr(), emit_entry(), expr_reduce(), ppp_compare_vals(), read_literal(), and warning_destination().
void cb_warning_x | ( | cb_tree | x, |
const char * | fmt, | ||
... | |||
) |
References _, print_error(), cb_tree_common::source_file, cb_tree_common::source_line, and warningcount.
Referenced by cb_build_address(), cb_build_display_name(), cb_build_field_tree(), cb_build_identifier(), cb_check_overlapping(), cb_emit_accept_name(), cb_emit_call(), cb_emit_corresponding(), cb_emit_move_corresponding(), cb_validate_program_body(), cb_validate_program_environment(), check_picture_item(), compute_size(), move_warning(), redefinition_warning(), terminator_warning(), undefined_error(), valid_const_date_time_args(), validate_field_1(), validate_move(), and warning_destination().
void configuration_error | ( | const char * | fname, |
const int | line, | ||
const char * | fmt, | ||
... | |||
) |
References _, and conf_error_displayed.
Referenced by cb_config_entry(), cb_load_conf(), invalid_value(), process_command_line(), and unsupported_value().
void group_error | ( | cb_tree | x, |
const char * | clause | ||
) |
void level_except_error | ( | cb_tree | x, |
const char * | clause | ||
) |
References _, cb_error_x(), CB_FIELD_PTR, cb_name(), cb_field::flag_item_78, and cb_field::level.
Referenced by cb_validate_78_item(), cb_validate_88_item(), and validate_field_1().
void level_redundant_error | ( | cb_tree | x, |
const char * | clause | ||
) |
References _, cb_error_x(), CB_FIELD_PTR, cb_name(), cb_field::flag_item_78, and cb_field::level.
Referenced by validate_field_1().
void level_require_error | ( | cb_tree | x, |
const char * | clause | ||
) |
References _, cb_error_x(), CB_FIELD_PTR, cb_name(), cb_field::flag_item_78, and cb_field::level.
Referenced by cb_validate_78_item(), cb_validate_88_item(), check_picture_item(), and validate_field_1().
|
static |
References _, cb_msg_style, CB_MSG_STYLE_MSC, cb_source_file, cb_source_line, current_paragraph, current_section, cb_label::flag_dummy_paragraph, cb_label::flag_dummy_section, and cb_label::name.
Referenced by cb_error(), cb_error_x(), cb_plex_error(), cb_plex_warning(), cb_warning(), and cb_warning_x().
void redefinition_error | ( | cb_tree | x | ) |
References _, cb_error_x(), CB_REFERENCE, CB_VALUE, cb_word::items, and cb_word::name.
Referenced by cb_build_section_name(), and cb_validate_program_data().
References _, CB_REFERENCE, CB_VALUE, cb_warning_x(), cb_word::items, cb_word::name, and NULL.
Referenced by cb_build_field_tree().
void undefined_error | ( | cb_tree | x | ) |
References _, cb_error_x(), CB_NAME, CB_REFERENCE, cb_warning_x(), cb_reference::chain, COB_NORMAL_BUFF, COB_NORMAL_MAX, cobc_main_malloc(), errnamebuff, and cb_reference::flag_optional.
Referenced by cb_ref(), and cb_resolve_redefines().
size_t cb_msg_style |
Referenced by cobc_print_info(), main(), and print_error().
|
static |
Referenced by configuration_error().
|
static |
Referenced by ambiguous_error(), and undefined_error().