LLVM  13.0.0git
Public Member Functions | Static Public Member Functions | List of all members
llvm::ErrorInfo< ThisErrT, ParentErrT > Class Template Reference

Base class for user error types. More...

#include "llvm/Support/Error.h"

Inherits llvm::ErrorInfoBase.

Collaboration diagram for llvm::ErrorInfo< ThisErrT, ParentErrT >:
Collaboration graph
[legend]

Public Member Functions

const void * dynamicClassID () const override
 
bool isA (const void *const ClassID) const override
 
- Public Member Functions inherited from llvm::ErrorInfoBase
virtual ~ErrorInfoBase ()=default
 
virtual void log (raw_ostream &OS) const =0
 Print an error message to an output stream. More...
 
virtual std::string message () const
 Return the error message as a string. More...
 
virtual std::error_code convertToErrorCode () const =0
 Convert this error to a std::error_code. More...
 
template<typename ErrorInfoT >
bool isA () const
 

Static Public Member Functions

static const void * classID ()
 
- Static Public Member Functions inherited from llvm::ErrorInfoBase
static const void * classID ()
 

Detailed Description

template<typename ThisErrT, typename ParentErrT = ErrorInfoBase>
class llvm::ErrorInfo< ThisErrT, ParentErrT >

Base class for user error types.

Users should declare their error types like:

class MyError : public ErrorInfo<MyError> { .... };

This class provides an implementation of the ErrorInfoBase::kind method, which is used by the Error RTTI system.

Definition at line 350 of file Error.h.

Member Function Documentation

◆ classID()

template<typename ThisErrT , typename ParentErrT = ErrorInfoBase>
static const void* llvm::ErrorInfo< ThisErrT, ParentErrT >::classID ( )
inlinestatic

Definition at line 354 of file Error.h.

Referenced by llvm::ErrorInfo< MSFError, StringError >::isA().

◆ dynamicClassID()

template<typename ThisErrT , typename ParentErrT = ErrorInfoBase>
const void* llvm::ErrorInfo< ThisErrT, ParentErrT >::dynamicClassID ( ) const
inlineoverridevirtual

Implements llvm::ErrorInfoBase.

Definition at line 356 of file Error.h.

◆ isA()

template<typename ThisErrT , typename ParentErrT = ErrorInfoBase>
bool llvm::ErrorInfo< ThisErrT, ParentErrT >::isA ( const void *const  ClassID) const
inlineoverridevirtual

The documentation for this class was generated from the following file: