mirror of
https://github.com/dlang/phobos.git
synced 2025-05-03 16:40:48 +03:00
Merge pull request #1015 from monarchdodra/spaces
Removing trailing spaces in algorithm
This commit is contained in:
commit
cc3176ab76
1 changed files with 72 additions and 79 deletions
|
@ -2248,7 +2248,6 @@ unittest
|
||||||
assert(equal(s.front, [1,2,3,4]));
|
assert(equal(s.front, [1,2,3,4]));
|
||||||
assert(equal(s.back, [6,7,8,9,10]));
|
assert(equal(s.back, [6,7,8,9,10]));
|
||||||
|
|
||||||
|
|
||||||
auto s2 = splitter(d, [4, 5]);
|
auto s2 = splitter(d, [4, 5]);
|
||||||
assert(equal(s2.front, [1,2,3]));
|
assert(equal(s2.front, [1,2,3]));
|
||||||
assert(equal(s2.back, [6,7,8,9,10]));
|
assert(equal(s2.back, [6,7,8,9,10]));
|
||||||
|
@ -3054,7 +3053,6 @@ private struct UniqResult(alias pred, Range)
|
||||||
@property bool empty() { return _input.empty; }
|
@property bool empty() { return _input.empty; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static if (isForwardRange!Range) {
|
static if (isForwardRange!Range) {
|
||||||
@property typeof(this) save() {
|
@property typeof(this) save() {
|
||||||
return typeof(this)(_input.save);
|
return typeof(this)(_input.save);
|
||||||
|
@ -4827,7 +4825,6 @@ unittest {
|
||||||
assert(r == ["def", "hij"]);
|
assert(r == ["def", "hij"]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* (Not yet documented.)
|
/* (Not yet documented.)
|
||||||
Consume all elements from $(D r) that are equal to one of the elements
|
Consume all elements from $(D r) that are equal to one of the elements
|
||||||
$(D es).
|
$(D es).
|
||||||
|
@ -8016,7 +8013,6 @@ private void quickSortImpl(alias less, Range)(Range r)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/+
|
/+
|
||||||
Tim Sort for Random-Access Ranges
|
Tim Sort for Random-Access Ranges
|
||||||
|
|
||||||
|
@ -8024,7 +8020,6 @@ private void quickSortImpl(alias less, Range)(Range r)
|
||||||
|
|
||||||
Authors: Xinok
|
Authors: Xinok
|
||||||
License: Public Domain
|
License: Public Domain
|
||||||
|
|
||||||
+/
|
+/
|
||||||
|
|
||||||
// Tim Sort implementation
|
// Tim Sort implementation
|
||||||
|
@ -8230,7 +8225,6 @@ private template TimSortImpl(alias pred, R)
|
||||||
range = range[firstElement .. lastElement];
|
range = range[firstElement .. lastElement];
|
||||||
mid -= firstElement;
|
mid -= firstElement;
|
||||||
|
|
||||||
|
|
||||||
if (mid == 0 || mid == range.length) return;
|
if (mid == 0 || mid == range.length) return;
|
||||||
|
|
||||||
// Call function which will copy smaller run into temporary memory
|
// Call function which will copy smaller run into temporary memory
|
||||||
|
@ -9362,7 +9356,6 @@ if (is(typeof(find!pred(haystack, needle))))
|
||||||
return !find!pred(haystack, needle).empty;
|
return !find!pred(haystack, needle).empty;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/++
|
/++
|
||||||
Returns the 1-based index of the first needle found in $(D haystack). If no
|
Returns the 1-based index of the first needle found in $(D haystack). If no
|
||||||
needle is found, then $(D 0) is returned.
|
needle is found, then $(D 0) is returned.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue