add a const version of stripPointerCasts