[MLIR][NFC] Get DiagnosticEngine as a reference in doc
authorAlfsonso Gregory <gfunni234@gmail.com>
Wed, 4 Aug 2021 18:31:11 +0000 (18:31 +0000)
committerrdzhabarov <rdzhabarov@google.com>
Wed, 4 Aug 2021 19:00:18 +0000 (19:00 +0000)
'mlir::DiagnosticEngine::DiagnosticEngine(const mlir::DiagnosticEngine&)' is implicitly deleted because the default definition would be ill-formed.

Reviewed By: rdzhabarov

Differential Revision: https://reviews.llvm.org/D107287

mlir/docs/Diagnostics.md

index 42d9840..1e27318 100644 (file)
@@ -26,7 +26,7 @@ the diagnostic should be propagated to any previously registered handlers. It
 can be interfaced with via an `MLIRContext` instance.
 
 ```c++
-DiagnosticEngine engine = ctx->getDiagEngine();
+DiagnosticEngine& engine = ctx->getDiagEngine();
 
 /// Handle the reported diagnostic.
 // Return success to signal that the diagnostic has either been fully processed,