mirror of
https://github.com/dlang/phobos.git
synced 2025-05-05 09:30:49 +03:00
Fix to Map caused by changes to hasSlicing.
import std.algorithm; import std.range; void main() { auto N2 = sequence!"n"(cast(size_t)1).map!"a"; } ceased to compile, because Map's opSlice won't work anymore over infinite ranges, because the result can't be reassigned to the original.
This commit is contained in:
parent
0d9b31b594
commit
57ddea7cf2
1 changed files with 1 additions and 1 deletions
|
@ -451,7 +451,7 @@ private struct MapResult(alias fun, Range)
|
|||
alias length opDollar;
|
||||
}
|
||||
|
||||
static if (hasSlicing!R)
|
||||
static if (!isInfinite!R && hasSlicing!R)
|
||||
{
|
||||
static if (is(typeof(_input[ulong.max .. ulong.max])))
|
||||
private alias ulong opSlice_t;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue