Halide 20.0.0
Halide compiler and libraries
Loading...
Searching...
No Matches
Halide::Internal::ErrorReport< Exception > Struct Template Reference

#include <Error.h>

Inheritance diagram for Halide::Internal::ErrorReport< Exception >:
Halide::Internal::ReportBase< ErrorReport< Exception > >

Public Types

using Base = ReportBase< ErrorReport >
 

Public Member Functions

 ErrorReport (const char *file, const char *function, int line, const char *condition_string)
 
 ~ErrorReport () noexcept(false)
 When you're done using << on the object, and let it fall out of scope, this errors out, or throws an exception if they are enabled.
 
- Public Member Functions inherited from Halide::Internal::ReportBase< ErrorReport< Exception > >
 ReportBase (const char *file, const char *function, int line, const char *condition_string, const char *prefix)
 
HALIDE_ALWAYS_INLINE ErrorReport< Exception > & ref ()
 
HALIDE_ALWAYS_INLINE ErrorReport< Exception > & operator<< (const S &x)
 

Additional Inherited Members

- Public Attributes inherited from Halide::Internal::ReportBase< ErrorReport< Exception > >
std::ostringstream msg
 
- Protected Member Functions inherited from Halide::Internal::ReportBase< ErrorReport< Exception > >
std::string finalize_message ()
 

Detailed Description

template<typename Exception>
struct Halide::Internal::ErrorReport< Exception >

Definition at line 158 of file Error.h.

Member Typedef Documentation

◆ Base

Definition at line 159 of file Error.h.

Constructor & Destructor Documentation

◆ ErrorReport()

template<typename Exception >
Halide::Internal::ErrorReport< Exception >::ErrorReport ( const char file,
const char function,
int  line,
const char condition_string 
)
inline

Definition at line 161 of file Error.h.

◆ ~ErrorReport()

When you're done using << on the object, and let it fall out of scope, this errors out, or throws an exception if they are enabled.

This is a little dangerous because the destructor will also be called if there's an exception in flight due to an error in one of the arguments passed to operator<<. We handle this by only actually throwing if there isn't an exception in flight already.

Definition at line 174 of file Error.h.

References Halide::Internal::throw_error().


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