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

Update TypeUpdating for exact heap types #7452

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

tlively
Copy link
Member

@tlively tlively commented Apr 4, 2025

Preserve exactness while updating the underlying heap type definitions
when copying old types into the new builder. Also fall back to updating
the underlying heap type definition while preserving exactness when when
updating the module's types if the mapping does not contain an explicit
mapping for an exact type.

Preserve exactness while updating the underlying heap type definitions
when copying old types into the new builder. Also fall back to updating
the underlying heap type definition while preserving exactness when when
updating the module's types if the mapping does not contain an explicit
mapping for an exact type.
@tlively tlively requested a review from kripken April 4, 2025 20:22
Copy link
Member

@kripken kripken left a comment

Choose a reason for hiding this comment

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

lgtm with suggestion

if (iter != oldToNewTypes.end()) {
return iter->second.with(Exact);
}
}
Copy link
Member

Choose a reason for hiding this comment

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

It might be a little more efficient and perhaps clear if we put the normal path and the exact path in separate if arms? That is, there is no need to try the normal path first before the exact one, if we are exact, IIANM

Copy link
Member Author

Choose a reason for hiding this comment

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

I was thinking that it would be nice to have the flexibility to map exact types to inexact types, but I think YAGNI is the correct response here. Will fix.

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.

2 participants