Cast between address spaces via an intermediate integer