diff --git a/mlir/include/mlir/Dialect/Complex/IR/ComplexOps.td b/mlir/include/mlir/Dialect/Complex/IR/ComplexOps.td index c31092a1a008..930d76884801 100644 --- a/mlir/include/mlir/Dialect/Complex/IR/ComplexOps.td +++ b/mlir/include/mlir/Dialect/Complex/IR/ComplexOps.td @@ -152,7 +152,9 @@ def ImOp : Complex_Op<"im", //===----------------------------------------------------------------------===// def EqualOp : Complex_Op<"eq", - [NoSideEffect, AllTypesMatch<["lhs", "rhs"]>]> { + [NoSideEffect, AllTypesMatch<["lhs", "rhs"]>, + DeclareOpInterfaceMethods] # + ElementwiseMappable.traits> { let summary = "computes whether two complex values are equal"; let description = [{ The `eq` op takes two complex numbers and returns whether they are equal. @@ -194,7 +196,9 @@ def MulOp : ComplexArithmeticOp<"mul"> { //===----------------------------------------------------------------------===// def NotEqualOp : Complex_Op<"neq", - [NoSideEffect, AllTypesMatch<["lhs", "rhs"]>]> { + [NoSideEffect, AllTypesMatch<["lhs", "rhs"]>, + DeclareOpInterfaceMethods] # + ElementwiseMappable.traits> { let summary = "computes whether two complex values are not equal"; let description = [{ The `neq` op takes two complex numbers and returns whether they are not