[Mlir-commits] [mlir] [mlir][Transform] Add a transform.match.operation_empty op to allow s… (PR #68319)

Oleksandr Alex Zinenko llvmlistbot at llvm.org
Thu Oct 5 10:32:46 PDT 2023


================
@@ -30,20 +62,22 @@ class SingleOpMatcherOpTrait
 public:
   static LogicalResult verifyTrait(Operation *op) {
     static_assert(llvm::is_detected<has_get_operand_handle, OpTy>::value,
-                  "SingleOpMatcherOpTrait expects operation type to have the "
-                  "getOperandHandle() method");
+                  "AtMostOneOpMatcherOpTrait/SingleOpMatcherOpTrait expects "
+                  "operation type to have the getOperandHandle() method");
     static_assert(llvm::is_detected<has_match_operation, OpTy>::value,
-                  "SingleOpMatcherOpTrait expected operation type to have the "
-                  "matchOperation(Operation *, TransformResults &, "
-                  "TransformState &) method");
+                  "AtMostOneOpMatcherOpTrait/SingleOpMatcherOpTrait expected "
+                  "operation type to have the matchOperation(Operation *, "
+                  "TransformResults &, TransformState &) method");
----------------
ftynse wrote:

I suspect `has_match_operation` should be updated to accept the cases taking nullopt. And so does the error message.

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


More information about the Mlir-commits mailing list