forked from OSchip/llvm-project
[mlir][doc] Fix usage of PatternApplicator.
The constructor of PatternApplicator doesn't have a constructor that accepts only a `RewritePatternSet` as currently used in the example code in PatternRewriter.md. Instead, one has to turn it into a `FrozenRewritePatternSet`. Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D125236
This commit is contained in:
parent
46b1a7c5f9
commit
d4a7ca81fe
|
@ -283,7 +283,7 @@ public:
|
|||
|
||||
/// Apply the custom driver to `op`.
|
||||
void applyMyPatternDriver(Operation *op,
|
||||
const RewritePatternSet &patterns) {
|
||||
const FrozenRewritePatternSet &patterns) {
|
||||
// Initialize the custom PatternRewriter.
|
||||
MyPatternRewriter rewriter(op->getContext());
|
||||
|
||||
|
|
Loading…
Reference in New Issue