forked from OSchip/llvm-project
Update upgrade some uses of mlir::interleave API to take container argument directly.
PiperOrigin-RevId: 273446814
This commit is contained in:
parent
a8a73f0640
commit
780f107a57
|
@ -632,15 +632,11 @@ static LogicalResult verify(YieldOp op) {
|
|||
static void printLinalgLibraryOp(OpAsmPrinter &p, Operation *op) {
|
||||
assert(op->getAbstractOperation() && "unregistered operation");
|
||||
p << op->getName().getStringRef() << "(";
|
||||
interleave(
|
||||
op->getOperands().begin(), op->getOperands().end(),
|
||||
[&](Value *v) { p << *v; }, [&]() { p << ", "; });
|
||||
interleaveComma(op->getOperands(), p, [&](Value *v) { p << *v; });
|
||||
p << ")";
|
||||
p.printOptionalAttrDict(op->getAttrs());
|
||||
p << " : ";
|
||||
interleave(
|
||||
op->getOperands().begin(), op->getOperands().end(),
|
||||
[&](Value *v) { p << v->getType(); }, [&]() { p << ", "; });
|
||||
interleaveComma(op->getOperands(), p, [&](Value *v) { p << v->getType(); });
|
||||
}
|
||||
|
||||
static ParseResult parseLinalgLibraryOp(OpAsmParser &parser,
|
||||
|
|
|
@ -394,7 +394,7 @@ public:
|
|||
|
||||
template <typename Container, typename UnaryFunctor>
|
||||
inline void interleaveComma(const Container &c, UnaryFunctor each_fn) const {
|
||||
interleave(c.begin(), c.end(), each_fn, [&]() { os << ", "; });
|
||||
mlir::interleaveComma(c, os, each_fn);
|
||||
}
|
||||
|
||||
void print(ModuleOp module);
|
||||
|
|
Loading…
Reference in New Issue