Skip to content

Commit

Permalink
Fixed broken build under GCC 5.4.
Browse files Browse the repository at this point in the history
This diff fixes broken build caused by D108550. Under GCC 5, auto lambdas that capture this require `this->` for member calls.

Reviewed By: bondhugula

Differential Revision: https://reviews.llvm.org/D114659
  • Loading branch information
sfuniak authored and bondhugula committed Nov 27, 2021
1 parent 6fa8f7b commit a19e163
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mlir/lib/Conversion/PDLToPDLInterp/PDLToPDLInterp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,9 @@ Block *PatternLowering::generateMatcher(MatcherNode &node, Region &region) {

// Dispatch to the correct method based on derived node type.
TypeSwitch<MatcherNode *>(&node)
.Case<BoolNode, SwitchNode>(
[&](auto *derivedNode) { generate(derivedNode, currentBlock, val); })
.Case<BoolNode, SwitchNode>([&](auto *derivedNode) {
this->generate(derivedNode, currentBlock, val);
})
.Case([&](SuccessNode *successNode) {
generate(successNode, currentBlock);
});
Expand Down

0 comments on commit a19e163

Please sign in to comment.