Implement `Tern.diff`