Avoid using the copy_nonoverlapping wrapper through mem::replace.
#87827
+47
−30
copy_nonoverlapping wrapper through mem::replace.
#87827