|
MLIR 22.0.0git
|
Python class mirroring the C MlirDiagnostic struct. More...
#include "mlir/Bindings/Python/IRCore.h"
Classes | |
| struct | DiagnosticInfo |
| Materialized diagnostic information. More... | |
Public Member Functions | |
| PyDiagnostic (MlirDiagnostic diagnostic) | |
| void | invalidate () |
| bool | isValid () |
| PyDiagnosticSeverity | getSeverity () |
| PyLocation | getLocation () |
| nanobind::str | getMessage () |
| nanobind::tuple | getNotes () |
| DiagnosticInfo | getInfo () |
Python class mirroring the C MlirDiagnostic struct.
Note that these structs are only valid for the duration of a diagnostic callback and attempting to access them outside of that will raise an exception. This applies to nested diagnostics (in the notes) as well.
|
inline |
Definition at line 359 of file IRCore.h.
Referenced by invalidate().
| PyDiagnostic::DiagnosticInfo mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::getInfo | ( | ) |
Definition at line 799 of file IRCore.cpp.
| PyLocation mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::getLocation | ( | ) |
Definition at line 768 of file IRCore.cpp.
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::populateIRCore().
| nb::str mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::getMessage | ( | ) |
Definition at line 775 of file IRCore.cpp.
References mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyMlirContext::forContext().
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::populateIRCore().
| nb::tuple mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::getNotes | ( | ) |
Definition at line 783 of file IRCore.cpp.
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::populateIRCore().
| PyDiagnosticSeverity mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::getSeverity | ( | ) |
Definition at line 762 of file IRCore.cpp.
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::populateIRCore().
| void mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::PyDiagnostic::invalidate | ( | ) |
Definition at line 728 of file IRCore.cpp.
References PyDiagnostic().
|
inline |
Definition at line 361 of file IRCore.h.
Referenced by mlir::python::MLIR_BINDINGS_PYTHON_DOMAIN::populateIRCore().