Python 2 has two integer datatypes int and long, and automatically converts between them as necessary, especially in order to avoid integer overflo
I don't know that there's a convenient way to do this natively because it's not normally considered a problem, so it's not something the python devs would want to build in. I think the way you're doing it is fine. You could even subclass the int built-in type and override the __add__(), __sub__(), etc operator methods to include your functionality, but that might be overkill.