[Mlir-commits] [mlir] 9bb9206 - [MLIR] Apply clang-tidy fixes for readability-container-size-empty in VectorTransforms.cpp (NFC)

Mehdi Amini llvmlistbot at llvm.org
Sun Aug 31 02:10:04 PDT 2025


Author: Mehdi Amini
Date: 2025-08-31T02:09:27-07:00
New Revision: 9bb9206d8e50ffcc6e1d6f18b577a1603429358c

URL: https://github.com/llvm/llvm-project/commit/9bb9206d8e50ffcc6e1d6f18b577a1603429358c
DIFF: https://github.com/llvm/llvm-project/commit/9bb9206d8e50ffcc6e1d6f18b577a1603429358c.diff

LOG: [MLIR] Apply clang-tidy fixes for readability-container-size-empty in VectorTransforms.cpp (NFC)

Added: 
    

Modified: 
    mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp b/mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp
index 023c4da7dffdf..dbb5eb398fae6 100644
--- a/mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp
+++ b/mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp
@@ -600,7 +600,7 @@ struct BubbleDownVectorBitCastForExtract
 
     // Get the first element of the mixed position as integer.
     auto mixedPos = extractOp.getMixedPosition();
-    if (mixedPos.size() > 0 && !isa<Attribute>(mixedPos[0]))
+    if (!mixedPos.empty() && !isa<Attribute>(mixedPos[0]))
       return failure();
     uint64_t index = cast<IntegerAttr>(cast<Attribute>(mixedPos[0])).getInt();
 


        


More information about the Mlir-commits mailing list