Replace dual array-add implementation with a single optionally-copying one.