fix imports 2

This commit is contained in:
Ilya Yaroshenko 2016-04-07 14:08:48 +02:00
parent df99fc8707
commit 95ea08d50b
3 changed files with 10 additions and 8 deletions

View file

@ -59,7 +59,7 @@ module std.algorithm.comparison;
// FIXME
import std.functional; // : unaryFun, binaryFun;
import std.range;
import std.range.primitives;
import std.traits;
// FIXME
import std.typecons; // : tuple, Tuple, Flag;
@ -1869,13 +1869,17 @@ bool isPermutation(alias pred = "a == b", Range1, Range2)
// also keeping track of the scanning index. If the first occurrence
// of item in the scanning loop has an index smaller than the current index,
// then you know that the element has been seen before
outloop: foreach (index, item; r1.save.enumerate)
size_t index;
outloop: for(auto r1s1 = r1.save; !r1s1.empty; r1s1.popFront, index++)
{
auto item = r1s1.front;
r1_count = 0;
r2_count = 0;
foreach (i, e; r1.save.enumerate)
size_t i;
for(auto r1s2 = r1.save; !r1s2.empty; r1s2.popFront, i++)
{
auto e = r1s2.front;
if (predEquals(e, item) && i < index)
{
continue outloop;

View file

@ -75,9 +75,6 @@ import std.traits : isArray, isBlitAssignable, isNarrowString, Unqual;
// FIXME
import std.typecons; // : tuple, Tuple;
// FIXME: somehow deleting this breaks the bringToFront() unittests.
import std.range;
// bringToFront
/**
The $(D bringToFront) function has considerable flexibility and
@ -114,7 +111,8 @@ See_Also:
size_t bringToFront(Range1, Range2)(Range1 front, Range2 back)
if (isInputRange!Range1 && isForwardRange!Range2)
{
import std.range: Take, take;
import std.range: take, Take;
import std.array: sameHead;
enum bool sameHeadExists = is(typeof(front.sameHead(back)));
size_t result;
for (bool semidone; !front.empty && !back.empty; )

View file

@ -78,7 +78,7 @@ module std.array;
import std.meta;
import std.traits;
import std.functional;
static import std.algorithm; // FIXME, remove with alias of splitter
static import std.algorithm.iteration; // FIXME, remove with alias of splitter
import std.range.primitives;
public import std.range.primitives : save, empty, popFront, popBack, front, back;