[minor] Document that replaceSlice returns a new array