mirror of
https://github.com/dlang/phobos.git
synced 2025-04-30 07:00:37 +03:00
Issue 8829 - std.algorithm.find fails to take advantage of SortedRange
This commit is contained in:
parent
8b29f206ae
commit
d6519853e1
1 changed files with 1 additions and 1 deletions
|
@ -1857,7 +1857,7 @@ if (isRandomAccessRange!R1 && hasLength!R1 && hasSlicing!R1 && isBidirectionalRa
|
|||
if(needle.empty())
|
||||
return haystack[partitions[0].length + partitions[1].length - count .. $];
|
||||
}
|
||||
else if (isRandomAccessRange!R2)
|
||||
static if (isRandomAccessRange!R2)
|
||||
{
|
||||
immutable lastIndex = needleLength - 1;
|
||||
auto last = needle[lastIndex];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue