15 #ifndef LLVM_CLANG_ASTMATCHERS_DYNAMIC_DIAGNOSTICS_H
16 #define LLVM_CLANG_ASTMATCHERS_DYNAMIC_DIAGNOSTICS_H
20 #include "llvm/ADT/ArrayRef.h"
21 #include "llvm/ADT/StringRef.h"
22 #include "llvm/ADT/Twine.h"
23 #include "llvm/Support/raw_ostream.h"
28 namespace ast_matchers {
86 ArgStream(std::vector<std::string> *Out) : Out(Out) {}
93 std::vector<std::string> *Out;
177 std::vector<ContextFrame> ContextStack;
178 std::vector<ErrorContent> Errors;
185 #endif // LLVM_CLANG_AST_MATCHERS_DYNAMIC_DIAGNOSTICS_H
std::string toString() const
The base class of the type hierarchy.
std::vector< std::string > Args
MatcherArgEnum
About to recurse into parsing one argument for a matcher.
Context(ConstructMatcherEnum, Diagnostics *Error, StringRef MatcherName, SourceRange MatcherRange)
ContextType
Parser context types.
ConstructMatcherEnum
About to call the constructor for a matcher.
std::vector< Message > Messages
OverloadContext(Diagnostics *Error)
Forward-declares and imports various common LLVM datatypes that clang wants to use unqualified...
Class defining a parser context.
void revertErrors()
Revert all errors that happened within this context.
A VariantValue instance annotated with its parser context.
std::string toStringFull() const
ArgStream(std::vector< std::string > *Out)
ArrayRef< ErrorContent > errors() const
Helper class to manage error messages.
ArgStream addError(SourceRange Range, ErrorType Error)
Add an error to the diagnostics.
ErrorType
All errors from the system.
void printToStream(llvm::raw_ostream &OS) const
Returns a simple string representation of each error.
ArgStream & operator<<(const T &Arg)
std::vector< ContextFrame > ContextStack
Context for overloaded matcher construction.
Information stored for each error found.
std::vector< std::string > Args
void printToStreamFull(llvm::raw_ostream &OS) const
Returns the full string representation of each error.
Information stored for one frame of the context.