[Mlir-commits] [mlir] [MLIR][Python] add type hints for accessors	(PR #158455)
    Sergei Lebedev 
    llvmlistbot at llvm.org
       
    Mon Sep 15 02:18:01 PDT 2025
    
    
  
================
@@ -44,7 +44,7 @@ _ods_ir = _ods_cext.ir
 _ods_cext.globals.register_traceback_file_exclusion(__file__)
 
 import builtins
-from typing import Sequence as _Sequence, Union as _Union
+from typing import Sequence as _Sequence, Union as _Union, Optional as _Optional
----------------
superbobry wrote:
Nit: I think you can use `|` for both `Union` and `Optional`. We were doing that in the hand-written ir.pyi.
https://github.com/llvm/llvm-project/pull/158455
    
    
More information about the Mlir-commits
mailing list