File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
mlir/lib/Dialect/LLVMIR/IR Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -2240,23 +2240,21 @@ static LogicalResult verifyComdat(Operation *op,
22402240
22412241static LogicalResult verifyBlockTags (LLVMFuncOp funcOp) {
22422242 llvm::DenseSet<BlockTagAttr> blockTags;
2243- LogicalResult r = success ();
22442243 // Note that presence of `BlockTagOp`s currently can't prevent an unrecheable
22452244 // block to be removed by canonicalizer's region simplify pass, which needs to
22462245 // be dialect aware to allow extra constraints to be described.
2247- funcOp.walk ([&](BlockTagOp blockTagOp) {
2246+ WalkResult res = funcOp.walk ([&](BlockTagOp blockTagOp) {
22482247 if (blockTags.contains (blockTagOp.getTag ())) {
22492248 blockTagOp.emitError ()
22502249 << " duplicate block tag '" << blockTagOp.getTag ().getId ()
22512250 << " ' in the same function: " ;
2252- r = failure ();
22532251 return WalkResult::interrupt ();
22542252 }
22552253 blockTags.insert (blockTagOp.getTag ());
22562254 return WalkResult::advance ();
22572255 });
22582256
2259- return r ;
2257+ return failure (res. wasInterrupted ()) ;
22602258}
22612259
22622260// / Parse common attributes that might show up in the same order in both
You can’t perform that action at this time.
0 commit comments