MLIR  17.0.0git
Classes | Namespaces | Enumerations | Functions
Diagnostics.h File Reference
#include "mlir/IR/Location.h"
#include <functional>
#include <optional>

Go to the source code of this file.

Classes

class  mlir::DiagnosticArgument
 A variant type that holds a single argument for a diagnostic. More...
 
class  mlir::Diagnostic
 This class contains all of the information necessary to report a diagnostic to the DiagnosticEngine. More...
 
class  mlir::InFlightDiagnostic
 This class represents a diagnostic that is inflight and set to be reported. More...
 
class  mlir::DiagnosticEngine
 This class is the main interface for diagnostics. More...
 
class  mlir::ScopedDiagnosticHandler
 This diagnostic handler is a simple RAII class that registers and erases a diagnostic handler on a given context. More...
 
class  mlir::SourceMgrDiagnosticHandler
 This class is a utility diagnostic handler for use with llvm::SourceMgr. More...
 
class  mlir::SourceMgrDiagnosticVerifierHandler
 This class is a utility diagnostic handler for use with llvm::SourceMgr that verifies that emitted diagnostics match 'expected-*' lines on the corresponding line of the source file. More...
 
class  mlir::ParallelDiagnosticHandler
 This class is a utility diagnostic handler for use when multi-threading some part of the compiler where diagnostics may be emitted. More...
 

Namespaces

 llvm
 Include the generated interface declarations.
 
 mlir
 This header declares functions that assist transformations in the MemRef dialect.
 
 mlir::detail
 Detect if any of the given parameter types has a sub-element handler.
 

Enumerations

enum class  mlir::DiagnosticSeverity { mlir::Note , mlir::Warning , mlir::Error , mlir::Remark }
 Defines the different supported severity of a diagnostic. More...
 

Functions

raw_ostream & mlir::operator<< (raw_ostream &os, const DiagnosticArgument &arg)
 
raw_ostream & mlir::operator<< (raw_ostream &os, const Diagnostic &diag)
 
InFlightDiagnostic mlir::emitError (Location loc)
 Utility method to emit an error message using this location. More...
 
InFlightDiagnostic mlir::emitError (Location loc, const Twine &message)
 
InFlightDiagnostic mlir::emitWarning (Location loc)
 Utility method to emit a warning message using this location. More...
 
InFlightDiagnostic mlir::emitWarning (Location loc, const Twine &message)
 
InFlightDiagnostic mlir::emitRemark (Location loc)
 Utility method to emit a remark message using this location. More...
 
InFlightDiagnostic mlir::emitRemark (Location loc, const Twine &message)
 
template<typename... Args>
LogicalResult mlir::emitOptionalError (std::optional< Location > loc, Args &&...args)
 Overloads of the above emission functions that take an optionally null location. More...
 
template<typename... Args>
LogicalResult mlir::emitOptionalWarning (std::optional< Location > loc, Args &&...args)
 
template<typename... Args>
LogicalResult mlir::emitOptionalRemark (std::optional< Location > loc, Args &&...args)