OSDN Git Service

Use .empty() instead of .size() == 0 (NFC)
authorMehdi Amini <joker.eph@gmail.com>
Sat, 30 May 2020 03:36:22 +0000 (03:36 +0000)
committerMehdi Amini <joker.eph@gmail.com>
Sat, 30 May 2020 03:36:22 +0000 (03:36 +0000)
Cleanup / Fix a clang-tidy warning

mlir/lib/Transforms/BufferPlacement.cpp

index 60f49d4..337e26e 100644 (file)
@@ -392,7 +392,7 @@ struct BufferPlacementPass
       // If the Dealloc position is at the terminator operation of the block,
       // then the value should escape from a deallocation.
       if (!nextOp) {
-        assert(deallocs.size() == 0 &&
+        assert(deallocs.empty() &&
                "There should be no dealloc for the returned buffer");
         continue;
       }