Skip to content

Commit 719548d

Browse files
committed
Fix gcc warning by explicitly initializing the base class copy ctor (NFC)
Full diagnostic was: warning: base class ‘class mlir::OptReductionBase<mlir::OptReductionPass>’ should be explicitly initialized in the copy constructor [-Wextra]
1 parent eb35ebb commit 719548d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

mlir/tools/mlir-reduce/OptReductionPass.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ OptReductionPass::OptReductionPass(const Tester &test, MLIRContext *context,
2323
: context(context), test(test), optPass(std::move(optPass)) {}
2424

2525
OptReductionPass::OptReductionPass(const OptReductionPass &srcPass)
26-
: test(srcPass.test), optPass(srcPass.optPass.get()) {}
26+
: OptReductionBase<OptReductionPass>(srcPass), test(srcPass.test),
27+
optPass(srcPass.optPass.get()) {}
2728

2829
/// Runs the pass instance in the pass pipeline.
2930
void OptReductionPass::runOnOperation() {

0 commit comments

Comments
 (0)