[Mlir-commits] [mlir] [MLIR][Standalone] don't register everything (PR #157688)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Tue Sep 9 09:02:54 PDT 2025


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- mlir/examples/standalone/python/StandaloneExtensionNanobind.cpp mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/mlir/examples/standalone/python/StandaloneExtensionNanobind.cpp b/mlir/examples/standalone/python/StandaloneExtensionNanobind.cpp
index 3dc067377..f4cf51198 100644
--- a/mlir/examples/standalone/python/StandaloneExtensionNanobind.cpp
+++ b/mlir/examples/standalone/python/StandaloneExtensionNanobind.cpp
@@ -25,7 +25,8 @@ NB_MODULE(_standaloneDialectsNanobind, m) {
   standaloneM.def(
       "register_dialects",
       [](MlirContext context, bool load) {
-        MlirDialectHandle standaloneHandle = mlirGetDialectHandle__standalone__();
+        MlirDialectHandle standaloneHandle =
+            mlirGetDialectHandle__standalone__();
         MlirDialectHandle arithHandle = mlirGetDialectHandle__arith__();
         mlirDialectHandleRegisterDialect(standaloneHandle, context);
         mlirDialectHandleRegisterDialect(arithHandle, context);
diff --git a/mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp b/mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp
index 02f23d758..99ad87b29 100644
--- a/mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp
+++ b/mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp
@@ -24,7 +24,8 @@ PYBIND11_MODULE(_standaloneDialectsPybind11, m) {
   standaloneM.def(
       "register_dialects",
       [](MlirContext context, bool load) {
-        MlirDialectHandle standaloneHandle = mlirGetDialectHandle__standalone__();
+        MlirDialectHandle standaloneHandle =
+            mlirGetDialectHandle__standalone__();
         MlirDialectHandle arithHandle = mlirGetDialectHandle__arith__();
         mlirDialectHandleRegisterDialect(standaloneHandle, context);
         mlirDialectHandleRegisterDialect(arithHandle, context);

``````````

</details>


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


More information about the Mlir-commits mailing list