mirror of
https://github.com/boostorg/algorithm.git
synced 2025-07-01 15:00:59 +02:00
More general fix for vc8.0
[SVN r24765]
This commit is contained in:
@ -125,16 +125,8 @@ namespace boost {
|
||||
ForwardIteratorT SegmentEnd )
|
||||
|
||||
{
|
||||
if(InsertIt!=SegmentBegin)
|
||||
{
|
||||
// Call replace to do the job
|
||||
replace( Input, InsertIt, SegmentBegin, Storage );
|
||||
}
|
||||
else
|
||||
{
|
||||
// Call insert to do the job
|
||||
insert( Input, InsertIt, Storage );
|
||||
}
|
||||
// Call replace to do the job
|
||||
replace( Input, InsertIt, SegmentBegin, Storage );
|
||||
// Empty the storage
|
||||
Storage.clear();
|
||||
// Iterators were not changed, simply return the end of segment
|
||||
|
@ -172,7 +172,14 @@ namespace boost {
|
||||
BOOST_STRING_TYPENAME InputT::iterator To,
|
||||
const InsertT& Insert )
|
||||
{
|
||||
replace( Input, From, To, begin(Insert), end(Insert) );
|
||||
if(From!=To)
|
||||
{
|
||||
replace( Input, From, To, begin(Insert), end(Insert) );
|
||||
}
|
||||
else
|
||||
{
|
||||
insert( Input, From, begin(Insert), end(Insert) );
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace detail
|
||||
|
Reference in New Issue
Block a user