[Mlir-commits] [mlir] [mlir] Fix CallOpInterface extraClassDeclaration (PR #81258)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Fri Feb 9 07:53:08 PST 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-mlir

Author: Richard Dzenis (RIscRIpt)

<details>
<summary>Changes</summary>

`extraClassDeclaration` of `CallOpInterface` can be inherited by other `OpInterfaces` into foreign namespaces, thus types must be fully qualified to prevent compiler errors, for example:

    def MyCaller : OpInterface<"MyCaller", [CallOpInterface]> {
        let cppNamespace = "::MyNamespace";
    }

---
Full diff: https://github.com/llvm/llvm-project/pull/81258.diff


1 Files Affected:

- (modified) mlir/include/mlir/Interfaces/CallInterfaces.td (+1-1) 


``````````diff
diff --git a/mlir/include/mlir/Interfaces/CallInterfaces.td b/mlir/include/mlir/Interfaces/CallInterfaces.td
index 3e9c002b22ed69..752de74e6e4d7e 100644
--- a/mlir/include/mlir/Interfaces/CallInterfaces.td
+++ b/mlir/include/mlir/Interfaces/CallInterfaces.td
@@ -68,7 +68,7 @@ def CallOpInterface : OpInterface<"CallOpInterface"> {
     /// `symbolTable` is an optional parameter that will allow for using a
     /// cached symbol table for symbol lookups instead of performing an O(N)
     /// scan.
-    Operation *resolveCallable(SymbolTableCollection *symbolTable = nullptr);
+    ::mlir::Operation *resolveCallable(::mlir::SymbolTableCollection *symbolTable = nullptr);
   }];
 }
 

``````````

</details>


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


More information about the Mlir-commits mailing list