mirror of
https://github.com/dlang/phobos.git
synced 2025-05-05 17:42:58 +03:00
Improve std.algorithm.splitter popBack
This commit is contained in:
parent
ee22cb65a7
commit
de314252bc
1 changed files with 1 additions and 9 deletions
|
@ -2329,15 +2329,7 @@ if (is(typeof(ElementType!Range.init == Separator.init))
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
_input = _input[0 .. _input.length - _backLength];
|
_input = _input[0 .. _input.length - _backLength - _separatorLength];
|
||||||
if (!_input.empty && _input.back == _separator)
|
|
||||||
{
|
|
||||||
_input.popBack();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
assert(false);
|
|
||||||
}
|
|
||||||
_backLength = _unComputed;
|
_backLength = _unComputed;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue