basectx is the only type in the repo having int implemented.
This magic method can result in unexpected coercion. Furthermore,
having it implemented is wrong for some contexts, since rev() may
return None in some cases.
Previous commits removed known cases in core where contexts are
coerced to integers. So let's delete basectx.int.
This commit is a bit dangerous. While the test suite passes, there
are likely still some callers in core that rely on int that
don't have test coverage. An alternative would be to issue a
deprecation warning and let this bake for a few releases.
.. api::
context.basectx no longer implements __int__. Context instances will no longer cast to ints. Consumers should call ``ctx.rev()`` instead.