Updated rearrangements detection.