[Mlir-commits] [mlir] [MLIR] Add 'const' qualifier to some functions (PR #72430)

Mehdi Amini llvmlistbot at llvm.org
Wed Nov 15 22:54:37 PST 2023


================
@@ -182,10 +182,10 @@ class Value {
   /// Replace all uses of 'this' value with 'newValue' if the given callback
   /// returns true.
   void replaceUsesWithIf(Value newValue,
-                         function_ref<bool(OpOperand &)> shouldReplace);
+                         function_ref<bool(OpOperand &)> shouldReplace) const;
----------------
joker-eph wrote:

Is this is particularly wrong: this API is actually modifying the Value.

https://github.com/llvm/llvm-project/pull/72430


More information about the Mlir-commits mailing list