fn bork_point(compressed: &mut CompressedEdwardsY, dist: &WeightedIndex<usize>) -> bool {
        if dist.sample(&mut rand::thread_rng()) == 1 {
            let bit = 1 << 2;
            compressed.0[0] ^= bit;

            return true;
        }

        false
    }
Flips a bit in the compressed point with probability 0.1.

Returns true if a bit was flipped. With probability .5 this is not a valid compressed point.
patch-testing/curve25519-dalek/src/lib.rs