2014-02-26  Tim Shen  <timshen91@gmail.com>

	* include/bits/regex.tcc (match_results<>::format,
	regex_replace<>): Update __out after calling std::copy.
	* testsuite/28_regex/algorithms/regex_replace/char/dr2213.cc:
	Add testcase.
	* testsuite/28_regex/match_results/format.cc: Likewise.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208179 138bc75d-0d04-0410-961f-82ee72b054a4