use splice for diff