Merging in DP code