An immunosurveillance mechanism controls cancer cell ploidy