Add type stub for SymInt.rsub (#138543)

Fixes https://github.com/pytorch/pytorch/issues/138478

Signed-off-by: Edward Z. Yang <ezyang@meta.com>
Pull Request resolved: https://github.com/pytorch/pytorch/pull/138543
Approved by: https://github.com/malfet
This commit is contained in:
Edward Z. Yang 2024-10-21 19:50:13 -07:00 committed by PyTorch MergeBot
parent 8c840fb921
commit 1b61313acd

View file

@ -522,6 +522,9 @@ class SymInt:
def __sub__(self, other: "IntLikeType") -> "SymInt":
raise TypeError("type stub not overridden")
def __rsub__(self, other: "IntLikeType") -> "SymInt":
raise TypeError("type stub not overridden")
def __repr__(self):
return self.node._graph_repr()