Skip to content

Commit

Permalink
[mlir][python] fix python build
Browse files Browse the repository at this point in the history
  • Loading branch information
Mogball committed Jan 12, 2023
1 parent d69e5df commit 80246b2
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions mlir/python/mlir/dialects/_memref_ops_ext.py
Expand Up @@ -4,7 +4,8 @@

try:
from ..ir import *
from ._ods_common import get_op_result_or_value as _get_op_result_or_value, get_op_results_or_values as _get_op_results_or_values
from ._ods_common import get_op_result_or_value as _get_op_result_or_value
from ._ods_common import get_op_results_or_values as _get_op_results_or_values
except ImportError as e:
raise RuntimeError("Error loading imports from extension module") from e

Expand All @@ -30,8 +31,6 @@ def __init__(self,
loc: user-visible location of the operation.
ip: insertion point.
"""
memref_resolved = _get_op_result_or_value(memref)
indices_resolved = [] if indices is None else _get_op_results_or_values(
indices)
return_type = MemRefType(memref_resolved.type).element_type
super().__init__(return_type, memref, indices_resolved, loc=loc, ip=ip)
super().__init__(memref, indices_resolved, loc=loc, ip=ip)

0 comments on commit 80246b2

Please sign in to comment.