You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SSAValue.erase() raises a generic exception "Attempting to delete SSA value that still has uses."
It would be more useful if it also printed out the specific operation.
This can be achieved by:
def erase(self, safe_erase: bool = True) -> None:
"""
Erase the value.
If safe_erase is True, then check that no operations use the value anymore.
If safe_erase is False, then replace its uses by an ErasedSSAValue.
"""
if safe_erase and len(self.uses) != 0:
raise Exception(
f"Attempting to delete SSA value that still has uses: {self}")
self.replace_by(ErasedSSAValue(self.typ))
The text was updated successfully, but these errors were encountered:
SSAValue.erase() raises a generic exception "Attempting to delete SSA value that still has uses."
It would be more useful if it also printed out the specific operation.
This can be achieved by:
The text was updated successfully, but these errors were encountered: