Skip to content

Commit 29794ab

Browse files
committed
[mlir] Use context provided rather than getContext
Avoids "pass state was never initialized" assertion failure.
1 parent 03c066a commit 29794ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mlir/test/lib/Tools/PDLL/TestPDLL.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ struct TestPDLLPass : public PassWrapper<TestPDLLPass, OperationPass<>> {
2929
LogicalResult initialize(MLIRContext *ctx) override {
3030
// Build the pattern set within the `initialize` to avoid recompiling PDL
3131
// patterns during each `runOnOperation` invocation.
32-
RewritePatternSet patternList(&getContext());
32+
RewritePatternSet patternList(ctx);
3333
populateGeneratedPDLLPatterns(patternList);
3434
patterns = std::move(patternList);
3535
return success();

0 commit comments

Comments
 (0)