Better typecasting for Utility::typecast