clang  6.0.0svn
ASTDiagnostic.h
Go to the documentation of this file.
1 //===--- ASTDiagnostic.h - Diagnostics for the AST library ------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef LLVM_CLANG_AST_ASTDIAGNOSTIC_H
11 #define LLVM_CLANG_AST_ASTDIAGNOSTIC_H
12 
13 #include "clang/Basic/Diagnostic.h"
14 
15 namespace clang {
16  namespace diag {
17  enum {
18 #define DIAG(ENUM,FLAGS,DEFAULT_MAPPING,DESC,GROUP,\
19  SFINAE,NOWERROR,SHOWINSYSHEADER,CATEGORY) ENUM,
20 #define ASTSTART
21 #include "clang/Basic/DiagnosticASTKinds.inc"
22 #undef DIAG
24  };
25  } // end namespace diag
26 
27  /// \brief DiagnosticsEngine argument formatting function for diagnostics that
28  /// involve AST nodes.
29  ///
30  /// This function formats diagnostic arguments for various AST nodes,
31  /// including types, declaration names, nested name specifiers, and
32  /// declaration contexts, into strings that can be printed as part of
33  /// diagnostics. It is meant to be used as the argument to
34  /// \c DiagnosticsEngine::SetArgToStringFn(), where the cookie is an \c
35  /// ASTContext pointer.
38  intptr_t Val,
39  StringRef Modifier,
40  StringRef Argument,
42  SmallVectorImpl<char> &Output,
43  void *Cookie,
44  ArrayRef<intptr_t> QualTypeVals);
45 } // end namespace clang
46 
47 #endif
Defines the Diagnostic-related interfaces.
__INTPTR_TYPE__ intptr_t
A signed integer type with the property that any valid pointer to void can be converted to this type...
Definition: opencl-c.h:75
Kind
OpenMPLinearClauseKind Modifier
Modifier of &#39;linear&#39; clause.
Definition: OpenMPClause.h:87
Dataflow Directional Tag Classes.
void FormatASTNodeDiagnosticArgument(DiagnosticsEngine::ArgumentKind Kind, intptr_t Val, StringRef Modifier, StringRef Argument, ArrayRef< DiagnosticsEngine::ArgumentValue > PrevArgs, SmallVectorImpl< char > &Output, void *Cookie, ArrayRef< intptr_t > QualTypeVals)
DiagnosticsEngine argument formatting function for diagnostics that involve AST nodes.