Commit graph

111 commits

Author SHA1 Message Date
Dmitry Olshansky
4d19d0ad3a Fix issue 17066 2017-01-17 23:07:56 +01:00
Eduard Staniloiu
3d98191ce9 Fix issue 16970 - Fix deprecations and warnings when compiling Phobos 2016-12-27 15:57:20 +02:00
Sebastian Wilzbach
f903de7bc6 Fix issue 16255 - std.algorithm.iteration.each on opApply doesn't support ref 2016-12-23 23:46:37 +01:00
Andrei Alexandrescu
428217b317 Merge pull request #4961 from edi33416/uniq_consistency
Fix issue 16588 - uniqs BidirectionalRange behavior is inconsistent w…
2016-12-19 14:58:51 -05:00
Eduard Staniloiu
e1c5362995 Add tests for empty range 2016-12-19 20:50:59 +02:00
Eduard Staniloiu
b9d271d52c Remove picking policy 2016-12-19 20:02:11 +02:00
Eduard Staniloiu
a502b2a254 Fix issue 16588 - uniqs BidirectionalRange behavior is inconsistent with its InputRange behavior 2016-12-16 18:05:37 +02:00
Sebastian Wilzbach
cc7f125ed1 Add missing imports to public unittests 2016-12-15 23:23:35 +01:00
Sebastian Wilzbach
b82ae35fd7 Use void for auto function without return statement 2016-12-08 12:32:14 +01:00
Ilya Yaroshenko
b6f03d4b89 Revert "Add new function std.algorithm.iteration : cumulativeSum" 2016-11-10 08:38:43 +02:00
Steven Schveighoffer
c41e41d961 Fix grammar nit 2016-11-08 15:51:40 -05:00
e-y-e
c5df83f912 Tweak unittests 2016-11-07 18:03:47 +00:00
e-y-e
9a64320e00 Fix documentation errors 2016-11-07 17:39:34 +00:00
e-y-e
aa74a62937 Add std.algorithm.iteration : cumulativeSum 2016-11-07 17:39:34 +00:00
Vladimir Panteleev
d6572c2a44 Fix Issue 16587 - split("", "x") should be ""
This reverts commit b438bf5a06.
2016-10-03 22:30:00 +00:00
Jack Stouffer
67d44e4cdc Remove package wide std.algorithm imports from Phobos 2016-09-22 08:36:14 +01:00
Andrei Alexandrescu
288c21b78b Merge pull request #4775 from NVolcz/patch-2
Removed debug lines from example unittest
2016-09-16 19:28:22 -04:00
Walter Bright
55e5737525 add 'scope' to opApply() parameter 2016-09-14 19:41:41 -07:00
NVolcz
afc7ae9bb3 Removed debug lines from example unittest
The example for ´´´auto joiner(RoR)(RoR r)´´´ includes a scoped debug line. This line is not relevant in an example unittest.
https://dlang.org/phobos/std_algorithm_iteration.html#joiner
2016-09-12 11:22:26 +02:00
Jack Stouffer
c5d537f06e Fix spelling mistake in iteration.d 2016-08-24 15:45:47 -04:00
Sebastian Wilzbach
d7a18dc52e add unittest attributes to std.algorithm.iteration 2016-07-29 12:25:22 +02:00
Ilya Yaroshenko
efe33e3470 fix docs in iteration
`sum` is not precise. Precise algorithms are Python `fsum` and Mir's [`sum!(Summation.precise)`](http://docs.mir.dlang.io/latest/mir_sum.html)
2016-07-26 10:07:42 +02:00
Andrei Alexandrescu
cd68d1a582 Merge pull request #4603 from JackStouffer/cache
Enhanced cache and map to provide length info for their slices
2016-07-15 16:45:30 -04:00
Jack Stouffer
fcb57098d1 Enhanced cache and map to provide length info for their slices 2016-07-14 14:03:25 -04:00
Jack Stouffer
c9222e1ecc Added messages to asserts in std.algorithm.iteration 2016-07-14 13:16:23 -04:00
Steven Schveighoffer
c74537000c Fix all windows cycles 2016-07-08 21:07:15 -04:00
Jack Stouffer
6b22c63c5b Enable long line checks in travis 2016-07-02 01:10:29 -04:00
Jack Stouffer
268fa2538d Add some const and immutable to std.algorithm 2016-07-01 17:11:09 -04:00
Jack Stouffer
ad7dbaa050 Fixed Issue 14485: .front of empty filtered zip range is accessible 2016-06-28 09:48:56 -04:00
Andrei Alexandrescu
e59c06b410 Merge pull request #4431 from wilzbach/document_std_algorithm_test
add external imports to documented unittests in std.algorithm
2016-06-18 06:38:44 -04:00
Andrei Alexandrescu
ac9c93cb9e Merge pull request #4315 from wilzbach/algorithms_private_cleanup
std.algorithm: set accidentally exposed methods to private
2016-06-18 04:27:58 -04:00
Andrei Alexandrescu
7172eda466 Merge pull request #4327 from tsbockman/isPowerOf2
Add `std.math.isPowerOf2()`. Supports floating-point and integers.
2016-06-16 23:09:02 -04:00
Sebastian Wilzbach
ec47ac4224 Remove the WEB macro in favor of HTTP
replacement: sed 's/\$(WEB/\$(HTTP/g' -i **/*.d
2016-06-16 00:14:51 +02:00
Sebastian Wilzbach
8b60ec24b0 add external imports to documented unittests in std.algorithm 2016-06-15 03:42:28 +02:00
tsbockman
18d1b436e4 Update Phobos to use the new std.math.isPowerOf2() everywhere.
`std.uni` looks like it may depend upon its local `isPowerOf2()` implementation
to return `true` for `0`. Since the semantics are different from the standard
version, I have renamed it to `isPow2OrZero()` to avoid confusion.
2016-06-04 21:19:38 -07:00
Sebastian Wilzbach
0c100a7b5a std.algorithm: set accidentally exposed methods to private 2016-06-04 16:13:07 +02:00
Steven Schveighoffer
e216c10b2c Merge pull request #4383 from JackStouffer/issue16073
Partial Fix for Issue 16073
2016-06-02 14:30:24 -04:00
Jack Stouffer
a818c7e059 [Issue 16073] Fix incorrect uses of random access range primitives in std.algorithm.iteration 2016-06-02 09:31:01 -04:00
Sebastian Wilzbach
ca098c57d2 manual allman brace fixup 2016-05-31 13:07:53 +02:00
Sebastian Wilzbach
1d34a121e9 apply all-man braces in Phobos
// find common cases
sed -E "s/^(\s*)((if|static if|for|foreach|foreach_reverse|while|unittest|switch|else|version).*)\s*\{$/\1\2\n\1{/" -i **/*.d
// catch else-if
sed -E "s/^(\s*)} (else static if| if|else if|else)(.*)\s*\{$/\1}\n\1\2\3\n\1{/" -i **/*.d
// remove created trailing whitespace
sed -i 's/[ \t]*$//' **/*.d
2016-05-31 13:07:53 +02:00
Sebastian Wilzbach
2dfbc51f17 Standardize whitespace after imports
Unified with:

sed -E "s/import\s*([^ ]+)\s*:\s*(.*(,|;))/import \1 : \2/" -i **/*.d
2016-05-29 22:09:56 +02:00
anonymous
641d6ff8d7 clean up remaining XREFs (manual)
Found by: grep -r '$(XREF'

std.experimental.allocator has a custom XREF2. Leaving that as is for now.
2016-05-27 21:40:46 +02:00
anonymous
ef9722928c XREF_PACK_NAMED -> REF_ALTTEXT (sed)
Done by:

arg='\s*([^(),]*)'
from='\$\(XREF_PACK_NAMED\s'$arg','$arg','$arg','$arg'\)'
to='$(REF_ALTTEXT \4, \3, std,\1,\2)'
(find . -type f -name "*.d" -print0; \
    find . -type f -name "*.dd" -print0) | \
xargs -0 sed -i -r "s/$from/$to/g"
2016-05-27 21:32:46 +02:00
anonymous
d648f9320e XREF_PACK -> REF (sed)
Done by:

from='\$\(XREF_PACK\s+([^(),]*),\s*([^(),]*),\s*([^(),]*)\)'
to='$(REF \3, std,\1,\2)'
(find . -type f -name "*.d" -print0; \
    find . -type f -name "*.dd" -print0) | \
xargs -0 sed -i -r "s/$from/$to/g"
2016-05-27 21:32:46 +02:00
anonymous
764caefa36 XREF -> REF (sed)
Done by:

(find . -type f -name "*.d" -print0; \
    find . -type f -name "*.dd" -print0) | \
xargs -0 sed -i -r \
    's/\$\(XREF\s+([^(),]*),\s*([^(),]*)\)/$(REF \2, std,\1)/g'
2016-05-27 21:32:46 +02:00
Sebastian Wilzbach
614294cd70 remove whitespace in ddoc output of std/algorithm 2016-05-25 03:57:01 +02:00
Vladimir Panteleev
38a6370788 Merge pull request #4303 from wilzbach/mref_phobos
use mref macro instead of link2
2016-05-24 03:12:08 +03:00
Sebastian Wilzbach
89a2dd5f11 use mref macro instead of link2 2016-05-16 03:30:08 +03:00
Sebastian Wilzbach
b8f17e2531 std.algorithms: document public methods 2016-05-12 17:53:03 +03:00
Jack Stouffer
3890f5d804 Fixed long lines in std/algorithm/iteration.d 2016-05-10 20:51:39 -04:00