Vladiwostok
231ae8b68a
Fix D-Scanner linting issues ( #9070 )
...
* Fix UndocumentedDeclarationCheck linting issue
* Fix IfConstraintsIndentCheck linting issue
* Address feedback
* Fix publictests CI
* Fix old (libdparse) D-Scanner linting warn
2024-10-27 01:21:56 -07:00
Walter Bright
42b8c65ccf
CheckBy postblit should be scope
2024-02-12 09:24:07 +01:00
Dennis
fe33c84610
Merge pull request #8836 from ntrel/fold-docs
...
[std.algorithm] Improve `fold` docs
2023-11-20 17:36:06 +01:00
Nick Treleaven
7f06f2358a
Rename b
to e
for element in predicates
2023-10-31 17:40:45 +00:00
Nick Treleaven
2170bb37bc
Tweak seed description
2023-10-31 17:37:05 +00:00
Nick Treleaven
5762f3311b
Explain predicate signature
2023-10-31 17:26:48 +00:00
Nick Treleaven
f491d1f233
[std.algorithm] Improve fold
docs
...
Mention iteratively calling predicates in summary.
Use list to explain calling a single predicate with a seed.
Mention multiple results are produced in description.
Use list for see also.
Rename `seed` parameter `seeds` and fix docs.
Fix result docs when >1 predicate.
2023-10-30 16:17:24 +00:00
Per Nordlöw
578dfbfeb3
Correct spelling of Seperator to Separator in joiner()
2023-10-10 15:58:42 +02:00
Dennis
5cd77a6e32
User hyperlinks to refer to bugzilla issues ( #8766 )
2023-06-16 14:45:44 +03:00
Robert burner Schadek
e1f7edae57
Better std.algorithm.iteration.permutations error messages
2023-05-26 05:45:32 +02:00
FeepingCreature
656ae7905e
Fix issue 22785: joiner
should Unqual
child ranges. ( #8737 )
...
* Fix issue 22785: `joiner` should `Unqual` child ranges.
This allows use with `immutable T[][]` and similar.
---------
Co-authored-by: Petar Kirov <petar.p.kirov@gmail.com>
2023-04-20 01:59:19 +03:00
Robert burner Schadek
8546da5b04
Better std.algorithm.iteration.filter error messages
2023-02-21 10:17:22 +01:00
H. S. Teoh
08be61029e
Clarify that .uniq by default expects a sorted range.
2022-12-09 03:18:46 +01:00
The Dlang Bot
b026e490c4
Merge pull request #8580 from jamesragray/b18975
...
Make permutations into forward range.
Signed-off-by: Razvan Nitu <RazvanN7@users.noreply.github.com>
Signed-off-by: H. S. Teoh <quickfur@users.noreply.github.com>
Merged-on-behalf-of: Nicholas Wilson <thewilsonator@users.noreply.github.com>
2022-09-27 01:05:31 +02:00
james
872bb2cdb4
Fixed a typo in comment.
2022-09-26 22:49:44 +02:00
james
8744064c6f
Fix issue 23362: Permutations should be a forward range.
2022-09-23 22:39:15 +02:00
james
cd42a6a81f
Style fixes.
2022-09-21 23:10:20 +02:00
james
370f14af6d
Make permutations into forward range.
2022-09-21 23:00:20 +02:00
james
d2b8a15e69
Added unittest related to fix, and moved unittest related to issue to std/algorithm/iterartion.d
2022-09-19 22:27:22 +02:00
Walter Bright
cf3f60c359
iteration: use static class
2022-08-18 11:27:21 -07:00
Paul Backus
4d0e74ba1c
std.algorithm: improve documentation of filter ( #8514 )
...
std.algorithm: improve documentation of filter
Signed-off-by: Razvan Nitu <RazvanN7@users.noreply.github.com>
Merged-on-behalf-of: Petar Kirov <PetarKirov@users.noreply.github.com>
2022-07-24 20:19:21 +00:00
Mathis Beer
0a228d72a8
Fix issue 22561: Allow joiner to reassign range values that contain immutable fields.
2021-12-03 14:10:32 +01:00
Adam D. Ruppe
ff6920bd8a
Fix issue #22359 - joiner over an empty forward range object liable to segfault
...
If you pass it a range of class-based ranges, the initialization to
`typeof(_current).init` will be `null`. Calling the `save` method
on `null` will naturally be a memory violation. This generic check
will handle null without harming any other type since save of any
init value will be another init value.
2021-10-07 10:34:35 -04:00
Johan Engelen
93ccfd21c3
Remove unused and inaccessible std.iteration.algorithm.aggregate(...)
2021-09-04 12:09:48 +00:00
Ate Eskola
eea0174127
Extra commenting on postblits, and removed needless trusted lambda
2021-08-30 16:14:53 +03:00
Ate Eskola
41355cd4e3
Partially solve issue 18161. splitWhen and chunkBy when using forward ranges is now safe
2021-08-25 22:52:40 +03:00
vladchicos
bbfe30a671
Add clarifications
2021-08-12 05:09:14 +03:00
vladchicos
cba0b3f813
Added more unittests
2021-08-12 05:09:14 +03:00
vladchicos
7a715fe687
Fix for popBack/popFront
...
popBack/popFront works for RoRs starting and/or ending with empty items
2021-08-12 05:09:14 +03:00
vladchicos
e32b635f05
Added more unittests
2021-08-12 05:09:14 +03:00
vladchicos
68dab0e2e5
Fix Issue 19727 - std.algorithm.endsWith fails to compile while startsWith succeeds.
2021-08-12 05:09:14 +03:00
berni44
b2019ebab0
Narrow imports of std.math in the rest of phobos.
2021-04-21 03:00:57 +02:00
Robert Aron
d8f3d3a815
Add splitter functionality that allows to keep the sentinels
...
Signed-off-by: Robert Aron <aronrobert293@gmail.com>
Update the Return: section of DDoc
Fix whitespace
2021-04-21 00:33:22 +02:00
Nick Treleaven
899601aa35
Fix assigning size_t to int for "a=i"
2021-03-19 16:18:29 +00:00
Nick Treleaven
18a647bed4
Add separate example for each
with index
...
Remove doc-comment for example that wasn't as clear.
2021-03-19 14:14:09 +00:00
Nick Treleaven
1af0e4d5e9
std.algorithm: tweak each
examples
...
Make first example @safe.
Split opApply example into separate block.
2021-03-19 14:08:37 +00:00
Ate Eskola
d944ca79a5
Fix Issue 13595 - added splitWhen ( #7794 )
...
Fix Issue 13595 - added splitWhen
merged-on-behalf-of: Razvan Nitu <RazvanN7@users.noreply.github.com>
2021-03-18 15:27:34 +01:00
Boris Carvajal
276053dd07
Remove a few uses of fully qualified names that rely on a DMD bug
2021-02-22 08:16:13 -03:00
Bernhard Seckinger
9cb7755041
Replace approxEqual with isClose
2021-01-28 10:39:50 +01:00
Martin Kinkelin
1a459c5996
Get rid of std.conv.emplace[Ref](), use core[.internal].lifetime
...
The emplace() stuff was moved to druntime; for some reason, it's still
in Phobos.
I've diffed the two versions, and they are still almost identical (incl.
unittests); the druntime version appears to have seen some improvements
(e.g., forwarding r/lvalueness of the arguments) in the meantime.
2021-01-17 16:02:25 +01:00
The Dlang Bot
4d7e5829cb
Merge pull request #7625 from jamesragray/chunkbyfix
...
Issue 14909: Provided a fix for the forward range version of chunkBy …
merged-on-behalf-of: Nathan Sashihara <n8sh@users.noreply.github.com>
2020-09-23 03:05:14 +02:00
Andrei Alexandrescu
71ff9d79c5
EASY: factor implementations of range length into a mixin template
2020-09-20 02:38:14 +02:00
James Gray
40286ea15d
Fixed several style problems
2020-09-11 15:26:35 +02:00
James Gray
e32356385e
Fixed trailing whitespace at line 2129 of std/algorithm/iteration.d
2020-09-11 15:11:50 +02:00
James Gray
2ed6952a71
Issue 14909: Provided a fix for the forward range version of chunkBy so that it can accept predicates refernce variables in the calling function
2020-09-10 20:42:17 +02:00
Nathan Sashihara
453faadf5b
Replace is(Unqual!T == Unqual!U) with is(immutable T == immutable U) for speed & memory usage
2020-08-03 15:07:32 +02:00
Simen Kjærås
692f909883
Fix issue 20928
2020-06-15 10:11:43 +02:00
Biotronic
fd59b6a92e
Fix issue 19525
2020-05-29 01:18:40 +02:00
MoonlightSentinel
8fd3b6d3a5
Fix Issue 20496 - chunkby should support ref predicate
...
Provide an lvalue when checking the predicate
2020-04-26 03:20:42 +02:00
Geod24
62c72ca6ff
Follow up review on PR 7441
...
Steven identified a couple mistakes in the massive round of linkification.
Fixing them here.
2020-04-15 02:15:04 +09:00