[Mlir-commits] [mlir] [mlir][python] Add normalforms to capture preconditions of transforms (PR #79449)

Maksim Levental llvmlistbot at llvm.org
Thu Jan 25 11:46:48 PST 2024


================
@@ -42,6 +44,46 @@ def __init__(
         super().__init__(v)
         self.parent = parent
         self.children = children if children is not None else []
+        self._normalform = Normalform
+
+    @property
+    def normalform(self) -> Type["Normalform"]:
----------------
makslevental wrote:

Just curious - I see this is techinically `typing.Type[ForwardRef('Normalform')]` but is this different from just writing `"Normalform"`?

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


More information about the Mlir-commits mailing list