Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug[next]: fix _Dedup for tuples in type_inference #1495

Merged
merged 2 commits into from
Mar 15, 2024

Conversation

havogt
Copy link
Contributor

@havogt havogt commented Mar 15, 2024

No description provided.

@havogt havogt changed the title bug[next]: remove obsolete call to _Dedup bug[next]: fix _Dedup in type_inference Mar 15, 2024
@havogt havogt changed the title bug[next]: fix _Dedup in type_inference bug[next]: fix _Dedup for tuples in type_inference Mar 15, 2024
@havogt havogt merged commit ee17241 into GridTools:main Mar 15, 2024
31 checks passed
@havogt havogt deleted the type_inference_bug branch March 15, 2024 11:00
@@ -142,11 +142,10 @@ def _free_variables(x: Type) -> set[TypeVar]:
class _Dedup(eve.NodeTranslator):
"""Deduplicate type nodes that have the same value but a different `id`."""

def visit(self, node, *, memo: dict[T, T]) -> typing.Any: # type: ignore[override]
def visit(self, node: Type | typing.Sequence[Type], *, memo: dict[Type, Type]) -> typing.Any: # type: ignore[override]
Copy link
Contributor

@egparedes egparedes Mar 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typing.Sequence is deprecated and should be replacedby collections.abc.Sequence

edopao pushed a commit to edopao/gt4py that referenced this pull request Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants