[cfe-commits] r63111 - in /cfe/trunk: Driver/ include/clang/Basic/ lib/AST/ lib/Analysis/ lib/Basic/ lib/Lex/ lib/Parse/ lib/Sema/

Chris Lattner sabre at nondot.org
Tue Jan 27 10:30:59 PST 2009


Author: lattner
Date: Tue Jan 27 12:30:58 2009
New Revision: 63111

URL: http://llvm.org/viewvc/llvm-project?rev=63111&view=rev
Log:
Split the single monolithic DiagnosticKinds.def file into one
.def file for each library.  This means that adding a diagnostic
to sema doesn't require all the other libraries to be rebuilt.

Patch by Anders Johnsen!

Modified:
    cfe/trunk/Driver/clang.cpp
    cfe/trunk/include/clang/Basic/Diagnostic.h
    cfe/trunk/include/clang/Basic/DiagnosticKinds.def
    cfe/trunk/lib/AST/ExprConstant.cpp
    cfe/trunk/lib/Analysis/UninitializedValues.cpp
    cfe/trunk/lib/Basic/Diagnostic.cpp
    cfe/trunk/lib/Lex/Lexer.cpp
    cfe/trunk/lib/Lex/LiteralSupport.cpp
    cfe/trunk/lib/Lex/MacroArgs.cpp
    cfe/trunk/lib/Lex/PPDirectives.cpp
    cfe/trunk/lib/Lex/PPExpressions.cpp
    cfe/trunk/lib/Lex/PPLexerChange.cpp
    cfe/trunk/lib/Lex/PPMacroExpansion.cpp
    cfe/trunk/lib/Lex/Pragma.cpp
    cfe/trunk/lib/Lex/Preprocessor.cpp
    cfe/trunk/lib/Lex/PreprocessorLexer.cpp
    cfe/trunk/lib/Lex/TokenLexer.cpp
    cfe/trunk/lib/Parse/DeclSpec.cpp
    cfe/trunk/lib/Parse/ExtensionRAIIObject.h
    cfe/trunk/lib/Parse/ParseCXXInlineMethods.cpp
    cfe/trunk/lib/Parse/ParseDecl.cpp
    cfe/trunk/lib/Parse/ParseDeclCXX.cpp
    cfe/trunk/lib/Parse/ParseExprCXX.cpp
    cfe/trunk/lib/Parse/ParseInit.cpp
    cfe/trunk/lib/Parse/ParseObjc.cpp
    cfe/trunk/lib/Parse/ParsePragma.cpp
    cfe/trunk/lib/Parse/ParseTemplate.cpp
    cfe/trunk/lib/Parse/ParseTentative.cpp
    cfe/trunk/lib/Parse/Parser.cpp
    cfe/trunk/lib/Sema/Sema.cpp
    cfe/trunk/lib/Sema/Sema.h
    cfe/trunk/lib/Sema/SemaCXXScopeSpec.cpp
    cfe/trunk/lib/Sema/SemaChecking.cpp
    cfe/trunk/lib/Sema/SemaDecl.cpp
    cfe/trunk/lib/Sema/SemaDeclAttr.cpp
    cfe/trunk/lib/Sema/SemaDeclCXX.cpp
    cfe/trunk/lib/Sema/SemaDeclObjC.cpp
    cfe/trunk/lib/Sema/SemaExpr.cpp
    cfe/trunk/lib/Sema/SemaExprCXX.cpp
    cfe/trunk/lib/Sema/SemaExprObjC.cpp
    cfe/trunk/lib/Sema/SemaInherit.cpp
    cfe/trunk/lib/Sema/SemaInit.cpp
    cfe/trunk/lib/Sema/SemaNamedCast.cpp
    cfe/trunk/lib/Sema/SemaStmt.cpp
    cfe/trunk/lib/Sema/SemaType.cpp

Modified: cfe/trunk/Driver/clang.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Driver/clang.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/Driver/clang.cpp (original)
+++ cfe/trunk/Driver/clang.cpp Tue Jan 27 12:30:58 2009
@@ -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"

Modified: cfe/trunk/include/clang/Basic/Diagnostic.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/Diagnostic.h?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/include/clang/Basic/Diagnostic.h (original)
+++ cfe/trunk/include/clang/Basic/Diagnostic.h Tue Jan 27 12:30:58 2009
@@ -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 @@
     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 @@
 
   /// 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 @@
   /// 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];

Modified: cfe/trunk/include/clang/Basic/DiagnosticKinds.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticKinds.def?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/include/clang/Basic/DiagnosticKinds.def (original)
+++ cfe/trunk/include/clang/Basic/DiagnosticKinds.def Tue Jan 27 12:30:58 2009
@@ -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,
-     "collection expression type %0 is not a valid object")
-DIAG(err_selector_element_type, ERROR,
-     "selector element type %0 is not a valid object")
-DIAG(err_selector_element_not_lvalue, ERROR,
-    "selector element is not a valid lvalue") 
-DIAG(err_toomany_element_decls, ERROR,
-     "Only one element declaration is allowed")
-DIAG(warn_expected_implementation, WARNING,
-     "@end must appear in an @implementation context")
-DIAG(error_missing_method_context, ERROR,
-     "missing context for method declaration")
-DIAG(error_bad_receiver_type, ERROR,
-     "bad receiver type %0")
-DIAG(error_no_super_class, ERROR,
-     "no super class declared in @interface for %0")
-DIAG(error_no_super_class_message, ERROR,
-     "no @interface declaration found in class messaging of %0")
-DIAG(error_missing_property_context, ERROR,
-     "missing context for property implementation declaration")
-DIAG(error_bad_property_context, ERROR,
-     "property implementation must be in a class or category implementation")
-DIAG(error_bad_property_decl, ERROR,
-     "property implementation must have its declaration in interface %0")
-DIAG(error_bad_category_property_decl, ERROR,
-     "property implementation must have its declaration in the category %0")
-DIAG(error_property_ivar_decl, ERROR,
-     "property synthesize requires specification of an ivar")
-DIAG(error_dynamic_property_ivar_decl, ERROR,
-     "dynamic property can not have ivar specification")
-DIAG(error_missing_property_interface, ERROR,
-     "property implementation in a category with no category declaration")
-DIAG(error_missing_property_ivar_decl, ERROR,
-     "synthesized property %0 must either be named the same as a compatible"
-     " ivar or must explicitly name an ivar")
-DIAG(error_synthesize_category_decl, ERROR,
-     "@synthesize not allowed in a category's implementation")
-DIAG(error_property_ivar_type, ERROR,
-     "type of property %0 does not match type of ivar %1") 
-DIAG(error_readonly_property_assignment, ERROR,
-     "assigning to property with 'readonly' attribute not allowed")
-DIAG(error_nosetter_property_assignment, ERROR,
-     "setter method is needed to assign to object using property"
-     " assignment syntax")
-DIAG(warn_readonly_property, WARNING,
-     "attribute 'readonly' of property %0 restricts attribute "
-     "'readwrite' of property inherited from %1")
-DIAG(warn_property_attribute, WARNING,
-     "property %0 '%1' attribute does not match the property inherited from %2")
-DIAG(warn_property_type, WARNING,
-     "property type %0 does not match property type inherited from %1")
-DIAG(err_continuation_class, ERROR,
-     "continuation class has no primary class")
-DIAG(err_use_continuation_class, ERROR,
-     "attribute of property in continuation class of %0 can only  be 'readwrite'")
-DIAG(warn_property_attr_mismatch, WARNING,
-     "property attribute in continuation class does not match the primary class")
-DIAG(err_accessor_property_type_mismatch, ERROR,
-     "type of property %0 does not match type of accessor %1")
-DIAG(note_declared_at, NOTE,
-     "declared at")
-DIAG(err_setter_type_void, ERROR,
-     "type of setter must be void")
-DIAG(warn_conflicting_types, WARNING,
-     "conflicting types for %0")
-DIAG(error_property_implemented, ERROR,
-     "property %0 is already implemented")
-DIAG(error_duplicate_ivar_use, ERROR,
-     "synthesized properties %0 and %1 both claim ivar %2")
-
-/// C++ parser diagnostics
-DIAG(err_expected_unqualified_id, ERROR,
-     "expected unqualified-id")
-DIAG(err_no_declarators, ERROR,
-     "declaration does not declare anything")
-DIAG(ext_typedef_without_a_name, EXTWARN,
-     "typedef requires a name")
-DIAG(err_func_def_no_params, ERROR,
-     "function definition does not declare parameters")
-DIAG(err_expected_lparen_after_type, ERROR,
-     "expected '(' for function-style cast or type construction")
-DIAG(err_expected_equal_after_declarator, ERROR,
-     "expected '=' after declarator")
-DIAG(warn_parens_disambiguated_as_function_decl, WARNING,
-     "parentheses were disambiguated as a function declarator")
-DIAG(err_expected_member_or_base_name, ERROR,
-     "expected class member or base class name")
-DIAG(ext_ellipsis_exception_spec, EXTENSION,
-     "exception specification of '...' is a Microsoft extension")
-DIAG(err_expected_catch, ERROR,
-     "expected catch")
-
-/// C++ Templates
-DIAG(err_expected_template, ERROR,
-      "expected template")
-DIAG(err_expected_comma_greater, ERROR,
-      "expected ',' or '>' in template-parameter-list")
-DIAG(err_expected_type_id_after, ERROR,
-      "expected type-id after '%0'")
-DIAG(err_expected_class_before, ERROR,
-      "expected 'class' before '%0'")
-
-// Language specific pragmas
-
-// #pragma pack
-DIAG(warn_pragma_pack_expected_lparen, WARNING,
-     "missing '(' after '#pragma pack' - ignoring")
-DIAG(warn_pragma_pack_expected_rparen, WARNING,
-     "missing ')' after '#pragma pack' - ignoring")
-DIAG(warn_pragma_pack_invalid_action, WARNING,
-     "unknown action for '#pragma pack' - ignored")
-DIAG(warn_pragma_pack_invalid_constant, WARNING,
-     "invalid constant for '#pragma pack', expected %0 - ignored")
-DIAG(warn_pragma_pack_malformed, WARNING,
-     "expected integer or identifier in '#pragma pack' - ignored")
-// Follow the MSVC implementation.
-DIAG(warn_pragma_pack_show, WARNING,
-     "value of #pragma pack(show) == %0")
-// FIXME: Dehardcode.
-DIAG(warn_pragma_pack_invalid_alignment, WARNING,
-     "expected #pragma pack parameter to be '1', '2', '4', '8', or '16'")
-DIAG(warn_pragma_pack_pop_identifer_and_alignment, WARNING,
-     "specifying both a name and alignment to 'pop' is undefined")
-DIAG(warn_pragma_pack_pop_failed, WARNING,
-     "#pragma pack(pop, ...) failed: %0")
-
-//===----------------------------------------------------------------------===//
-// Semantic Analysis
-//===----------------------------------------------------------------------===//
-
-// Constant expressions
-DIAG(err_expr_not_ice, ERROR,
-     "expression is not an integer constant expression")
-DIAG(ext_expr_not_ice, EXTENSION,
-     "expression is not integer constant expression "
-     "(but is allowed as an extension)")
-DIAG(ext_null_pointer_expr_not_ice, EXTENSION,
-     "null pointer expression is not an integer constant expression "
-     "(but is allowed as an extension)")
-
-DIAG(note_comma_in_ice, NOTE,
-     "C does not permit evaluated commas in an integer constant expression")
-DIAG(note_invalid_subexpr_in_ice, NOTE,
-     "subexpression not valid in an integer constant expression")
-DIAG(note_expr_divide_by_zero, NOTE,
-    "division by zero")
-
-// Semantic analysis of string and character constant literals.
-DIAG(ext_nonstandard_escape, EXTENSION,
-     "use of non-standard escape character '\\%0'")
-DIAG(ext_unknown_escape, EXTENSION,
-     "unknown escape sequence '\\%0'")
-DIAG(warn_extraneous_wide_char_constant, WARNING,
-     "extraneous characters in wide character constant ignored")
-DIAG(warn_char_constant_too_large, WARNING,
-     "character constant too long for its type")
-DIAG(warn_hex_escape_too_large, WARNING,
-     "hex escape sequence out of range")
-DIAG(warn_octal_escape_too_large, WARNING,
-     "octal escape sequence out of range")
-
-DIAG(err_hex_escape_no_digits, ERROR,
-     "\\x used with no following hex digits")
-     
-DIAG(ext_predef_outside_function, WARNING,
-     "predefined identifier is only valid inside function")
-
-// C99 Designated Initializers
-DIAG(err_array_designator_nonconstant, ERROR,
-     "array designator value must be a constant expression")
-DIAG(err_array_designator_negative, ERROR,
-     "array designator value '%0' is negative")
-DIAG(err_array_designator_empty_range, ERROR,
-     "array designator range [%0, %1] is empty")
-DIAG(err_array_designator_non_array, ERROR,
-     "array designator cannot initialize non-array type %0")
-DIAG(err_array_designator_too_large, ERROR,
-     "array designator index (%0) exceeds array bounds (%1)")
-DIAG(err_field_designator_non_aggr, ERROR,
-     "field designator cannot initialize a %select{non-struct, non-union|non-class}0 type %1")
-DIAG(err_field_designator_unknown, ERROR,
-     "field designator %0 does not refer to any field in type %1")
-DIAG(err_field_designator_nonfield, ERROR,
-     "field designator %0 does not refer to a non-static data member")
-DIAG(note_field_designator_found, NOTE,
-     "field designator refers here")
-DIAG(err_designator_for_scalar_init, ERROR,
-     "designator in initializer for scalar type %0")
-
-// Declarations.
-DIAG(err_typename_requires_specqual, ERROR,
-     "type name requires a specifier or qualifier")
-DIAG(err_typename_invalid_storageclass, ERROR,
-     "type name does not allow storage class to be specified")
-DIAG(err_typename_invalid_functionspec, ERROR,
-     "type name does not allow function specifier to be specified")
-DIAG(err_invalid_decl_spec_combination, ERROR,
-     "cannot combine with previous '%0' declaration specifier")
-DIAG(err_invalid_sign_spec, ERROR,
-     "'%0' cannot be signed or unsigned")
-DIAG(ext_invalid_sign_spec, EXTENSION,
-     "'%0' cannot be signed or unsigned")
-DIAG(err_invalid_short_spec, ERROR,
-     "'short %0' is invalid")
-DIAG(err_invalid_long_spec, ERROR,
-     "'long %0' is invalid")
-DIAG(err_invalid_longlong_spec, ERROR,
-     "'long long %0' is invalid")
-DIAG(ext_longlong, EXTENSION,
-     "'long long' is an extension when C99 mode is not enabled")
-DIAG(err_invalid_complex_spec, ERROR,
-     "'_Complex %0' is invalid")
-DIAG(err_invalid_thread_spec, ERROR,
-     "'__thread %0' is invalid")
-DIAG(err_ellipsis_first_arg, ERROR,
-     "ISO C requires a named argument before '...'")
-DIAG(err_unspecified_vla_size_with_static, ERROR,
-     "'static' may not be used with an unspecified variable length array size")
-DIAG(ext_vla, EXTENSION,
-     "variable length arrays are a C99 feature, accepted as an extension")
-DIAG(err_invalid_storage_class_in_func_decl, ERROR,
-     "invalid storage class specifier in function declarator")
-DIAG(ext_anon_param_requires_type_specifier, EXTENSION,
-     "type specifier required for unnamed parameter, defaults to int")
-DIAG(err_missing_param, ERROR,
-     "expected parameter declarator")
-DIAG(err_bad_variable_name, ERROR,
-     "'%0' cannot be the name of a variable or data member")
-DIAG(err_parameter_name_omitted, ERROR,
-     "parameter name omitted")
-DIAG(warn_decl_in_param_list, WARNING,
-     "declaration of %0 will not be visible outside of this function")
-
-DIAG(err_declarator_need_ident, ERROR,
-     "declarator requires an identifier")
-DIAG(err_bad_language, ERROR,
-     "unknown linkage language")
-
-// C++ class members
-DIAG(err_storageclass_invalid_for_member, ERROR,
-     "storage class specified for a member declaration")
-DIAG(err_mutable_function, ERROR,
-     "'mutable' cannot be applied to functions")
-DIAG(err_mutable_reference, ERROR,
-     "'mutable' cannot be applied to references")
-DIAG(err_mutable_const, ERROR,
-     "'mutable' and 'const' cannot be mixed")
-DIAG(err_mutable_nonmember, ERROR,
-     "'mutable' can only be applied to member variables")
-DIAG(err_virtual_non_function, ERROR,
-     "'virtual' can only appear on non-static member functions")
-DIAG(err_not_bitfield_type, ERROR,
-     "cannot declare %0 to be a bit-field type")
-DIAG(err_static_not_bitfield, ERROR,
-     "static member %0 cannot be a bit-field")
-DIAG(err_not_integral_type_bitfield, ERROR,
-     "bit-field %0 with non-integral type")
-DIAG(err_member_initialization, ERROR,
-    "%0 can only be initialized if it is a static const integral data member")
-DIAG(err_member_function_initialization, ERROR,
-    "initializer on function does not look like a pure-specifier")
-DIAG(err_non_virtual_pure, ERROR,
-    "%0 is not virtual and cannot be declared pure")
-DIAG(err_implicit_object_parameter_init, ERROR,
-     "cannot initialize object parameter of type %0 with an expression of type %1")
-
-// C++ constructors
-DIAG(err_constructor_cannot_be, ERROR,
-     "constructor cannot be declared '%0'")
-DIAG(err_invalid_qualified_constructor, ERROR,
-     "'%0' qualifier is not allowed on a constructor")
-DIAG(err_constructor_return_type, ERROR,
-     "constructor cannot have a return type")
-DIAG(err_constructor_redeclared, ERROR,
-     "constructor cannot be redeclared")
-DIAG(err_constructor_byvalue_arg, ERROR,
-     "copy constructor must pass its first argument by reference")
-
-// C++ destructors
-DIAG(err_destructor_not_member, ERROR,
-     "destructor must be a non-static member function")
-DIAG(err_destructor_cannot_be, ERROR,
-     "destructor cannot be declared '%0'")
-DIAG(err_invalid_qualified_destructor, ERROR,
-     "'%0' qualifier is not allowed on a destructor")
-DIAG(err_destructor_return_type, ERROR,
-     "destructor cannot have a return type")
-DIAG(err_destructor_redeclared, ERROR,
-     "destructor cannot be redeclared")
-DIAG(err_destructor_with_params, ERROR,
-     "destructor cannot have any parameters")
-DIAG(err_destructor_variadic, ERROR,
-     "destructor cannot be variadic")
-DIAG(err_destructor_typedef_name, ERROR,
-     "destructor cannot be declared using a typedef %0 of the class name")
-
-// C++ initialization
-// FIXME: passing in an English string as %1!
-DIAG(err_not_reference_to_const_init, ERROR,
-     "non-const reference to type %0 cannot be initialized with a %1 of type %2")
-// FIXME: passing in an English string as %1!
-DIAG(err_reference_init_drops_quals, ERROR,
-     "initialization of reference to type %0 with a %1 of type %2 drops qualifiers")
-DIAG(err_reference_var_requires_init, ERROR,
-     "declaration of reference variable %0 requires an initializer")
-DIAG(err_const_var_requires_init, ERROR,
-     "declaration of const variable '%0' requires an initializer")
-DIAG(err_init_non_aggr_init_list, ERROR,
-     "initialization of non-aggregate type %0 with an initializer list")
-
-// Objective-C++
-DIAG(err_objc_decls_may_only_appear_in_global_scope, ERROR,
-     "Objective-C declarations may only appear in global scope")
-
-// Attributes
-DIAG(err_attribute_can_be_applied_only_to_symbol_declaration, ERROR,
-     "%0 attribute can be applied only to symbol declaration")
-DIAG(err_attributes_are_not_compatible, ERROR,
-     "%0 and %1 attributes are not compatible")
-DIAG(err_attribute_wrong_number_arguments, ERROR,
-     "attribute requires %0 argument(s)")
-DIAG(err_attribute_missing_parameter_name, ERROR,
-     "attribute requires unquoted parameter")
-DIAG(err_attribute_invalid_vector_type, ERROR,
-     "invalid vector type %0")
-DIAG(err_attribute_argument_not_int, ERROR,
-     "'%0' attribute requires integer constant")
-DIAG(err_attribute_argument_n_not_int, ERROR,
-     "'%0' attribute requires parameter %1 to be an integer constant")
-DIAG(err_attribute_argument_n_not_string, ERROR,
-     "'%0' attribute requires parameter %1 to be a string")
-DIAG(err_attribute_argument_out_of_bounds, ERROR,
-     "'%0' attribute parameter %1 is out of bounds")
-DIAG(err_nonnull_pointers_only, ERROR,
-    "nonnull attribute only applies to pointer arguments")
-DIAG(err_format_strftime_third_parameter, ERROR,
-     "strftime format attribute requires 3rd parameter to be 0")
-DIAG(err_format_attribute_requires_variadic, ERROR,
-     "format attribute requires variadic function")
-DIAG(err_format_attribute_not, ERROR,
-     "format argument not %0")
-DIAG(err_attribute_invalid_size, ERROR,
-     "vector size not an integral multiple of component size")
-DIAG(err_attribute_zero_size, ERROR,
-     "zero vector size")
-DIAG(err_typecheck_vector_not_convertable, ERROR,
-     "can't convert between vector values of different size (%0 and %1)")
-DIAG(err_typecheck_ext_vector_not_typedef, ERROR,
-     "ext_vector_type only applies to types, not variables")
-DIAG(err_ext_vector_component_exceeds_length, ERROR,
-     "vector component access exceeds type %0")
-DIAG(err_ext_vector_component_requires_even, ERROR,
-     "vector component access invalid for odd-sized type %0")
-DIAG(err_ext_vector_component_name_illegal, ERROR,
-     "illegal vector component name '%0'")
-DIAG(err_attribute_address_space_not_int, ERROR,
-     "address space attribute requires an integer constant")
-DIAG(err_attribute_address_multiple_qualifiers, ERROR,
-     "multiple address spaces specified for type")
-DIAG(err_implicit_pointer_address_space_cast, ERROR,
-     "illegal implicit cast between two pointers with different address spaces")
-DIAG(err_as_qualified_auto_decl, ERROR,
-     "automatic variable qualified with an address space")
-DIAG(err_attribute_annotate_no_string, ERROR,
-     "argument to annotate attribute was not a string literal")
-DIAG(warn_redeclaration_without_attribute_prev_attribute_ignored, WARNING,
-  "'%0' redeclared without %1 attribute: previous %1 ignored")
-DIAG(warn_attribute_ignored, WARNING,
-     "%0 attribute ignored")
-DIAG(warn_attribute_weak_on_field, WARNING,
-     "__weak attribute cannot be specified on a field declaration")
-DIAG(warn_attribute_wrong_decl_type, WARNING,
-     "'%0' attribute only applies to %1 types")
-DIAG(warn_attribute_ignored_for_field_of_type, WARNING,
-     "%0 attribute ignored for field of type %1")
-DIAG(warn_attribute_type_not_supported, WARNING,
-     "'%0' attribute argument not supported: %1")
-DIAG(warn_attribute_unknown_visibility, WARNING,
-     "unknown visibility '%1'")
-DIAG(err_unknown_machine_mode, ERROR,
-     "unknown machine mode %0")
-DIAG(err_unsupported_machine_mode, ERROR,
-     "unsupported machine mode %0")
-DIAG(err_mode_not_primitive, ERROR,
-     "mode attribute only supported for integer and floating-point types")
-DIAG(err_mode_wrong_type, ERROR,
-     "type of machine mode does not match type of base type")
-DIAG(err_attr_wrong_decl, ERROR,
-     "'%0' attribute invalid on this declaration, requires typedef or value")
-DIAG(warn_attribute_nonnull_no_pointers, WARNING,
-     "'nonnull' attribute applied to function with no pointer arguments")
-DIAG(warn_transparent_union_nonpointer, WARNING,
-     "'transparent_union' attribute support incomplete; only supported for"
-     "pointer unions")
-DIAG(warn_attribute_sentinel_not_variadic, WARNING,
-     "'sentinel' attribute only supported for variadic functions")
-DIAG(err_attribute_sentinel_less_than_zero, ERROR,
-     "'sentinel' parameter 1 less than zero")
-DIAG(err_attribute_sentinel_not_zero_or_one, ERROR,
-     "'sentinel' parameter 2 not 0 or 1")
-  
-// Clang-Specific Attributes
-DIAG(err_attribute_iboutlet_non_ivar, ERROR,
-     "'iboutlet' attribute can only be applied to instance variables")
-
-// Function Parameter Semantic Analysis.
-DIAG(err_argument_required_after_attribute, ERROR,
-     "argument required after attribute")
-DIAG(err_param_with_void_type, ERROR,
-     "argument may not have 'void' type")
-DIAG(err_void_only_param, ERROR,
-     "'void' must be the first and only parameter if specified")
-DIAG(err_void_param_qualified, ERROR,
-     "'void' as parameter must not have type qualifiers")
-DIAG(err_param_redefinition, ERROR,
-     "redefinition of parameter %0")
-DIAG(err_ident_list_in_fn_declaration, ERROR,
-     "a parameter list without types is only allowed in a function definition")
-DIAG(err_declaration_does_not_declare_param, ERROR,
-     "declaration does not declare a parameter")
-DIAG(err_no_matching_param, ERROR,
-     "parameter named %0 is missing")
-DIAG(ext_param_not_declared, EXTENSION,
-     "parameter %0 was not declared, defaulting to type 'int'")
-DIAG(ext_param_typedef_of_void, EXTENSION,
-     "empty parameter list defined with a typedef of 'void' not allowed in C++")
-DIAG(err_param_default_argument, ERROR,
-     "C does not support default arguments")
-DIAG(err_param_default_argument_redefinition, ERROR,
-     "redefinition of default argument")
-DIAG(err_param_default_argument_missing, ERROR,
-     "missing default argument on parameter")
-DIAG(err_param_default_argument_missing_name, ERROR,
-     "missing default argument on parameter %0")
-DIAG(err_param_default_argument_references_param, ERROR,
-     "default argument references parameter %0")
-DIAG(err_param_default_argument_references_local, ERROR,
-     "default argument references local variable %0 of enclosing function")
-DIAG(err_param_default_argument_references_this, ERROR,
-     "default argument references 'this'")
-DIAG(err_param_default_argument_nonfunc, ERROR,
-     "default arguments can only be specified for parameters in a function"
-     " declaration")
-
-// C++ Overloading Semantic Analysis.
-DIAG(err_ovl_diff_return_type, ERROR,
-     "functions that differ only in their return type cannot be overloaded")
-DIAG(err_ovl_static_nonstatic_member, ERROR,
-     "static and non-static member functions with the same parameter types "
-     "cannot be overloaded")
-DIAG(err_ovl_no_viable_function_in_call, ERROR,
-     "no matching function for call to %0"
-     "%plural{0:|1:; candidate is|:; candidates are:}1")
-DIAG(err_ovl_no_viable_member_function_in_call, ERROR,
-     "no matching member function for call to %0"
-     "%plural{0:|1:; candidate is|:; candidates are:}1")
-DIAG(err_ovl_ambiguous_call, ERROR,
-     "call to %0 is ambiguous; candidates are:")
-DIAG(err_ovl_ambiguous_member_call, ERROR,
-     "call to member function %0 is ambiguous; candidates are:")
-DIAG(err_ovl_candidate, NOTE,
-     "candidate function")
-DIAG(err_ovl_builtin_candidate, NOTE,
-     "built-in candidate function %0")
-DIAG(err_ovl_no_viable_function_in_init, ERROR,
-     "no matching constructor for initialization of %0"
-     "%plural{0:|1:; candidate is|:; candidates are:}1")
-DIAG(err_ovl_ambiguous_init, ERROR,
-     "call to constructor of %0 is ambiguous; candidates are:")
-DIAG(err_ovl_ambiguous_oper, ERROR,
-     "use of overloaded operator '%0' is ambiguous; candidates are:")
-DIAG(err_ovl_no_viable_oper, ERROR,
-     "no viable overloaded '%0'; candidate%plural{1: is|:s are}1:")
-DIAG(err_ovl_no_viable_object_call, ERROR,
-     "no matching function for call to object of type %0"
-     "%plural{0:|1:; candidate is|:; candidates are:}1")
-DIAG(err_ovl_ambiguous_object_call, ERROR,
-     "call to object of type %0 is ambiguous; candidates are:")
-DIAG(err_ovl_surrogate_cand, NOTE,
-     "conversion candidate of type %0")
-DIAG(err_member_call_without_object, ERROR,
-     "call to non-static member function without an object argument")
-
-/// C++ Templates Semantic Analysis
-DIAG(err_template_param_shadow, ERROR,
-     "declaration of %0 shadows template parameter")
-DIAG(note_template_param_here, NOTE,
-     "template parameter is declared here")
-DIAG(note_template_export_unsupported, NOTE, 
-     "exported templates are unsupported")
-
-DIAG(err_unexpected_typedef, ERROR,
-     "unexpected type name %0: expected expression")
-DIAG(err_unexpected_namespace, ERROR,
-     "unexpected namespace name %0: expected expression")
-DIAG(err_unexpected_typedef_ident, ERROR,
-     "unexpected type name %0: expected identifier")
-DIAG(err_undeclared_var_use, ERROR,
-     "use of undeclared identifier %0")
-DIAG(err_undeclared_use, ERROR,
-     "use of undeclared '%0'")
-DIAG(warn_deprecated, WARNING,
-     "%0 is deprecated")
-DIAG(warn_unavailable, WARNING,
-     "%0 is unavailable")
-DIAG(err_redefinition, ERROR,
-     "redefinition of %0")
-DIAG(err_static_non_static, ERROR,
-     "static declaration of %0 follows non-static declaration")
-DIAG(err_non_static_static, ERROR,
-     "non-static declaration of %0 follows static declaration")
-DIAG(err_redefinition_different_type, ERROR,
-     "redefinition of %0 with a different type")
-DIAG(err_redefinition_different_kind, ERROR,
-     "redefinition of %0 as different kind of symbol")
-DIAG(err_redefinition_different_typedef, ERROR,
-     "typedef redefinition with different types (%0 vs %1)")
-DIAG(err_conflicting_types, ERROR,
-     "conflicting types for %0")
-DIAG(err_nested_redefinition, ERROR,
-     "nested redefinition of %0")
-DIAG(err_use_with_wrong_tag, ERROR,
-     "use of %0 with tag type that does not match previous declaration")
-DIAG(ext_forward_ref_enum, EXTENSION,
-     "ISO C forbids forward references to 'enum' types")
-DIAG(err_redefinition_of_enumerator, ERROR,
-     "redefinition of enumerator %0")
-DIAG(err_duplicate_member, ERROR,
-     "duplicate member %0")
-DIAG(ext_enum_value_not_int, EXTENSION,
-     "ISO C restricts enumerator values to range of 'int' (%0 is too large)")
-DIAG(warn_enum_too_large, WARNING,
-     "enumeration values exceed range of largest integer")
-DIAG(warn_illegal_constant_array_size, EXTENSION,
-     "size of static array must be an integer constant expression")
-DIAG(err_vla_decl_in_file_scope, ERROR,
-     "variable length array declaration not allowed at file scope")
-DIAG(err_vla_decl_has_static_storage, ERROR,
-     "variable length array declaration can not have 'static' storage duration")
-DIAG(err_vla_decl_has_extern_linkage, ERROR,
-     "variable length array declaration can not have 'extern' linkage")
-DIAG(err_vm_decl_in_file_scope, ERROR,
-     "variably modified type declaration not allowed at file scope")
-DIAG(err_vm_decl_has_extern_linkage, ERROR,
-     "variably modified type declaration can not have 'extern' linkage")
-DIAG(err_typecheck_field_variable_size, ERROR,
-     "fields must have a constant size")
-DIAG(err_typecheck_negative_array_size, ERROR,
-     "array size is negative")
-DIAG(warn_typecheck_function_qualifiers, WARNING,
-     "qualifier on function type %0 has unspecified behavior")
-DIAG(err_typecheck_invalid_restrict_not_pointer, ERROR,
-     "restrict requires a pointer or reference (%0 is invalid)")
-DIAG(err_typecheck_invalid_restrict_invalid_pointee, ERROR,
-     "pointer to function type %0 may not be 'restrict' qualified")
-DIAG(ext_typecheck_zero_array_size, EXTENSION,
-     "zero size arrays are an extension")
-DIAG(err_at_least_one_initializer_needed_to_size_array, ERROR,
-    "at least one initializer value required to size array")
-DIAG(err_array_size_non_int, ERROR,
-     "size of array has non-integer type %0")
-DIAG(err_init_element_not_constant, ERROR,
-     "initializer element is not a compile-time constant")
-DIAG(err_block_extern_cant_init, ERROR,
-     "'extern' variable cannot have an initializer")
-DIAG(warn_extern_init, WARNING,
-     "'extern' variable has an initializer")
-DIAG(err_variable_object_no_init, ERROR,
-     "variable-sized object may not be initialized")
-DIAG(err_array_init_list_required, ERROR,
-     "initialization with '{...}' expected for array")
-DIAG(warn_excess_initializers, WARNING,
-     "excess elements in array initializer")
-DIAG(err_excess_initializers_in_char_array_initializer, ERROR,
-    "excess elements in char array initializer")
-DIAG(warn_initializer_string_for_char_array_too_long, WARNING,
-    "initializer-string for char array is too long")
-DIAG(warn_braces_around_scalar_init, WARNING,
-     "braces around scalar initializer")
-DIAG(err_many_braces_around_scalar_init, ERROR,
-     "too many braces around scalar initializer")
-DIAG(err_empty_scalar_initializer, ERROR,
-     "scalar initializer cannot be empty")
-DIAG(err_illegal_initializer, ERROR,
-     "illegal initializer (only variables can be initialized)")
-DIAG(err_illegal_initializer_type, ERROR,
-     "illegal initializer type %0")
-DIAG(err_implicit_empty_initializer, ERROR,
-     "initializer for aggregate with no elements requires explicit braces")
-DIAG(err_bitfield_has_negative_width, ERROR,
-     "bit-field %0 has negative width")
-DIAG(err_bitfield_has_zero_width, ERROR,
-     "bit-field %0 has zero width")
-DIAG(err_bitfield_width_exceeds_type_size, ERROR,
-     "size of bit-field %0 exceeds size of its type (%1 bits)")
-
-DIAG(err_redefinition_of_label, ERROR,
-     "redefinition of label '%0'")
-DIAG(err_undeclared_label_use, ERROR,
-     "use of undeclared label '%0'")
-
-DIAG(warn_implicit_function_decl, WARNING,
-     "implicit declaration of function %0")
-DIAG(ext_implicit_function_decl, EXTENSION,
-     "implicit declaration of function %0 is invalid in C99")
-
-DIAG(err_func_returning_array_function, ERROR,
-     "function cannot return array or function type %0")
-DIAG(err_field_declared_as_function, ERROR,
-     "field %0 declared as a function")
-DIAG(err_field_incomplete, ERROR,
-     "field has incomplete type %0")
-DIAG(err_variable_sized_type_in_struct, EXTENSION,
-     "variable sized type %0 must be at end of struct or class")
-DIAG(err_flexible_array_empty_struct, ERROR,
-     "flexible array %0 not allowed in otherwise empty struct")
-DIAG(ext_flexible_array_in_struct, EXTENSION,
-     "%0 may not be nested in a struct due to flexible array member")
-DIAG(err_flexible_array_in_array, ERROR,
-     "%0 may not be used as an array element due to flexible array member")
-DIAG(err_illegal_decl_array_of_functions, ERROR,
-     "'%0' declared as array of functions")
-DIAG(err_illegal_decl_array_incomplete_type, ERROR,
-     "array has incomplete element type %0")
-DIAG(err_illegal_decl_array_of_references, ERROR,
-     "'%0' declared as array of references")
-DIAG(err_illegal_decl_pointer_to_reference, ERROR,
-     "'%0' declared as a pointer to a reference")
-DIAG(err_illegal_decl_mempointer_to_void, ERROR,
-     "'%0' declared as a member pointer to void")
-DIAG(err_illegal_decl_mempointer_in_nonclass, ERROR,
-     "'%0' does not point into a class")
-DIAG(err_illegal_decl_reference_to_reference, ERROR,
-     "%0 declared as a reference to a reference")
-DIAG(err_invalid_reference_qualifier_application, ERROR,
-     "'%0' qualifier may not be applied to a reference")
-DIAG(err_reference_to_void, ERROR,
-     "cannot form a reference to 'void'")
-DIAG(err_qualified_block_pointer_type, ERROR,
-     "qualifier specification on block pointer type not allowed")
-DIAG(err_nonfunction_block_type, ERROR,
-     "block pointer to non-function type is invalid")
-DIAG(err_return_block_has_expr, ERROR,
-     "void block should not return a value")
-DIAG(err_block_return_missing_expr, ERROR,
-     "non-void block should return a value")
-DIAG(err_block_with_return_type_requires_args, ERROR,
-     "block with explicit return type requires argument list")
-
-// Expressions.
-DIAG(ext_sizeof_function_type, EXTENSION,
-     "invalid application of 'sizeof' to a function type")
-DIAG(ext_sizeof_void_type, EXTENSION,
-     "invalid application of '%0' to a void type")
-// FIXME: merge with %select
-DIAG(err_sizeof_incomplete_type, ERROR,
-     "invalid application of 'sizeof' to an incomplete type %0")
-DIAG(err_alignof_incomplete_type, ERROR,
-     "invalid application of '__alignof' to an incomplete type %0")
-DIAG(err_sizeof_alignof_bitfield, ERROR,
-     "invalid application of '%select{sizeof|__alignof}0' to bitfield")
-DIAG(err_offsetof_record_type, ERROR,
-     "offsetof requires struct, union, or class type, %0 invalid")
-DIAG(err_offsetof_array_type, ERROR,
-     "offsetof requires array type, %0 invalid")
-DIAG(ext_offsetof_extended_field_designator, EXTENSION,
-     "using extended field designator is an extension")
-DIAG(err_expected_field_designator, ERROR,
-     "expected a field designator, such as '.field = 4'")
-     
-DIAG(err_invalid_suffix_integer_constant, ERROR,
-     "invalid suffix '%0' on integer constant")
-DIAG(err_invalid_suffix_float_constant, ERROR,
-     "invalid suffix '%0' on floating constant")
-DIAG(ext_imaginary_constant, EXTENSION,
-     "imaginary constants are an extension")
-DIAG(warn_integer_too_large, WARNING,
-     "integer constant is too large for its type")
-DIAG(warn_integer_too_large_for_signed, WARNING,
-     "integer constant is so large that it is unsigned")
-DIAG(err_exponent_has_no_digits, ERROR,
-     "exponent has no digits")
-DIAG(ext_binary_literal, EXTENSION,
-     "binary integer literals are an extension")
-DIAG(err_invalid_binary_digit, ERROR,
-     "invalid digit '%0' in binary constant")
-DIAG(err_invalid_octal_digit, ERROR,
-     "invalid digit '%0' in octal constant")
-DIAG(err_invalid_decimal_digit, ERROR,
-     "invalid digit '%0' in decimal constant")
-DIAG(err_hexconstant_requires_exponent, ERROR,
-     "hexadecimal floating constants require an exponent")
-DIAG(ext_hexconstant_invalid, EXTENSION,
-     "hexadecimal floating constants are a C99 feature")
-DIAG(err_typecheck_subscript_value, ERROR,
-     "subscripted value is neither array nor pointer")
-DIAG(err_typecheck_subscript, ERROR,
-     "array subscript is not an integer")
-DIAG(err_typecheck_subscript_not_object, ERROR,
-     "illegal subscript of non-object type %0")
-DIAG(err_typecheck_member_reference_struct_union, ERROR,
-     "member reference base type %0 is not a structure or union")
-DIAG(err_typecheck_member_reference_ivar, ERROR,
-     "%0 does not have a member named %1")
-DIAG(err_typecheck_member_reference_arrow, ERROR,
-     "member reference type %0 is not a pointer")
-DIAG(err_typecheck_member_reference_type, ERROR,
-     "cannot refer to type member %0 with '%select{.|->}1'")
-DIAG(err_typecheck_member_reference_unknown, ERROR,
-     "cannot refer to member %0 with '%select{.|->}1'")
-DIAG(err_typecheck_incomplete_tag, ERROR,
-     "incomplete definition of type %0")
-DIAG(err_typecheck_no_member, ERROR,
-     "no member named %0")
-DIAG(err_member_redeclared, ERROR, 
-     "class member cannot be redeclared")
-DIAG(err_member_def_does_not_match, ERROR,
-     "out-of-line definition does not match any declaration in %0")
-DIAG(err_nonstatic_member_out_of_line, ERROR,
-     "non-static data member defined out-of-line")
-DIAG(err_qualified_typedef_declarator, ERROR,
-     "typedef declarator cannot be qualified")
-DIAG(err_qualified_param_declarator, ERROR,
-     "parameter declarator cannot be qualified")
-DIAG(err_out_of_line_declaration, ERROR,
-     "out-of-line declaration of a member must be a definition")
-DIAG(note_member_def_close_match, NOTE,
-     "member declaration nearly matches")
-DIAG(err_typecheck_ivar_variable_size, ERROR,
-     "instance variables must have a constant size")
-// FIXME: Improve with %select
-DIAG(err_typecheck_illegal_increment_decrement, ERROR,
-     "cannot modify value of type %0")
-DIAG(err_typecheck_arithmetic_incomplete_type, ERROR,
-     "arithmetic on pointer to incomplete type %0")
-DIAG(err_typecheck_pointer_arith_function_type, ERROR,
-     "arithmetic on pointer to function type %0")
-DIAG(err_typecheck_pointer_arith_void_type, ERROR,
-     "arithmetic on pointer to void type")
-DIAG(err_typecheck_decl_incomplete_type, ERROR,
-     "variable has incomplete type %0")
-// FIXME: Use %select
-DIAG(err_realimag_invalid_type, ERROR,
-     "invalid type %0 to __real or __imag operator")
-DIAG(err_typecheck_sclass_fscope, ERROR,
-     "illegal storage class on file-scoped variable")
-DIAG(err_typecheck_sclass_func, ERROR,
-     "illegal storage class on function")
-DIAG(err_typecheck_address_of, ERROR,
-     "address of %0 requested")
-DIAG(err_typecheck_invalid_lvalue_addrof, ERROR,
-     "address expression must be an lvalue or a function designator")
-DIAG(err_typecheck_unary_expr, ERROR,
-     "invalid argument type %0 to unary expression")
-DIAG(err_typecheck_indirection_requires_pointer, ERROR,
-     "indirection requires pointer operand (%0 invalid)")
-DIAG(err_typecheck_invalid_operands, ERROR,
-     "invalid operands to binary expression (%0 and %1)")
-DIAG(err_typecheck_sub_ptr_object, ERROR,
-     "subtraction of pointer %0 requires pointee to be a complete object type")
-DIAG(err_typecheck_sub_ptr_compatible, ERROR,
-     "%0 and %1 are not pointers to compatible types")
-DIAG(ext_typecheck_comparison_of_pointer_integer, WARNING,
-     "comparison between pointer and integer (%0 and %1)")
-DIAG(ext_typecheck_comparison_of_distinct_pointers, WARNING,
-     "comparison of distinct pointer types (%0 and %1)")
-DIAG(err_typecheck_assign_const, ERROR,
-     "read-only variable is not assignable")
-DIAG(err_stmtexpr_file_scope, ERROR,
-     "statement expression not allowed at file scope")
-
-DIAG(err_invalid_this_use, ERROR,
-     "invalid use of 'this' outside of a nonstatic member function")
-DIAG(err_invalid_member_use_in_static_method, ERROR,
-     "invalid use of member %0 in static member function")
-DIAG(err_invalid_qualified_function_type, ERROR,
-     "type qualifier is not allowed on this function")
-DIAG(err_invalid_qualified_typedef_function_type_use, ERROR,
-     "a qualified function type cannot be used to declare a nonmember function "
-     "or a static member function")
-DIAG(err_invalid_non_static_member_use, ERROR,
-     "invalid use of nonstatic data member %0")
-DIAG(err_invalid_incomplete_type_use, ERROR,
-     "invalid use of incomplete type %0")
-DIAG(err_builtin_func_cast_more_than_one_arg, ERROR,
-     "function-style cast to a builtin type can only take one argument")
-DIAG(err_builtin_direct_init_more_than_one_arg, ERROR,
-     "initializer of a builtin type can only take one argument")
-DIAG(err_value_init_for_array_type, ERROR,
-     "array types cannot be value-initialized")
-
-// C++ casts
-DIAG(err_bad_cxx_cast_generic, ERROR,
-     "%0 from %2 to %1 is not allowed")
-DIAG(err_bad_cxx_cast_rvalue, ERROR,
-     "%0 from rvalue to reference type %1")
-DIAG(err_bad_cxx_cast_const_away, ERROR,
-     "%0 from %2 to %1 casts away constness")
-DIAG(err_bad_const_cast_dest, ERROR,
-     "const_cast to %0, which is not a reference, pointer-to-object, "
-     "or pointer-to-data-member")
-DIAG(err_bad_reinterpret_cast_same_type, ERROR,
-     "source and destination type of reinterpret_cast are not distinct")
-DIAG(ext_reinterpret_cast_fn_obj, EXTENSION,
-     "reinterpret_cast between pointer-to-function and pointer-to-object is "
-     "an extension")
-DIAG(err_bad_reinterpret_cast_small_int, ERROR,
-     "cast from pointer to smaller type %0 loses information")
-DIAG(err_bad_dynamic_cast_not_ref_or_ptr, ERROR,
-     "%0 is not a reference or pointer")
-DIAG(err_bad_dynamic_cast_not_class, ERROR,
-     "%0 is not a class")
-DIAG(err_bad_dynamic_cast_incomplete, ERROR,
-     "%0 is an incomplete type")
-DIAG(err_bad_dynamic_cast_not_ptr, ERROR,
-     "%0 is not a pointer")
-DIAG(err_bad_dynamic_cast_not_polymorphic, ERROR,
-     "%0 is not polymorphic")
-// FIXME: Display the path somehow better.
-DIAG(err_ambiguous_base_to_derived_cast, ERROR,
-     "ambiguous static_cast from base %0 to derived %1:%2")
-DIAG(err_static_downcast_via_virtual, ERROR,
-     "cannot cast %0 to %1 via virtual base %2")
-
-// Other C++ expressions
-DIAG(err_need_header_before_typeid, ERROR,
-     "you need to include <typeinfo> before using the 'typeid' operator")
-DIAG(err_static_illegal_in_new, ERROR,
-     "the 'static' modifier for the array size is not legal in new expressions")
-DIAG(err_array_new_needs_size, ERROR,
-     "array size must be specified in new expressions")
-DIAG(err_bad_new_type, ERROR,
-    "cannot allocate %select{function|incomplete|reference}1 type %0 with new")
-DIAG(err_new_array_nonconst, ERROR,
-     "only the first dimension of an allocated array may be non-const")
-DIAG(err_array_size_not_integral, ERROR,
-     "array size expression must have integral or enumerated type, not %0")
-DIAG(err_new_uninitialized_const, ERROR,
-     "must provide an initializer if the allocated object is 'const'")
-DIAG(err_delete_operand, ERROR,
-     "cannot delete expression of type %0")
-DIAG(warn_delete_incomplete, WARNING,
-     "deleting pointer to incomplete type %0 may cause undefined behaviour")
-DIAG(err_decrement_bool, ERROR,
-     "cannot decrement expression of type bool")
-DIAG(warn_increment_bool, WARNING,
-     "incrementing expression of type bool is deprecated")
-DIAG(err_catch_incomplete_ptr, ERROR,
-     "cannot catch pointer to incomplete type %0")
-DIAG(err_catch_incomplete_ref, ERROR,
-     "cannot catch reference to incomplete type %0")
-DIAG(err_catch_incomplete, ERROR,
-     "cannot catch incomplete type %0")
-DIAG(err_qualified_catch_declarator, ERROR,
-     "exception declarator cannot be qualified")
-DIAG(err_early_catch_all, ERROR,
-     "catch-all handler must come last")
-
-DIAG(err_invalid_use_of_function_type, ERROR,
-     "a function type is not allowed here")
-DIAG(err_invalid_use_of_array_type, ERROR,
-     "an array type is not allowed here")
-DIAG(err_type_defined_in_condition, ERROR,
-     "types may not be defined in conditions")
-DIAG(err_typecheck_bool_condition, ERROR,
-     "value of type %0 is not contextually convertible to 'bool'")
-DIAG(err_expected_class_or_namespace, ERROR,
-     "expected a class or namespace")
-DIAG(err_invalid_declarator_scope, ERROR,
-     "definition or redeclaration of %0 not in a namespace enclosing %1")
-DIAG(err_invalid_declarator_in_function, ERROR,
-     "definition or redeclaration of %0 not allowed inside a function")
-DIAG(err_not_tag_in_scope, ERROR,
-     "%0 does not name a tag member in the specified scope")
-
-DIAG(warn_value_always_zero, WARNING,
-     "%0 is always zero in this context")
-DIAG(warn_value_always_false, WARNING,
-     "%0 is always false in this context")
-
-// assignment related diagnostics (also for argument passing, returning, etc).
-// FIXME: %2 is an english string here.
-DIAG(err_typecheck_convert_incompatible, ERROR,
-     "incompatible type %2 %1, expected %0")
-DIAG(err_cannot_initialize_decl_noname, ERROR,
-     "cannot initialize a value of type %0 with an %select{rvalue|lvalue}1 of type %2")
-DIAG(err_cannot_initialize_decl, ERROR,
-     "cannot initialize %0 with an %select{rvalue|lvalue}1 of type %2")
-DIAG(warn_incompatible_qualified_id, WARNING,
-     "incompatible type %2 %1, expected %0")
-DIAG(warn_incompatible_qualified_id_operands, WARNING,
-     "invalid operands to binary expression (%0 and %1)")
-DIAG(ext_typecheck_convert_pointer_int, EXTWARN,
-     "incompatible pointer to integer conversion %2 %1, expected %0")
-DIAG(ext_typecheck_convert_int_pointer, EXTWARN,
-     "incompatible integer to pointer conversion %2 %1, expected %0")
-DIAG(ext_typecheck_convert_pointer_void_func, EXTENSION,
-     "%2 %1 converts between void* and function pointer, expected %0")
-DIAG(ext_typecheck_convert_incompatible_pointer, EXTWARN,
-     "incompatible pointer types %2 %1, expected %0")
-DIAG(ext_typecheck_convert_discards_qualifiers, EXTWARN,
-     "%2 %1 discards qualifiers, expected %0")
-DIAG(err_int_to_block_pointer, ERROR,
-     "invalid conversion %2 integer %1, expected block pointer %0")
-DIAG(err_typecheck_comparison_of_distinct_blocks, ERROR,
-     "comparison of distinct block types (%0 and %1)")
-DIAG(ext_typecheck_convert_incompatible_block_pointer, EXTWARN,
-     "incompatible block pointer types %2 %1, expected %0")
-     
-DIAG(err_typecheck_array_not_modifiable_lvalue, ERROR,
-     "array type %0 is not assignable")
-DIAG(err_typecheck_non_object_not_modifiable_lvalue, ERROR,
-     "non-object type %0 is not assignable")
-DIAG(err_typecheck_expression_not_modifiable_lvalue, ERROR,
-     "expression is not assignable")
-DIAG(err_typecheck_incomplete_type_not_modifiable_lvalue, ERROR,
-     "incomplete type %0 is not assignable")
-DIAG(err_typecheck_lvalue_casts_not_supported, ERROR,
-     "assignment to cast is illegal, lvalue casts are not supported")
-
-DIAG(err_typecheck_duplicate_vector_components_not_mlvalue, ERROR,
-     "vector is not assignable (contains duplicate components)")
-DIAG(err_block_decl_ref_not_modifiable_lvalue, ERROR,
-     "variable is not assignable (missing __block type specifier)")
-DIAG(err_typecheck_call_not_function, ERROR,
-     "called object type %0 is not a function or function pointer")
-DIAG(err_typecheck_call_too_few_args, ERROR,
-     "too few arguments to %select{function|block|method}0 call")
-DIAG(err_typecheck_call_too_many_args, ERROR,
-     "too many arguments to %select{function|block|method}0 call")
-DIAG(warn_cannot_pass_non_pod_arg_to_vararg, WARNING,
-     "cannot pass object of non-POD type %0 through variadic "
-     "%select{function|block|method}1; call will abort at runtime")
-DIAG(err_typecheck_closure_too_many_args, ERROR,
-     "too many arguments to closure call")
-DIAG(err_typecheck_call_invalid_ordered_compare, ERROR,
-     "ordered compare requires two args of floating point type (%0 and %1)")
-DIAG(err_typecheck_cond_expect_scalar, ERROR,
-     "used type %0 where arithmetic or pointer type is required")
-DIAG(ext_typecheck_cond_one_void, EXTENSION,
-     "C99 forbids conditional expressions with only one void side")
-DIAG(ext_typecheck_cast_nonscalar, EXTENSION,
-     "C99 forbids casting nonscalar type %0 to the same type")
-DIAG(ext_typecheck_cast_to_union, EXTENSION,
-     "C99 forbids casts to union type")
-DIAG(err_typecheck_cast_to_union_no_type, ERROR,
-     "cast to union type from type %0 not present in union")
-DIAG(err_typecheck_expect_scalar_operand, ERROR,
-     "operand of type %0 where arithmetic or pointer type is required")
-DIAG(err_typecheck_cond_incompatible_operands, ERROR,
-     "incompatible operand types (%0 and %1)")
-DIAG(warn_typecheck_cond_incompatible_pointers, WARNING,
-     "pointer type mismatch (%0 and %1)")
-DIAG(err_typecheck_choose_expr_requires_constant, ERROR,
-     "'__builtin_choose_expr' requires a constant expression")
-DIAG(ext_typecheck_expression_not_constant_but_accepted, EXTENSION,
-     "expression is not a constant, but is accepted as one by GNU extensions")
-DIAG(warn_unused_expr, WARNING,
-     "expression result unused")
-DIAG(err_pascal_string_too_long, ERROR,
-    "Pascal string is too long")
-DIAG(err_asm_wide_character, ERROR,
-    "wide string is invalid in 'asm'")
-DIAG(err_asm_invalid_lvalue_in_output, ERROR,
-    "invalid lvalue in asm output")
-DIAG(err_asm_invalid_output_constraint, ERROR,
-    "invalid output constraint '%0' in asm")
-DIAG(err_asm_invalid_lvalue_in_input, ERROR,
-     "invalid lvalue in asm input for constraint '%0'")
-DIAG(err_asm_invalid_input_constraint, ERROR,
-     "invalid input constraint '%0' in asm")
-DIAG(err_asm_invalid_type_in_input, ERROR,
-     "invalid type %0 in asm input for constraint '%1'")
-DIAG(err_asm_unknown_register_name, ERROR,
-    "unknown register name '%0' in asm")
-DIAG(err_invalid_conversion_between_vectors, ERROR,
-    "invalid conversion between vector type %0 and %1 of different size")
-DIAG(err_invalid_conversion_between_vector_and_integer, ERROR,
-    "invalid conversion between vector type %0 and integer type %1 "
-    "of different size")
-DIAG(err_invalid_conversion_between_vector_and_scalar, ERROR,
-    "invalid conversion between vector type %0 and scalar type %1")
-DIAG(err_overload_expr_requires_non_zero_constant, ERROR,
-     "overload requires a non-zero constant expression as first argument")
-DIAG(err_overload_incorrect_fntype, ERROR,
-     "argument is not a function, or has wrong number of parameters")
-     
-// FIXME: PASSING TYPES AS STRING.
-DIAG(err_overload_no_match, ERROR,
-     "no matching overload found for arguments of type '%0'")
-DIAG(err_overload_multiple_match, ERROR,
-     "more than one matching function found in __builtin_overload")
-
-// Classes.
-DIAG(err_expected_class_name, ERROR,
-     "expected class name")
-DIAG(err_anon_type_definition, ERROR,
-     "declaration of anonymous %0 must be a definition")
-
-// Namespaces.
-DIAG(err_expected_namespace_name, ERROR,
-     "expected namespace name")
-
-// C++ member initializers.
-DIAG(err_mem_init_not_member_or_class, ERROR,
-     "member initializer %0 does not name a non-static data member or base "
-     "class")
-DIAG(err_base_init_does_not_name_class, ERROR,
-     "constructor initializer %0 does not name a class")
-DIAG(err_base_init_direct_and_virtual, ERROR,
-     "base class initializer %0 names both a direct base class and an"
-     " inherited virtual base class")
-
-// C++ anonymous unions and GNU anonymous structs/unions
-DIAG(ext_anonymous_union, EXTENSION,
-     "anonymous unions are a GNU extension in C")
-DIAG(ext_anonymous_struct, EXTENSION,
-     "anonymous structs are a GNU extension")
-DIAG(err_anonymous_union_not_static, ERROR,
-     "anonymous unions at namespace or global scope must be declared 'static'")
-DIAG(err_anonymous_union_with_storage_spec, ERROR,
-     "anonymous union at class scope must not have a storage specifier")
-DIAG(err_anonymous_struct_not_member, ERROR,
-     "anonymous %select{structs|structs and classes}0 must be %select{struct or union|class}0 members")
-DIAG(err_anonymous_union_not_member, ERROR,
-     "anonymous unions must be struct or union members")
-DIAG(err_anonymous_union_member_redecl, ERROR,
-     "member of anonymous union redeclares %0")
-DIAG(err_anonymous_struct_member_redecl, ERROR,
-     "member of anonymous struct redeclares %0")
-DIAG(err_anonymous_record_with_type, ERROR,
-     "types cannot be declared in an anonymous %select{struct|union}0")
-DIAG(err_anonymous_record_with_function, ERROR,
-     "functions cannot be declared in an anonymous %select{struct|union}0")
-DIAG(err_anonymous_record_with_static, ERROR,
-     "static members cannot be declared in an anonymous %select{struct|union}0")
-DIAG(err_anonymous_record_bad_member, ERROR,
-     "anonymous %select{struct|union}0 can only contain non-static data members")
-DIAG(err_anonymous_record_nonpublic_member, ERROR,
-     "anonymous %select{struct|union}0 cannot contain a %select{private|protected}1 data member")
-
-// C++ derived classes
-DIAG(err_dup_virtual, ERROR,
-     "duplicate 'virtual' in base specifier")
-DIAG(err_base_clause_on_union, ERROR,
-     "unions cannot have base classes")
-DIAG(err_base_must_be_class, ERROR,
-     "base specifier must name a class")
-DIAG(err_union_as_base_class, ERROR,
-     "unions cannot be base classes")
-DIAG(err_incomplete_base_class, ERROR,
-     "base class has incomplete type")
-DIAG(err_duplicate_base_class, ERROR,
-     "base class %0 specified more than once as a direct base class")
-// FIXME: better way to display derivation?  Pass entire thing into diagclient?
-DIAG(err_ambiguous_derived_to_base_conv, ERROR,
-     "ambiguous conversion from derived class %0 to base class %1:%2")
-DIAG(err_ambiguous_base_to_derived_memptr_conv, ERROR,
-     "ambiguous conversion from pointer to member of base class %0 "
-     "to pointer to member of derived class %1:%2")
-DIAG(err_memptr_conv_via_virtual, ERROR,
-     "conversion from pointer to member of class %0 to pointer to member "
-     "of class %1 via virtual base %2 is not allowed")
-
-// C++ member name lookup
-DIAG(err_ambiguous_member_multiple_subobjects, ERROR,
-     "non-static member %0 found in multiple base-class subobjects of type %1:%2")
-DIAG(err_ambiguous_member_multiple_subobject_types, ERROR,
-     "member %0 found in multiple base classes of different types")
-DIAG(note_ambiguous_member_found, NOTE,
-     "member found by ambiguous name lookup")
-
-// C++ operator overloading
-DIAG(err_operator_overload_needs_class_or_enum, ERROR,
-     "overloaded %0 must have at least one parameter of class "
-     "or enumeration type")
-DIAG(err_operator_overload_variadic, ERROR,
-     "overloaded %0 cannot be variadic")
-DIAG(err_operator_overload_static, ERROR,
-     "overloaded %0 cannot be a static member function")
-DIAG(err_operator_overload_default_arg, ERROR,
-     "parameter of overloaded %0 cannot have a default argument")
-DIAG(err_operator_overload_must_be, ERROR,
-     "overloaded %0 must be a %select{unary|binary|unary or binary}2 operator"
-     " (has %1 parameter%s1)")
-DIAG(err_operator_overload_must_be_member, ERROR,
-     "overloaded %0 must be a non-static member function")
-DIAG(err_operator_overload_post_incdec_must_be_int, ERROR,
-     "parameter of overloaded post-%select{increment|decrement}1 operator must"
-     " have type 'int' (not %0)")
-DIAG(err_operator_missing_type_specifier, ERROR,
-     "missing type specifier after 'operator'")
-
-// C++ conversion functions
-DIAG(err_conv_function_not_member, ERROR,
-     "conversion function must be a non-static member function")
-DIAG(err_conv_function_return_type, ERROR,
-     "conversion function cannot have a return type")
-DIAG(err_conv_function_with_params, ERROR,
-     "conversion function cannot have any parameters")
-DIAG(err_conv_function_variadic, ERROR,
-     "conversion function cannot be variadic")
-DIAG(err_conv_function_to_array, ERROR,
-     "conversion function cannot convert to an array type")
-DIAG(err_conv_function_to_function, ERROR,
-     "conversion function cannot convert to a function type")
-DIAG(err_conv_function_redeclared, ERROR,
-     "conversion function cannot be redeclared")
-DIAG(warn_conv_to_self_not_used, WARNING,
-     "conversion function converting %0 to itself will never be used")
-DIAG(warn_conv_to_base_not_used, WARNING,
-     "conversion function converting %0 to its base class %1 will never be used")
-DIAG(warn_conv_to_void_not_used, WARNING,
-     "conversion function converting %0 to %1 will never be used")
-
-DIAG(warn_not_compound_assign, WARNING,
-     "use of unary operator that may be intended as compound assignment (%0=)")
-
-// C++0x explicit conversion operators
-DIAG(warn_explicit_conversion_functions, WARNING,
-     "explicit conversion functions are a C++0x extension")
-
-// CHECK: printf format string errors
-DIAG(warn_printf_not_string_constant, WARNING,
-     "format string is not a string literal (potentially insecure)")
-DIAG(warn_printf_write_back, WARNING,
-     "use of '%%n' in format string discouraged (potentially insecure)")
-DIAG(warn_printf_insufficient_data_args, WARNING,
-    "more '%%' conversions than data arguments")
-DIAG(warn_printf_too_many_data_args, WARNING,
-    "more data arguments than '%%' conversions")
-DIAG(warn_printf_invalid_conversion, WARNING,
-    "invalid conversion '%0'")
-DIAG(warn_printf_missing_format_string, WARNING,
-    "format string missing")
-DIAG(warn_printf_empty_format_string, WARNING,
-   "format string is empty")
-DIAG(warn_printf_format_string_is_wide_literal, WARNING,
-  "format string should not be a wide string")
-DIAG(warn_printf_format_string_contains_null_char, WARNING,
-  "format string contains '\\0' within the string body")
-DIAG(warn_printf_asterisk_width_missing_arg, WARNING,
-     "'*' specified field width is missing a matching 'int' argument")
-DIAG(warn_printf_asterisk_precision_missing_arg, WARNING,
-     "'.*' specified field precision is missing a matching 'int' argument")
-DIAG(warn_printf_asterisk_width_wrong_type, WARNING,
-     "field width should have type 'int', but argument has type %0")
-DIAG(warn_printf_asterisk_precision_wrong_type, WARNING,
-     "field precision should have type 'int', but argument has type %0")
-
-// CHECK: returning address/reference of stack memory
-DIAG(warn_ret_stack_addr, WARNING,
-  "address of stack memory associated with local variable %0 returned")
-DIAG(warn_ret_stack_ref, WARNING,
-  "reference to stack memory associated with local variable %0 returned")
-
-// CHECK: floating point values should not use "==" or "!="
-DIAG(warn_floatingpoint_eq, WARNING,
-  "comparing floating point with == or != is unsafe")
-
-// CHECK: for non-floating point, expressions of the form x == x or x != x
-// should result in a warning, since these always evaluate to a constant.
-DIAG(warn_selfcomparison,WARNING,
-     "self-comparison always results in a constant value.")
-
-// CHECK: use of uninitialized values
-DIAG(warn_uninit_val, WARNING, "use of uninitialized variable")
-
-// Blocks
-DIAG(err_expected_block_lbrace, ERROR,
-     "expected '{' in block literal")
-DIAG(err_goto_in_block, ERROR,
-     "goto not allowed in block literal")
-DIAG(err_return_in_block_expression, ERROR,
-     "return not allowed in block expression literal")
-
-DIAG(err_ret_local_block, ERROR,
-     "returning block that lives on the local stack")
-
-// CFString checking
-DIAG(err_cfstring_literal_not_string_constant, ERROR,
-  "CFString literal is not a string constant")
-DIAG(warn_cfstring_literal_contains_non_ascii_character, WARNING,
-  "CFString literal contains non-ASCII character")
-DIAG(warn_cfstring_literal_contains_nul_character, WARNING,
-  "CFString literal contains NUL character")
-
-// Statements.
-DIAG(err_continue_not_in_loop, ERROR,
-     "'continue' statement not in loop statement")
-DIAG(err_break_not_in_loop_or_switch, ERROR,
-     "'break' statement not in loop or switch statement")
-DIAG(err_default_not_in_switch, ERROR,
-     "'default' statement not in switch statement")
-DIAG(err_case_not_in_switch, ERROR,
-     "'case' statement not in switch statement")
-DIAG(warn_case_value_overflow, WARNING,
-     "overflow converting case value to switch condition type (%0 to %1)")
-DIAG(err_duplicate_case, ERROR,
-     "duplicate case value '%0'")
-DIAG(warn_case_empty_range, WARNING,
-     "empty case range specified")
-DIAG(err_typecheck_statement_requires_scalar, ERROR,
-     "statement requires expression of scalar type (%0 invalid)")
-DIAG(err_typecheck_statement_requires_integer, ERROR,
-    "statement requires expression of integer type (%0 invalid)")
-DIAG(err_multiple_default_labels_defined, ERROR,
-    "multiple default labels in one switch")
-DIAG(warn_empty_if_body, WARNING,
-    "if statement has empty body")
-DIAG(err_va_start_used_in_non_variadic_function, ERROR,
-    "'va_start' used in function with fixed args")
-DIAG(warn_second_parameter_of_va_start_not_last_named_argument, WARNING,
-    "second parameter of 'va_start' not last named argument")
-DIAG(err_first_argument_to_va_arg_not_of_type_va_list, ERROR,
-    "first argument to 'va_arg' is of type %0 and not 'va_list'")
-  
-DIAG(warn_return_missing_expr, WARNING,
-     "non-void %select{function|method}1 %0 should return a value")
-DIAG(ext_return_missing_expr, EXTENSION,
-     "non-void %select{function|method}1 %0 should return a value")
-DIAG(ext_return_has_expr, EXTWARN,
-     "void %select{function|method}1 %0 should not return a value")
-DIAG(ext_return_has_void_expr, EXTENSION,
-     "void %select{function|method}1 %0 should not return void expression")
-
-DIAG(err_shufflevector_non_vector, ERROR,
-     "first two arguments to __builtin_shufflevector must be vectors")
-DIAG(err_shufflevector_incompatible_vector, ERROR,
-     "first two arguments to __builtin_shufflevector must have the same type")
-DIAG(err_shufflevector_nonconstant_argument, ERROR,
-     "index for __builtin_shufflevector must be a constant integer")
-DIAG(err_shufflevector_argument_too_large, ERROR,
-     "index for __builtin_shufflevector must be less than the total number"
-     " of vector elements")
-
-DIAG(err_stack_const_level, ERROR,
-     "level argument for a stack address builtin must be constant")
-
-DIAG(err_prefetch_invalid_argument, ERROR,
-     "argument to __builtin_prefetch must be a constant integer")
-DIAG(err_argument_invalid_range, ERROR,
-     "argument should be a value from %0 to %1")
-
-DIAG(err_object_size_invalid_argument, ERROR,
-     "argument to __builtin_object_size must be a constant integer")
+#include "clang/Basic/DiagnosticCommonKinds.def"
+#include "clang/Basic/DiagnosticLexKinds.def"
+#include "clang/Basic/DiagnosticParseKinds.def"
+#include "clang/Basic/DiagnosticASTKinds.def"
+#include "clang/Basic/DiagnosticSemaKinds.def"
+#include "clang/Basic/DiagnosticAnalysisKinds.def"
 
 #undef DIAG

Modified: cfe/trunk/lib/AST/ExprConstant.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/ExprConstant.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/AST/ExprConstant.cpp (original)
+++ cfe/trunk/lib/AST/ExprConstant.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/RecordLayout.h"
 #include "clang/AST/StmtVisitor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticAST.h"
 #include "clang/Basic/TargetInfo.h"
 #include "llvm/Support/Compiler.h"
 using namespace clang;

Modified: cfe/trunk/lib/Analysis/UninitializedValues.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/UninitializedValues.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Analysis/UninitializedValues.cpp (original)
+++ cfe/trunk/lib/Analysis/UninitializedValues.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #include "clang/Analysis/Analyses/UninitializedValues.h"
 #include "clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h"
 #include "clang/Analysis/LocalCheckers.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticAnalysis.h"
 #include "clang/AST/ASTContext.h"
 #include "clang/Analysis/FlowSensitive/DataflowSolver.h"
 #include "llvm/Support/Compiler.h"

Modified: cfe/trunk/lib/Basic/Diagnostic.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Diagnostic.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Basic/Diagnostic.cpp (original)
+++ cfe/trunk/lib/Basic/Diagnostic.cpp Tue Jan 27 12:30:58 2009
@@ -36,29 +36,99 @@
   class_mask = 0x07
 };
 
+namespace clang {
+  namespace diag {
+    enum _kind{
+#define DIAG(ENUM,FLAGS,DESC) ENUM,
+#define LEXSTART
+#define PARSESTART
+#define ASTSTART
+#define SEMASTART
+#define ANALYSISSTART
+#include "clang/Basic/DiagnosticKinds.def"
+      NUM_BUILTIN_DIAGNOSTICS = DIAG_UPPER_LIMIT
+    };
+  }
+}
+
 /// DiagnosticFlags - A set of flags, or'd together, that describe the
 /// diagnostic.
-static unsigned char DiagnosticFlags[] = {
 #define DIAG(ENUM,FLAGS,DESC) FLAGS,
-#include "clang/Basic/DiagnosticKinds.def"
+static unsigned char DiagnosticFlagsCommon[] = {
+#include "clang/Basic/DiagnosticCommonKinds.def"
+  0
+};
+static unsigned char DiagnosticFlagsLex[] = {
+#include "clang/Basic/DiagnosticLexKinds.def"
+  0
+};
+static unsigned char DiagnosticFlagsParse[] = {
+#include "clang/Basic/DiagnosticParseKinds.def"
+  0
+};
+static unsigned char DiagnosticFlagsAST[] = {
+#include "clang/Basic/DiagnosticASTKinds.def"
+  0
+};
+static unsigned char DiagnosticFlagsSema[] = {
+#include "clang/Basic/DiagnosticSemaKinds.def"
+  0
+};
+static unsigned char DiagnosticFlagsAnalysis[] = {
+#include "clang/Basic/DiagnosticAnalysisKinds.def"
   0
 };
+#undef DIAG
 
 /// getDiagClass - Return the class field of the diagnostic.
 ///
 static unsigned getBuiltinDiagClass(unsigned DiagID) {
   assert(DiagID < diag::NUM_BUILTIN_DIAGNOSTICS &&
          "Diagnostic ID out of range!");
-  return DiagnosticFlags[DiagID] & class_mask;
+  unsigned res;
+  if (DiagID < DIAG_START_LEX)
+    res = DiagnosticFlagsCommon[DiagID];
+  else if (DiagID < DIAG_START_PARSE)
+    res = DiagnosticFlagsLex[DiagID - DIAG_START_LEX - 1];
+  else if (DiagID < DIAG_START_AST)
+    res = DiagnosticFlagsParse[DiagID - DIAG_START_PARSE - 1];
+  else if (DiagID < DIAG_START_SEMA)
+    res = DiagnosticFlagsAST[DiagID - DIAG_START_AST - 1];
+  else if (DiagID < DIAG_START_ANALYSIS)
+    res = DiagnosticFlagsSema[DiagID - DIAG_START_SEMA - 1];
+  else
+    res = DiagnosticFlagsAnalysis[DiagID - DIAG_START_ANALYSIS - 1];
+  return res & class_mask;
 }
 
 /// DiagnosticText - An english message to print for the diagnostic.  These
 /// should be localized.
-static const char * const DiagnosticText[] = {
 #define DIAG(ENUM,FLAGS,DESC) DESC,
-#include "clang/Basic/DiagnosticKinds.def"
+static const char * const DiagnosticTextCommon[] = {
+#include "clang/Basic/DiagnosticCommonKinds.def"
+  0
+};
+static const char * const DiagnosticTextLex[] = {
+#include "clang/Basic/DiagnosticLexKinds.def"
+  0
+};
+static const char * const DiagnosticTextParse[] = {
+#include "clang/Basic/DiagnosticParseKinds.def"
   0
 };
+static const char * const DiagnosticTextAST[] = {
+#include "clang/Basic/DiagnosticASTKinds.def"
+  0
+};
+static const char * const DiagnosticTextSema[] = {
+#include "clang/Basic/DiagnosticSemaKinds.def"
+  0
+};
+static const char * const DiagnosticTextAnalysis[] = {
+#include "clang/Basic/DiagnosticAnalysisKinds.def"
+  0
+};
+#undef DIAG
 
 //===----------------------------------------------------------------------===//
 // Custom Diagnostic information
@@ -170,9 +240,22 @@
 /// issue.
 const char *Diagnostic::getDescription(unsigned DiagID) const {
   if (DiagID < diag::NUM_BUILTIN_DIAGNOSTICS)
-    return DiagnosticText[DiagID];
-  else 
-    return CustomDiagInfo->getDescription(DiagID);
+  {
+    if (DiagID < DIAG_START_LEX)
+      return DiagnosticTextCommon[DiagID];
+    else if (DiagID < DIAG_START_PARSE)
+      return DiagnosticTextLex[DiagID - DIAG_START_LEX - 1];
+    else if (DiagID < DIAG_START_AST)
+      return DiagnosticTextParse[DiagID - DIAG_START_PARSE - 1];
+    else if (DiagID < DIAG_START_SEMA)
+      return DiagnosticTextAST[DiagID - DIAG_START_AST - 1];
+    else if (DiagID < DIAG_START_ANALYSIS)
+      return DiagnosticTextSema[DiagID - DIAG_START_SEMA - 1];
+    else if (DiagID < DIAG_UPPER_LIMIT)
+      return DiagnosticTextAnalysis[DiagID - DIAG_START_ANALYSIS - 1];
+  }
+   
+  return CustomDiagInfo->getDescription(DiagID);
 }
 
 /// getDiagnosticLevel - Based on the way the client configured the Diagnostic

Modified: cfe/trunk/lib/Lex/Lexer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/Lexer.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/Lexer.cpp (original)
+++ cfe/trunk/lib/Lex/Lexer.cpp Tue Jan 27 12:30:58 2009
@@ -26,7 +26,7 @@
 
 #include "clang/Lex/Lexer.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/SourceManager.h"
 #include "llvm/Support/Compiler.h"
 #include "llvm/Support/MemoryBuffer.h"

Modified: cfe/trunk/lib/Lex/LiteralSupport.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/LiteralSupport.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/LiteralSupport.cpp (original)
+++ cfe/trunk/lib/Lex/LiteralSupport.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 
 #include "clang/Lex/LiteralSupport.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/TargetInfo.h"
 #include "llvm/ADT/StringExtras.h"
 using namespace clang;

Modified: cfe/trunk/lib/Lex/MacroArgs.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/MacroArgs.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/MacroArgs.cpp (original)
+++ cfe/trunk/lib/Lex/MacroArgs.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #include "MacroArgs.h"
 #include "clang/Lex/MacroInfo.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 using namespace clang;
 
 /// MacroArgs ctor function - This destroys the vector passed in.

Modified: cfe/trunk/lib/Lex/PPDirectives.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PPDirectives.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/PPDirectives.cpp (original)
+++ cfe/trunk/lib/Lex/PPDirectives.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/Lex/LiteralSupport.h"
 #include "clang/Lex/HeaderSearch.h"
 #include "clang/Lex/MacroInfo.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/SourceManager.h"
 #include "llvm/ADT/APInt.h"
 using namespace clang;

Modified: cfe/trunk/lib/Lex/PPExpressions.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PPExpressions.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/PPExpressions.cpp (original)
+++ cfe/trunk/lib/Lex/PPExpressions.cpp Tue Jan 27 12:30:58 2009
@@ -20,7 +20,7 @@
 #include "clang/Lex/MacroInfo.h"
 #include "clang/Lex/LiteralSupport.h"
 #include "clang/Basic/TargetInfo.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "llvm/ADT/APSInt.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Lex/PPLexerChange.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PPLexerChange.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/PPLexerChange.cpp (original)
+++ cfe/trunk/lib/Lex/PPLexerChange.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/Lex/Preprocessor.h"
 #include "clang/Lex/HeaderSearch.h"
 #include "clang/Lex/MacroInfo.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/SourceManager.h"
 #include "llvm/Support/MemoryBuffer.h"
 

Modified: cfe/trunk/lib/Lex/PPMacroExpansion.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PPMacroExpansion.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/PPMacroExpansion.cpp (original)
+++ cfe/trunk/lib/Lex/PPMacroExpansion.cpp Tue Jan 27 12:30:58 2009
@@ -17,7 +17,7 @@
 #include "clang/Lex/MacroInfo.h"
 #include "clang/Basic/SourceManager.h"
 #include "clang/Basic/FileManager.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include <ctime>
 using namespace clang;
 

Modified: cfe/trunk/lib/Lex/Pragma.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/Pragma.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/Pragma.cpp (original)
+++ cfe/trunk/lib/Lex/Pragma.cpp Tue Jan 27 12:30:58 2009
@@ -16,7 +16,7 @@
 #include "clang/Lex/HeaderSearch.h"
 #include "clang/Lex/LiteralSupport.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/FileManager.h"
 #include "clang/Basic/SourceManager.h"
 using namespace clang;

Modified: cfe/trunk/lib/Lex/Preprocessor.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/Preprocessor.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/Preprocessor.cpp (original)
+++ cfe/trunk/lib/Lex/Preprocessor.cpp Tue Jan 27 12:30:58 2009
@@ -30,7 +30,7 @@
 #include "clang/Lex/MacroInfo.h"
 #include "clang/Lex/Pragma.h"
 #include "clang/Lex/ScratchBuffer.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/SourceManager.h"
 #include "clang/Basic/TargetInfo.h"
 #include "llvm/ADT/APFloat.h"

Modified: cfe/trunk/lib/Lex/PreprocessorLexer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PreprocessorLexer.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/PreprocessorLexer.cpp (original)
+++ cfe/trunk/lib/Lex/PreprocessorLexer.cpp Tue Jan 27 12:30:58 2009
@@ -13,7 +13,7 @@
 
 #include "clang/Lex/PreprocessorLexer.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "clang/Basic/SourceManager.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Lex/TokenLexer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/TokenLexer.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Lex/TokenLexer.cpp (original)
+++ cfe/trunk/lib/Lex/TokenLexer.cpp Tue Jan 27 12:30:58 2009
@@ -16,7 +16,7 @@
 #include "clang/Lex/MacroInfo.h"
 #include "clang/Lex/Preprocessor.h"
 #include "clang/Basic/SourceManager.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticLex.h"
 #include "llvm/ADT/SmallVector.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Parse/DeclSpec.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/DeclSpec.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/DeclSpec.cpp (original)
+++ cfe/trunk/lib/Parse/DeclSpec.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/DeclSpec.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Basic/LangOptions.h"
 #include "llvm/ADT/STLExtras.h"
 using namespace clang;

Modified: cfe/trunk/lib/Parse/ExtensionRAIIObject.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ExtensionRAIIObject.h?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ExtensionRAIIObject.h (original)
+++ cfe/trunk/lib/Parse/ExtensionRAIIObject.h Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #ifndef LLVM_CLANG_PARSE_EXTENSION_RAII_OBJECT_H
 #define LLVM_CLANG_PARSE_EXTENSION_RAII_OBJECT_H
 
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 
 namespace clang {
 

Modified: cfe/trunk/lib/Parse/ParseCXXInlineMethods.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseCXXInlineMethods.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseCXXInlineMethods.cpp (original)
+++ cfe/trunk/lib/Parse/ParseCXXInlineMethods.cpp Tue Jan 27 12:30:58 2009
@@ -11,7 +11,7 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/Parser.h"
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Parse/Scope.h"

Modified: cfe/trunk/lib/Parse/ParseDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseDecl.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseDecl.cpp (original)
+++ cfe/trunk/lib/Parse/ParseDecl.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/Parser.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/Scope.h"
 #include "ExtensionRAIIObject.h"
 #include "AstGuard.h"

Modified: cfe/trunk/lib/Parse/ParseDeclCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseDeclCXX.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseDeclCXX.cpp (original)
+++ cfe/trunk/lib/Parse/ParseDeclCXX.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/Parser.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Parse/Scope.h"
 #include "AstGuard.h"

Modified: cfe/trunk/lib/Parse/ParseExprCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseExprCXX.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseExprCXX.cpp (original)
+++ cfe/trunk/lib/Parse/ParseExprCXX.cpp Tue Jan 27 12:30:58 2009
@@ -11,7 +11,7 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/Parser.h"
 #include "clang/Parse/DeclSpec.h"
 #include "AstGuard.h"

Modified: cfe/trunk/lib/Parse/ParseInit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseInit.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseInit.cpp (original)
+++ cfe/trunk/lib/Parse/ParseInit.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #include "clang/Parse/Designator.h"
 #include "clang/Parse/Parser.h"
 #include "AstGuard.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "llvm/ADT/SmallString.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Parse/ParseObjc.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseObjc.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseObjc.cpp (original)
+++ cfe/trunk/lib/Parse/ParseObjc.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Parse/Scope.h"
 #include "AstGuard.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "llvm/ADT/SmallVector.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Parse/ParsePragma.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParsePragma.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParsePragma.cpp (original)
+++ cfe/trunk/lib/Parse/ParsePragma.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "ParsePragma.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Lex/Preprocessor.h"
 #include "clang/Parse/Action.h"
 using namespace clang;

Modified: cfe/trunk/lib/Parse/ParseTemplate.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseTemplate.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseTemplate.cpp (original)
+++ cfe/trunk/lib/Parse/ParseTemplate.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/Parser.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Parse/Scope.h"
 

Modified: cfe/trunk/lib/Parse/ParseTentative.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseTentative.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/ParseTentative.cpp (original)
+++ cfe/trunk/lib/Parse/ParseTentative.cpp Tue Jan 27 12:30:58 2009
@@ -13,7 +13,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/Parser.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 using namespace clang;
 
 /// isCXXDeclarationStatement - C++-specialized function that disambiguates

Modified: cfe/trunk/lib/Parse/Parser.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/Parser.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Parse/Parser.cpp (original)
+++ cfe/trunk/lib/Parse/Parser.cpp Tue Jan 27 12:30:58 2009
@@ -12,7 +12,7 @@
 //===----------------------------------------------------------------------===//
 
 #include "clang/Parse/Parser.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticParse.h"
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Parse/Scope.h"
 #include "ExtensionRAIIObject.h"

Modified: cfe/trunk/lib/Sema/Sema.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/Sema.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/Sema.cpp (original)
+++ cfe/trunk/lib/Sema/Sema.cpp Tue Jan 27 12:30:58 2009
@@ -17,7 +17,7 @@
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/Expr.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 using namespace clang;
 
 /// ConvertQualTypeToStringFn - This function is used to pretty print the 

Modified: cfe/trunk/lib/Sema/Sema.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/Sema.h?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/Sema.h (original)
+++ cfe/trunk/lib/Sema/Sema.h Tue Jan 27 12:30:58 2009
@@ -21,7 +21,7 @@
 #include "clang/AST/DeclBase.h"
 #include "clang/AST/Expr.h"
 #include "clang/Parse/Action.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/ADT/DenseSet.h"
 #include "llvm/ADT/SmallPtrSet.h"

Modified: cfe/trunk/lib/Sema/SemaCXXScopeSpec.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaCXXScopeSpec.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaCXXScopeSpec.cpp (original)
+++ cfe/trunk/lib/Sema/SemaCXXScopeSpec.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #include "Sema.h"
 #include "clang/AST/ASTContext.h"
 #include "clang/Parse/DeclSpec.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "llvm/ADT/STLExtras.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Sema/SemaChecking.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaChecking.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaChecking.cpp (original)
+++ cfe/trunk/lib/Sema/SemaChecking.cpp Tue Jan 27 12:30:58 2009
@@ -18,7 +18,7 @@
 #include "clang/AST/ExprCXX.h"
 #include "clang/AST/ExprObjC.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "SemaUtil.h"
 using namespace clang;
 

Modified: cfe/trunk/lib/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDecl.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDecl.cpp Tue Jan 27 12:30:58 2009
@@ -18,7 +18,7 @@
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/ExprCXX.h"
 #include "clang/Parse/DeclSpec.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Basic/TargetInfo.h"
 #include "clang/Basic/SourceManager.h"
 // FIXME: layering (ideally, Sema shouldn't be dependent on Lex API's)

Modified: cfe/trunk/lib/Sema/SemaDeclAttr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclAttr.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclAttr.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclAttr.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/Expr.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Basic/TargetInfo.h"
 #include "clang/Parse/DeclSpec.h"
 #include <llvm/ADT/StringExtras.h>

Modified: cfe/trunk/lib/Sema/SemaDeclCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclCXX.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclCXX.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclCXX.cpp Tue Jan 27 12:30:58 2009
@@ -18,7 +18,7 @@
 #include "clang/AST/TypeOrdering.h"
 #include "clang/AST/StmtVisitor.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Parse/DeclSpec.h"
 #include "llvm/ADT/STLExtras.h"
 #include "llvm/Support/Compiler.h"

Modified: cfe/trunk/lib/Sema/SemaDeclObjC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclObjC.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclObjC.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclObjC.cpp Tue Jan 27 12:30:58 2009
@@ -14,7 +14,7 @@
 #include "Sema.h"
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/DeclObjC.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Parse/DeclSpec.h"
 
 using namespace clang;

Modified: cfe/trunk/lib/Sema/SemaExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaExpr.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaExpr.cpp (original)
+++ cfe/trunk/lib/Sema/SemaExpr.cpp Tue Jan 27 12:30:58 2009
@@ -18,7 +18,7 @@
 #include "clang/AST/ExprObjC.h"
 #include "clang/Lex/Preprocessor.h"
 #include "clang/Lex/LiteralSupport.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Basic/SourceManager.h"
 #include "clang/Basic/TargetInfo.h"
 #include "clang/Parse/DeclSpec.h"

Modified: cfe/trunk/lib/Sema/SemaExprCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaExprCXX.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaExprCXX.cpp (original)
+++ cfe/trunk/lib/Sema/SemaExprCXX.cpp Tue Jan 27 12:30:58 2009
@@ -16,7 +16,7 @@
 #include "clang/AST/ASTContext.h"
 #include "clang/Parse/DeclSpec.h"
 #include "clang/Lex/Preprocessor.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Basic/TargetInfo.h"
 #include "llvm/ADT/STLExtras.h"
 using namespace clang;

Modified: cfe/trunk/lib/Sema/SemaExprObjC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaExprObjC.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaExprObjC.cpp (original)
+++ cfe/trunk/lib/Sema/SemaExprObjC.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/ExprObjC.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 using namespace clang;
 
 Sema::ExprResult Sema::ParseObjCStringLiteral(SourceLocation *AtLocs, 

Modified: cfe/trunk/lib/Sema/SemaInherit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaInherit.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaInherit.cpp (original)
+++ cfe/trunk/lib/Sema/SemaInherit.cpp Tue Jan 27 12:30:58 2009
@@ -19,7 +19,7 @@
 #include "clang/AST/DeclCXX.h"
 #include "clang/AST/Type.h"
 #include "clang/AST/TypeOrdering.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include <algorithm>
 #include <memory>
 #include <set>

Modified: cfe/trunk/lib/Sema/SemaInit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaInit.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaInit.cpp (original)
+++ cfe/trunk/lib/Sema/SemaInit.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/Parse/Designator.h"
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/Expr.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include <algorithm> // for std::count_if
 #include <functional> // for std::mem_fun
 

Modified: cfe/trunk/lib/Sema/SemaNamedCast.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaNamedCast.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaNamedCast.cpp (original)
+++ cfe/trunk/lib/Sema/SemaNamedCast.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "SemaInherit.h"
 #include "clang/AST/ExprCXX.h"
 #include "clang/AST/ASTContext.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "llvm/ADT/SmallVector.h"
 #include <set>
 using namespace clang;

Modified: cfe/trunk/lib/Sema/SemaStmt.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaStmt.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaStmt.cpp (original)
+++ cfe/trunk/lib/Sema/SemaStmt.cpp Tue Jan 27 12:30:58 2009
@@ -17,7 +17,7 @@
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/Expr.h"
 #include "clang/Basic/TargetInfo.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 using namespace clang;
 
 Sema::OwningStmtResult Sema::ActOnExprStmt(ExprArg expr) {

Modified: cfe/trunk/lib/Sema/SemaType.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaType.cpp?rev=63111&r1=63110&r2=63111&view=diff

==============================================================================
--- cfe/trunk/lib/Sema/SemaType.cpp (original)
+++ cfe/trunk/lib/Sema/SemaType.cpp Tue Jan 27 12:30:58 2009
@@ -15,7 +15,7 @@
 #include "clang/AST/ASTContext.h"
 #include "clang/AST/DeclObjC.h"
 #include "clang/AST/Expr.h"
-#include "clang/Basic/Diagnostic.h"
+#include "clang/Basic/DiagnosticSema.h"
 #include "clang/Parse/DeclSpec.h"
 using namespace clang;
 





More information about the cfe-commits mailing list