Change mergetool to use splice