diff options
45 files changed, 150 insertions, 1826 deletions
diff --git a/Driver/clang.cpp b/Driver/clang.cpp index d7c8beb1d3..8002318b6a 100644 --- a/Driver/clang.cpp +++ b/Driver/clang.cpp @@ -40,6 +40,7 @@ #include "clang/Basic/FileManager.h" #include "clang/Basic/SourceManager.h" #include "clang/Basic/TargetInfo.h" +#include "clang/Basic/DiagnosticDriver.h" #include "llvm/ADT/OwningPtr.h" #include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/StringExtras.h" diff --git a/include/clang/Basic/Diagnostic.h b/include/clang/Basic/Diagnostic.h index a78f733315..d1c045704a 100644 --- a/include/clang/Basic/Diagnostic.h +++ b/include/clang/Basic/Diagnostic.h @@ -18,6 +18,13 @@ #include <string> #include <cassert> +#define DIAG_START_LEX 300 +#define DIAG_START_PARSE (DIAG_START_LEX + 300) +#define DIAG_START_AST (DIAG_START_PARSE + 300) +#define DIAG_START_SEMA (DIAG_START_AST + 100) +#define DIAG_START_ANALYSIS (DIAG_START_SEMA + 1000) +#define DIAG_UPPER_LIMIT (DIAG_START_ANALYSIS + 100) + namespace llvm { template <typename T> class SmallVectorImpl; } @@ -34,12 +41,8 @@ namespace clang { class CustomDiagInfo; /// diag::kind - All of the diagnostics that can be emitted by the frontend. - enum kind { -#define DIAG(ENUM,FLAGS,DESC) ENUM, -#include "DiagnosticKinds.def" - NUM_BUILTIN_DIAGNOSTICS - }; - + typedef unsigned kind; + /// Enum values that allow the client to map NOTEs, WARNINGs, and EXTENSIONs /// to either MAP_IGNORE (nothing), MAP_WARNING (emit a warning), MAP_ERROR /// (emit as an error), or MAP_DEFAULT (handle the default way). @@ -82,7 +85,7 @@ private: /// DiagMappings - Mapping information for diagnostics. Mapping info is /// packed into two bits per diagnostic. - unsigned char DiagMappings[(diag::NUM_BUILTIN_DIAGNOSTICS+3)/4]; + unsigned char DiagMappings[DIAG_UPPER_LIMIT/4]; /// ErrorOccurred - This is set to true when an error is emitted, and is /// sticky. @@ -144,7 +147,7 @@ public: /// setDiagnosticMapping - This allows the client to specify that certain /// warnings are ignored. Only NOTEs, WARNINGs, and EXTENSIONs can be mapped. void setDiagnosticMapping(diag::kind Diag, diag::Mapping Map) { - assert(Diag < diag::NUM_BUILTIN_DIAGNOSTICS && + assert(Diag < DIAG_UPPER_LIMIT && "Can only map builtin diagnostics"); assert(isBuiltinNoteWarningOrExtension(Diag) && "Cannot map errors!"); unsigned char &Slot = DiagMappings[Diag/4]; diff --git a/include/clang/Basic/DiagnosticKinds.def b/include/clang/Basic/DiagnosticKinds.def index 5ff6728283..70a4821ea1 100644 --- a/include/clang/Basic/DiagnosticKinds.def +++ b/include/clang/Basic/DiagnosticKinds.def @@ -22,1775 +22,12 @@ // by default. // ERROR - Error, compilation will stop after parsing completes. -//===----------------------------------------------------------------------===// -// Common Helpers -//===----------------------------------------------------------------------===// - -DIAG(note_previous_definition, NOTE, - "previous definition is here") -DIAG(note_previous_declaration, NOTE, - "previous declaration is here") -DIAG(note_previous_implicit_declaration, NOTE, - "previous implicit declaration is here") -DIAG(note_previous_use, NOTE, - "previous use is here") -DIAG(note_duplicate_case_prev, NOTE, - "previous case defined here") -DIAG(note_forward_declaration, NOTE, - "forward declaration of %0") -DIAG(note_type_being_defined, NOTE, - "definition of %0 is not complete until the closing '}'") -/// note_matching - this is used as a continuation of a previous diagnostic, -/// e.g. to specify the '(' when we expected a ')'. -DIAG(note_matching, NOTE, - "to match this '%0'") - -DIAG(note_using_decl, NOTE, - "using") -DIAG(note_also_found_decl, NOTE, - "also found") - -//===----------------------------------------------------------------------===// -// Lexer Diagnostics -//===----------------------------------------------------------------------===// - -DIAG(null_in_string, WARNING, - "null character(s) preserved in string literal") -DIAG(null_in_char , WARNING, - "null character(s) preserved in character literal") -DIAG(null_in_file , WARNING, - "null character ignored") -DIAG(warn_nested_block_comment, WARNING, - "'/*' within block comment") -DIAG(escaped_newline_block_comment_end, WARNING, - "escaped newline between */ characters at block comment end") -DIAG(backslash_newline_space, WARNING, - "backslash and newline separated by space") - -// Trigraphs. -DIAG(trigraph_ignored, WARNING, "trigraph ignored") -DIAG(trigraph_ignored_block_comment, WARNING, - "ignored trigraph would end block comment") -DIAG(trigraph_ends_block_comment, WARNING, - "trigraph ends block comment") -DIAG(trigraph_converted, WARNING, - "trigraph converted to '%0' character") - -DIAG(ext_multi_line_bcpl_comment, EXTENSION, - "multi-line // comment") -DIAG(ext_bcpl_comment, EXTENSION, - "// comments are not allowed in this language") -DIAG(ext_no_newline_eof, EXTENSION, - "no newline at end of file") -DIAG(ext_backslash_newline_eof, EXTENSION, - "backslash-newline at end of file") -DIAG(ext_dollar_in_identifier, EXTENSION, - "'$' in identifier") -DIAG(charize_microsoft_ext, EXTENSION, - "@# is a microsoft extension") - -DIAG(ext_token_used, EXTENSION, - "extension used") - -DIAG(err_unterminated_string, ERROR, - "missing terminating \" character") -DIAG(err_unterminated_char, ERROR, - "missing terminating ' character") -DIAG(err_empty_character, ERROR, - "empty character constant") -DIAG(err_unterminated_block_comment, ERROR, - "unterminated /* comment") -DIAG(err_invalid_character_to_charify, ERROR, - "invalid argument to convert to character") - -//===----------------------------------------------------------------------===// -// Preprocessor Diagnostics -//===----------------------------------------------------------------------===// - -DIAG(pp_hash_warning, WARNING, - "#warning%0") -DIAG(pp_include_next_in_primary, WARNING, - "#include_next in primary source file") -DIAG(pp_include_next_absolute_path, WARNING, - "#include_next with absolute path") -DIAG(ext_c99_whitespace_required_after_macro_name, WARNING, - "ISO C99 requires whitespace after the macro name") -DIAG(pp_pragma_once_in_main_file, WARNING, - "#pragma once in main file") -DIAG(pp_pragma_sysheader_in_main_file, WARNING, - "#pragma system_header ignored in main file") -DIAG(pp_poisoning_existing_macro, WARNING, - "poisoning existing macro") -DIAG(pp_out_of_date_dependency, WARNING, - "current file is older than dependency %0") -DIAG(pp_undef_builtin_macro, WARNING, - "undefining builtin macro") -DIAG(pp_redef_builtin_macro, WARNING, - "redefining builtin macro") -DIAG(pp_macro_not_used, WARNING, // -Wunused-macros - "macro is not used") -DIAG(pp_invalid_string_literal, WARNING, - "invalid string literal, ignoring final '\\'") -DIAG(warn_pp_expr_overflow, WARNING, - "integer overflow in preprocessor expression") -DIAG(warn_pp_convert_lhs_to_positive, WARNING, - "left side of operator converted from negative value to unsigned: %0") -DIAG(warn_pp_convert_rhs_to_positive, WARNING, - "right side of operator converted from negative value to unsigned: %0") - -DIAG(ext_pp_import_directive, EXTENSION, - "#import is a language extension") -DIAG(ext_pp_ident_directive, EXTENSION, - "#ident is a language extension") -DIAG(ext_pp_include_next_directive, EXTENSION, - "#include_next is a language extension") -DIAG(ext_pp_warning_directive, EXTENSION, - "#warning is a language extension") -DIAG(ext_pp_extra_tokens_at_eol, EXTENSION, - "extra tokens at end of %0 directive") -DIAG(ext_pp_comma_expr, EXTENSION, - "comma operator in operand of #if") -DIAG(ext_pp_bad_vaargs_use, EXTENSION, - "__VA_ARGS__ can only appear in the expansion of a C99 variadic macro") -DIAG(ext_pp_macro_redef, EXTENSION, - "%0 macro redefined") -DIAG(ext_variadic_macro, EXTENSION, - "variadic macros were introduced in C99") -DIAG(ext_named_variadic_macro, EXTENSION, - "named variadic macros are a GNU extension") -DIAG(ext_embedded_directive, EXTENSION, - "embedding a directive within macro arguments is not portable") -DIAG(ext_missing_varargs_arg, EXTENSION, - "varargs argument missing, but tolerated as an extension") -DIAG(ext_empty_fnmacro_arg, EXTENSION, - "empty macro arguments were standardized in C99") - -DIAG(ext_pp_base_file, EXTENSION, - "__BASE_FILE__ is a language extension") -DIAG(ext_pp_include_level, EXTENSION, - "__INCLUDE_LEVEL__ is a language extension") -DIAG(ext_pp_timestamp, EXTENSION, - "__TIMESTAMP__ is a language extension") - -DIAG(err_pp_invalid_directive, ERROR, - "invalid preprocessing directive") -DIAG(err_pp_hash_error, ERROR, - "#error%0") -DIAG(err_pp_file_not_found, ERROR, - "'%0' file not found") -DIAG(err_pp_empty_filename, ERROR, - "empty filename") -DIAG(err_pp_include_too_deep, ERROR, - "#include nested too deeply") -DIAG(err_pp_expects_filename, ERROR, - "expected \"FILENAME\" or <FILENAME>") -DIAG(err_pp_macro_not_identifier, ERROR, - "macro names must be identifiers") -DIAG(err_pp_missing_macro_name, ERROR, - "macro name missing") -DIAG(err_pp_missing_rparen_in_macro_def, ERROR, - "missing ')' in macro parameter list") -DIAG(err_pp_invalid_tok_in_arg_list, ERROR, - "invalid token in macro parameter list") -DIAG(err_pp_expected_ident_in_arg_list, ERROR, - "expected identifier in macro parameter list") -DIAG(err_pp_expected_comma_in_arg_list, ERROR, - "expected comma in macro parameter list") -DIAG(err_pp_duplicate_name_in_arg_list, ERROR, - "duplicate macro parameter name %0") -DIAG(err_pp_stringize_not_parameter, ERROR, - "'#' is not followed by a macro parameter") -DIAG(err_pp_line_requires_integer, ERROR, - "#line directive requires a positive integer argument") -DIAG(err_pp_line_invalid_filename, ERROR, - "invalid filename for #line directive") -DIAG(err_pp_linemarker_requires_integer, ERROR, - "line marker directive requires a positive integer argument") -DIAG(err_pp_linemarker_invalid_filename, ERROR, - "invalid filename for line marker directive") -DIAG(err_pp_linemarker_invalid_flag, ERROR, - "invalid flag line marker directive") -DIAG(ext_pp_line_too_big, EXTENSION, - "C requires #line number to be less than %0, allowed as extension") - -DIAG(err_pp_malformed_ident, ERROR, - "invalid #ident directive") -DIAG(err_pp_unterminated_conditional, ERROR, - "unterminated conditional directive") -DIAG(pp_err_else_after_else, ERROR, - "#else after #else") -DIAG(pp_err_elif_after_else, ERROR, - "#elif after #else") -DIAG(pp_err_else_without_if, ERROR, - "#else without #if") -DIAG(pp_err_elif_without_if, ERROR, - "#elif without #if") -DIAG(err_pp_endif_without_if, ERROR, - "#endif without #if") -DIAG(err_pp_expected_value_in_expr, ERROR, - "expected value in expression") -DIAG(err_pp_missing_val_before_operator, ERROR, - "missing value before operator") -DIAG(err_pp_expected_rparen, ERROR, - "expected ')' in preprocessor expression") -DIAG(err_pp_expected_eol, ERROR, - "expected end of line in preprocessor expression") -DIAG(warn_pp_undef_identifier, WARNING, - "%0 is not defined, evaluates to 0") -DIAG(err_pp_defined_requires_identifier, ERROR, - "operator 'defined' requires an identifier") -DIAG(err_pp_missing_rparen, ERROR, - "missing ')' after 'defined'") -DIAG(err_pp_colon_without_question, ERROR, - "':' without preceding '?'") -DIAG(err_pp_division_by_zero, ERROR, - "division by zero in preprocessor expression") -DIAG(err_pp_remainder_by_zero, ERROR, - "remainder by zero in preprocessor expression") -DIAG(err_pp_expr_bad_token_binop, ERROR, - "token is not a valid binary operator in a preprocessor subexpression") -DIAG(err_pp_expr_bad_token_start_expr, ERROR, - "invalid token at start of a preprocessor expression") -DIAG(err_pp_invalid_poison, ERROR, - "can only poison identifier tokens") -DIAG(err_pp_used_poisoned_id, ERROR, - "attempt to use a poisoned identifier") -DIAG(err__Pragma_malformed, ERROR, - "_Pragma takes a parenthesized string literal") -DIAG(err_pragma_comment_malformed, ERROR, - "pragma comment requires parenthesized identifier and optional string") -DIAG(err_pragma_comment_unknown_kind, ERROR, - "unknown kind of pragma comment") -DIAG(err_defined_macro_name, ERROR, - "'defined' cannot be used as a macro name") -DIAG(err_paste_at_start, ERROR, - "'##' cannot appear at start of macro expansion") -DIAG(err_paste_at_end, ERROR, - "'##' cannot appear at end of macro expansion") -DIAG(ext_paste_comma, EXTENSION, - "Use of comma pasting extension is non-portable") -DIAG(err_unterm_macro_invoc, ERROR, - "unterminated function-like macro invocation") -DIAG(err_too_many_args_in_macro_invoc, ERROR, - "too many arguments provided to function-like macro invocation") -DIAG(err_too_few_args_in_macro_invoc, ERROR, - "too few arguments provided to function-like macro invocation") -DIAG(err_pp_bad_paste, ERROR, - "pasting formed '%0', an invalid preprocessing token") -DIAG(err_pp_operator_used_as_macro_name, ERROR, - "C++ operator '%0' cannot be used as a macro name") -DIAG(err_pp_illegal_floating_literal, ERROR, - "floating point literal in preprocessor expression") - -// Should be a sorry? -DIAG(err_pp_I_dash_not_supported, ERROR, - "-I- not supported, please use -iquote instead") - -//===----------------------------------------------------------------------===// -// Parser Diagnostics -//===----------------------------------------------------------------------===// - -DIAG(w_asm_qualifier_ignored, WARNING, - "ignored %0 qualifier on asm") - -DIAG(ext_empty_source_file, EXTENSION, - "ISO C forbids an empty source file") -DIAG(ext_top_level_semi, EXTENSION, - "ISO C does not allow an extra ';' outside of a function") -DIAG(ext_extra_struct_semi, EXTENSION, - "ISO C does not allow an extra ';' inside a struct or union") -DIAG(ext_missing_declspec, EXTENSION, - "declaration specifier missing, defaulting to 'int'") -DIAG(ext_missing_type_specifier, EXTENSION, - "type specifier missing, defaults to 'int'") - -DIAG(ext_duplicate_declspec, EXTENSION, - "duplicate '%0' declaration specifier") -DIAG(ext_plain_complex, EXTENSION, - "ISO C does not support plain '_Complex' meaning '_Complex double'") -DIAG(ext_integer_complex, EXTENSION, - "ISO C does not support complex integer types") -DIAG(ext_thread_before, EXTENSION, - "'__thread' before 'static'") -DIAG(ext_integer_increment_complex, EXTENSION, - "ISO C does not support '++'/'--' on complex integer type %0") -DIAG(ext_integer_complement_complex, EXTENSION, - "ISO C does not support '~' for complex conjugation of %0") - -DIAG(ext_mixed_decls_code, EXTENSION, - "ISO C90 forbids mixing declarations and code") - -DIAG(ext_empty_struct_union_enum, EXTENSION, - "use of empty %0 extension") -DIAG(warn_enum_value_overflow, WARNING, - "overflow in enumeration value") - -DIAG(ext_ident_list_in_param, EXTENSION, - "type-less parameter names in function declaration") -DIAG(ext_c99_array_usage, EXTENSION, - "use of C99-specific array features, accepted as an extension") -DIAG(ext_c99_variable_decl_in_for_loop, EXTENSION, - "variable declaration in for loop is a C99-specific feature") -DIAG(ext_c99_compound_literal, EXTENSION, - "compound literals are a C99-specific feature") -DIAG(ext_c99_enumerator_list_comma, EXTENSION, - "commas at the end of enumerator lists are a C99-specific feature") - -DIAG(ext_gnu_void_ptr, EXTENSION, - "use of GNU void* extension") -DIAG(ext_gnu_indirect_goto, EXTENSION, - "use of GNU indirect-goto extension") -DIAG(ext_gnu_address_of_label, EXTENSION, - "use of GNU address-of-label extension") -DIAG(ext_gnu_statement_expr, EXTENSION, - "use of GNU statement expression extension") -DIAG(ext_gnu_conditional_expr, EXTENSION, - "use of GNU ?: expression extension, eliding middle term") -DIAG(ext_gnu_empty_initializer, EXTENSION, - "use of GNU empty initializer extension") -DIAG(ext_gnu_array_range, EXTENSION, - "use of GNU array range extension") -DIAG(ext_gnu_missing_equal_designator, EXTENSION, - "use of GNU 'missing =' extension in designator") -DIAG(err_expected_equal_designator, ERROR, - "expected '=' or another designator") -DIAG(ext_gnu_old_style_field_designator, EXTENSION, - "use of GNU old-style field designator extension") -DIAG(ext_gnu_case_range, EXTENSION, - "use of GNU case range extension") -DIAG(ext_gnu_ptr_func_arith, EXTENSION, - "arithmetic on pointer to function type %0 is a GNU extension") - -// Generic errors. -DIAG(err_parse_error, ERROR, - "parse error") -DIAG(err_expected_expression, ERROR, - "expected expression") -DIAG(err_expected_type, ERROR, - "expected a type") -DIAG(err_expected_external_declaration, ERROR, - "expected external declaration") -DIAG(err_expected_ident, ERROR, - "expected identifier") -DIAG(err_expected_ident_lparen, ERROR, - "expected identifier or '('") -DIAG(err_expected_ident_lbrace, ERROR, - "expected identifier or '{'") -DIAG(err_expected_lbrace, ERROR, - "expected '{'") -DIAG(err_expected_lparen, ERROR, - "expected '('") -DIAG(err_expected_rparen, ERROR, - "expected ')'") -DIAG(err_expected_rsquare, ERROR, - "expected ']'") -DIAG(err_expected_rbrace, ERROR, - "expected '}'") -DIAG(err_expected_greater, ERROR, - "expected '>'") -DIAG(err_expected_semi_decl_list, ERROR, - "expected ';' at end of declaration list") -DIAG(ext_expected_semi_decl_list, EXTENSION, - "expected ';' at end of declaration list") -DIAG(err_function_declared_typedef, ERROR, - "function definition declared 'typedef'") -DIAG(err_expected_fn_body, ERROR, - "expected function body after function declarator") -DIAG(err_expected_method_body, ERROR, - "expected method body") -DIAG(err_expected_after_declarator, ERROR, - "expected '=', ',', ';', 'asm', or '__attribute__' after declarator") -DIAG(err_expected_statement, ERROR, - "expected statement") -DIAG(err_expected_lparen_after, ERROR, - "expected '(' after '%0'") -DIAG(err_expected_lparen_after_id, ERROR, - "expected '(' after %0") -DIAG(err_expected_less_after, ERROR, - "expected '<' after '%0'") -DIAG(err_expected_comma, ERROR, - "expected ','") -DIAG(err_expected_lbrace_in_compound_literal, ERROR, - "expected '{' in compound literal") -DIAG(err_expected_while, ERROR, - "expected 'while' in do/while loop") -DIAG(err_expected_semi_after, ERROR, - "expected ';' after %0") -DIAG(err_expected_semi_after_expr, ERROR, - "expected ';' after expression") -DIAG(err_expected_semi_for, ERROR, - "expected ';' in 'for' statement specifier") -DIAG(err_non_variable_decl_in_for, ERROR, - "declaration of non-local variable in 'for' loop") -DIAG(err_expected_colon_after, ERROR, - "expected ':' after %0") -DIAG(err_label_end_of_compound_statement, ERROR, - "label at end of compound statement: expected statement") -DIAG(err_expected_colon, ERROR, - "expected ':'") -DIAG(err_expected_string_literal, ERROR, - "expected string literal") -DIAG(err_expected_asm_operand, ERROR, - "expected string literal or '[' for asm operand") -DIAG(err_expected_selector_for_method, ERROR, - "expected selector for Objective-C method") -DIAG(err_object_as_method_param, ERROR, - "can not use an object as parameter to a method") -DIAG(err_nsobject_attribute, ERROR, - "__attribute ((NSObject)) is for pointer types only") - -DIAG(err_unexpected_at, ERROR, - "unexpected '@' in program") - -/// Objective-C parser diagnostics -DIAG(err_unexpected_interface, ERROR, - "unexpected interface name %0: expected expression") -DIAG(err_objc_no_attributes_on_category, ERROR, - "attributes may not be specified on a category") -DIAG(err_objc_missing_end, ERROR, - "missing @end") -DIAG(warn_objc_protocol_qualifier_missing_id, WARNING, - "protocol qualifiers without 'id' is archaic") -DIAG(warn_objc_array_of_interfaces, WARNING, - "array of interface %0 should probably be an array of pointers") - -DIAG(err_invalid_receiver_to_message, ERROR, - "invalid receiver to message expression") -DIAG(err_objc_illegal_visibility_spec, ERROR, - "illegal visibility specification") -DIAG(err_objc_illegal_interface_qual, ERROR, - "illegal interface qualifier") -DIAG(err_objc_expected_equal, ERROR, - "setter/getter expects '=' followed by name") -DIAG(err_objc_property_requires_field_name, ERROR, - "property requires fields to be named") -DIAG(err_objc_property_bitfield, ERROR, - "property name cannot be a bitfield") -DIAG(err_objc_expected_property_attr, ERROR, - "unknown property attribute %0") -DIAG(err_objc_propertoes_require_objc2, ERROR, - "properties are an Objective-C 2 feature") -DIAG(err_objc_unexpected_attr, ERROR, - "prefix attribute must be followed by an interface or protocol") -DIAG(err_objc_property_attr_mutually_exclusive, ERROR, - "property attributes '%0' and '%1' are mutually exclusive") -DIAG(warn_objc_property_attr_mutually_exclusive, WARNING, - "property attributes '%0' and '%1' are mutually exclusive") -DIAG(warn_objc_property_no_assignment_attribute, WARNING, - "no 'assign', 'retain', or 'copy' attribute is specified - 'assign' is assumed") -DIAG(warn_objc_property_default_assign_on_object, WARNING, - "default property attribute 'assign' not appropriate for non-gc object") -DIAG(err_objc_property_requires_object, ERROR, - "property with '%0' attribute must be of object type") -DIAG(err_property_type, ERROR, - "property cannot have array or function type %0") -DIAG(err_property_not_found, ERROR, - "property %0 not found on object of type %1") -DIAG(err_objc_directive_only_in_protocol, ERROR, - "directive may only be specified in protocols only") -DIAG(err_missing_catch_finally, ERROR, - "@try statement without a @catch and @finally clause") -DIAG(err_objc_concat_string, ERROR, - "unexpected token after Objective-C string") -DIAG(err_undef_superclass, ERROR, - "cannot find interface declaration for %0, superclass of %1") -DIAG(err_duplicate_class_def, ERROR, - "duplicate interface definition for class %0") -DIAG(warn_undef_protocolref, WARNING, - "cannot find protocol definition for %0") -DIAG(err_duplicate_protocol_def, ERROR, - "duplicate protocol definition of %0") -DIAG(err_undef_interface, ERROR, - "cannot find interface declaration for %0") -DIAG(warn_dup_category_def, WARNING, - "duplicate definition of category %1 on interface %0") -DIAG(warn_undef_interface, WARNING, - "cannot find interface declaration for %0") -DIAG(err_dup_implementation_class, ERROR, - "reimplementation of class %0") -DIAG(err_conflicting_super_class, ERROR, - "conflicting super class name %0") -DIAG(err_conflicting_ivar_name, ERROR, - "conflicting instance variable names: %0 vs %1") -DIAG(err_inconsistant_ivar_count, ERROR, - "inconsistent number of instance variables specified") -DIAG(err_conflicting_ivar_type, ERROR, - "instance variable %0 has conflicting type: %1 vs %2") -DIAG(warn_undef_method_impl, WARNING, - "method definition for %0 not found") -DIAG(warn_incomplete_impl, WARNING, - "incomplete implementation") -DIAG(warn_multiple_method_decl, WARNING, - "multiple methods named %0 found") -DIAG(err_duplicate_method_decl, ERROR, - "duplicate declaration of method %0") -DIAG(err_undeclared_protocol, ERROR, - "cannot find protocol declaration for %0") -DIAG(err_missing_sel_definition, ERROR, - "cannot find definition of 'SEL'") -DIAG(err_missing_id_definition, ERROR, - "cannot find definition of 'id'") -DIAG(err_missing_proto_definition, ERROR, - "cannot find definition of 'Protocol'") -DIAG(err_missing_class_definition, ERROR, - "cannot find definition of 'Class'") -DIAG(warn_previous_alias_decl, WARNING, - "previously declared alias is ignored") -DIAG(err_conflicting_aliasing_type, ERROR, - "conflicting types for alias %0") -DIAG(err_statically_allocated_object, ERROR, - "statically allocated Objective-C object %0") -DIAG(warn_class_method_not_found, WARNING, - "method %objcclass0 not found (return type defaults to 'id')") -DIAG(warn_inst_method_not_found, WARNING, - "method %objcinstance0 not found (return type defaults to 'id')") -DIAG(warn_method_not_found_in_protocol, WARNING, - "method %objcinstance0 not found in protocol (return type defaults to 'id')") -DIAG(err_collection_expr_type, ERROR, |