MLIR  20.0.0git
Diagnostic.cpp
Go to the documentation of this file.
1 //===- Diagnostic.cpp -----------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
10 
11 using namespace mlir;
12 using namespace mlir::pdll::ast;
13 
14 //===----------------------------------------------------------------------===//
15 // InFlightDiagnostic
16 //===----------------------------------------------------------------------===//
17 
19  // If this diagnostic is still inflight and it hasn't been abandoned, then
20  // report it.
21  if (isInFlight()) {
22  owner->report(std::move(*impl));
23  owner = nullptr;
24  }
25  impl.reset();
26 }
void report(Diagnostic &&diagnostic)
Report the given diagnostic.
Definition: Diagnostic.h:155
void report()
Reports the diagnostic to the engine.
Include the generated interface declarations.