Change the return type of createPrintCFGGraphPass to match other passes.

PiperOrigin-RevId: 271252404
This commit is contained in:
Jing Pu 2019-09-25 18:33:09 -07:00 committed by A. Unique TensorFlower
parent ae13c28f3f
commit 47a7021cc3
2 changed files with 5 additions and 5 deletions

View File

@ -41,7 +41,7 @@ llvm::raw_ostream &writeGraph(llvm::raw_ostream &os, Region &region,
bool shortNames = false, const Twine &title = "");
/// Creates a pass to print CFG graphs.
OpPassBase<FuncOp> *
std::unique_ptr<mlir::OpPassBase<mlir::FuncOp>>
createPrintCFGGraphPass(llvm::raw_ostream &os = llvm::errs(),
bool shortNames = false, const llvm::Twine &title = "");

View File

@ -85,10 +85,10 @@ private:
};
} // namespace
OpPassBase<FuncOp> *mlir::createPrintCFGGraphPass(llvm::raw_ostream &os,
bool shortNames,
const llvm::Twine &title) {
return new PrintCFGPass(os, shortNames, title);
std::unique_ptr<mlir::OpPassBase<mlir::FuncOp>>
mlir::createPrintCFGGraphPass(llvm::raw_ostream &os, bool shortNames,
const llvm::Twine &title) {
return std::make_unique<PrintCFGPass>(os, shortNames, title);
}
static PassRegistration<PrintCFGPass> pass("print-cfg-graph",