use getPointerType throughout