[Mlir-commits] [mlir] ab32f5b - Apply clang-tidy fixes for readability-simplify-boolean-expr in BufferizableOpInterfaceImpl.cpp (NFC)

Mehdi Amini llvmlistbot at llvm.org
Wed Dec 28 14:42:55 PST 2022


Author: Mehdi Amini
Date: 2022-12-28T22:42:39Z
New Revision: ab32f5b7ef7ff203ecf2afe31b85f4ebd102d366

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

LOG: Apply clang-tidy fixes for readability-simplify-boolean-expr in BufferizableOpInterfaceImpl.cpp (NFC)

Added: 
    

Modified: 
    mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp b/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
index 3c634e9b0f9ce..5d0d44f3c53d6 100644
--- a/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
+++ b/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
@@ -646,10 +646,8 @@ static bool matchesInsertDestination(const AnalysisState &state, Value value,
         return true;
     return false;
   };
-  if (llvm::all_of(state.findValueInReverseUseDefChain(value, matchesSlice),
-                   matchesSlice))
-    return true;
-  return false;
+  return static_cast<bool>(llvm::all_of(
+      state.findValueInReverseUseDefChain(value, matchesSlice), matchesSlice));
 }
 
 template <typename OpTy>


        


More information about the Mlir-commits mailing list