Jack Stouffer
9ab1fc442a
Merge pull request #5211 from wilzbach/std-range
...
std.range: remove quick index and fix docs (part 2)
2017-03-01 15:46:48 -05:00
Sebastian Wilzbach
64760be50f
std.range: remove quick index and fix docs (part 2)
2017-03-01 03:59:38 +01:00
Sebastian Wilzbach
d548e8830a
Replace LUCKY links with actual links
2017-02-28 23:46:54 +01:00
Andrei Alexandrescu
a36113e5ba
Merge pull request #5160 from wilzbach/dscanner-check-for-void-auto-return
...
DScanner: check for auto function with void return statement
2017-02-28 13:28:42 -05:00
Sebastian Wilzbach
70ebcb8405
reorder CircleCi setup to init DMD before style checking
2017-02-26 09:33:14 +01:00
Sebastian Wilzbach
b8a88558a9
Fix Ddoc warnings
2017-02-26 09:33:14 +01:00
Andrei Alexandrescu
30724e67d9
Merge pull request #5166 from wilzbach/dscanner-unittest-safe-or-system
...
Dscanner: let unittest be @safe or @system
2017-02-22 14:44:08 -05:00
Sebastian Wilzbach
c8cd04d27a
DScanner: check for auto function with void return statement
2017-02-22 05:51:14 +01:00
Sebastian Wilzbach
a36cec8686
DScanner: automatially set all unattributed unittests to @safe or @system
2017-02-22 05:42:04 +01:00
Sebastian Wilzbach
425ab667a3
Automatically set the range style from a..b -> a .. b
...
Commands:
sed -E "s/([[:alnum:]])[.][.]([[:alnum:]])/\1 .. \2/g" -i **/*.d
sed -E "s/([[:alnum:]])[.][.] ([[:alnum:]])/\1 .. \2/g" -i **/*.d
sed -E "s/([[:alnum:]]) [.][.]([[:alnum:]])/\1 .. \2/g" -i **/*.d
2017-02-22 05:37:31 +01:00
Sebastian Wilzbach
805c720595
Unify Phobos by ensuring there's always a space after cast(...)
...
Command:
sed -E 's/([^"])cast\(([^)]*?)\)([[:alnum:]])/\1cast(\2) \3/g' -i **/*.d
2017-02-21 16:40:20 +01:00
Sebastian Wilzbach
5521541032
Unify assert style to have no spaces between the first brace
...
Application of:
sed -E "s/assert +\(/assert(/" -i **/*.d
2017-02-21 15:27:15 +01:00
Sebastian Wilzbach
87dec58a41
DStyle: Constraints on declarations should have the same indentation level
2017-02-17 07:36:23 +01:00
Sebastian Wilzbach
8d5b051235
Provide reference to other common names
2017-02-16 02:57:51 +01:00
Nick Treleaven
759da8eec0
swapRanges: Remove redundant constraint tests
...
hasSwappableElements already tests for isInputRange.
Also fix hasSwappableElements docs.
2017-02-15 17:21:21 +00:00
RazvanN7
41c2d14658
Fix Issue 16442 - FrontTransversal fails with empty ranges
2017-02-06 16:48:20 +02:00
dukc
a5208075c6
Fixed a bug: takeOne with unslicabe ranges did not pop its source range when popped. This made it inconsistent with take and takeExactly when using reference ranges. Also corrected its documentation.
2017-01-26 23:09:38 +02:00
Eduard Staniloiu
095e3277b8
Enable opIndexAssign only for ranges that have assignable elements
2017-01-13 23:17:58 +02:00
Eduard Staniloiu
46a3353ad1
Fix opSlice index error. Add unittests and changelog entry
2017-01-13 21:22:54 +02:00
Martin Nowak
9de40a6b6c
remove bitwise documentation
...
- still unresolved issues before release
2017-01-06 22:37:54 +01:00
dukc
5fed1e4292
Add attributes to unittests of std.range
2016-12-28 05:28:50 +01:00
Eduard Staniloiu
3d98191ce9
Fix issue 16970 - Fix deprecations and warnings when compiling Phobos
2016-12-27 15:57:20 +02:00
Martin Nowak
dc2109ebbb
Merge pull request #4981 from wilzbach/bitwise-cleanup
...
First cleanup of bitwise adapter + add to docs
2016-12-25 12:06:59 +01:00
Sebastian Wilzbach
8f725361b7
First cleanup of bitwise adapter + add to docs
2016-12-21 11:54:05 +01:00
ErinaceusEuropaeus
3daef3fb4f
Fix std.range.Zip.save
2016-12-20 17:19:24 +01:00
Andrei Alexandrescu
b6bcf753ad
Merge pull request #4927 from edi33416/bitwise_adapter
...
[WIP] std.range: implement bitwise adapter over Integral type Ranges
2016-12-19 15:42:04 -05:00
Sebastian Wilzbach
cc7f125ed1
Add missing imports to public unittests
2016-12-15 23:23:35 +01:00
Eduard Staniloiu
5faa96dd6f
Add ddocs
2016-12-15 17:51:44 +02:00
Eduard Staniloiu
37b40631be
Remove branching from opIndex and opSlice using bitwise ops
2016-12-15 17:51:44 +02:00
Eduard Staniloiu
7aff2076a4
Make unittest assertThrown catch Error
2016-12-15 17:51:44 +02:00
Eduard Staniloiu
f5c1e47258
Addressed comments. Refactored code. Fixed bugs.
2016-12-15 17:51:44 +02:00
Eduard Staniloiu
3209adfd74
Fixed cast bug that caused the bitmask to be a 32bit int for long and ulong types
2016-12-15 17:51:44 +02:00
Eduard Staniloiu
0b7cb1639b
std.range: implement bitwise adapter over Integral type Ranges
2016-12-15 17:51:44 +02:00
Sebastian Wilzbach
b82ae35fd7
Use void for auto function without return statement
2016-12-08 12:32:14 +01:00
Jonathan M Davis
1a8cfa7029
Require that popFront and popBack be callable without parens.
...
Technically, prior to this change, it was possible to define popFront
and popBack to be callables that required parens - such as member
variable with an overloaded opCall or a delegate. It's unlikely that
anyone has actually declared popFront or popBack in this manner, but
it's possible. Because of that, calling popFront or popBack without
parens would technically not work with some valid ranges (even if such
ranges are unlikely to exist) and thus without this change, it's
arguably not valid to call popFront or popBack without parens in generic
code - especially in the standard library.
Andrei wants to be able to call popFront without parens in generic code,
and when I pointed out the existing problem with that, he wanted me to
change it so that it's no longer legal to have a range where popFront or
popBack is a callable that requires parens. So, this PR fixes that.
Now, technically, this is a breaking change, but it's highly unlikely
that it actually breaks any code, and I don't know of any way to do this
change in a way which would allow for any kind of deprecation message
for anyone trying to declare a range with a popFront or popBack that
would not work without parens. So, as far as I can tell, if we want to
make this change, we're stuck making a breaking change, but the odds of
it actually mattering seem low.
2016-11-25 10:42:29 -08:00
UplinkCoder
8bed6b2843
15% more performance for popFront(char[])
2016-10-12 20:14:47 +02:00
Andrei Alexandrescu
71dc211e69
Merge pull request #4848 from andralex/popFront
...
Tighten popFront
2016-10-10 18:22:31 -04:00
Andrei Alexandrescu
28b6b462b8
Tighten popFront
2016-10-09 18:04:14 -04:00
Per Nordlöw
0e448d2780
Update primitives.d
...
Fix typo in explanation.
2016-10-09 22:55:48 +02:00
Steven Schveighoffer
86ef3a224e
Merge pull request #4463 from JackStouffer/issue16073
...
Partial Fix for Issue 16073 (part 3)
2016-10-09 09:28:22 -07:00
ZombineDev
8dd953827c
Fix issue 16534 - RefRange should define opDollar if it defines length
2016-09-24 20:12:48 +03:00
Jack Stouffer
67d44e4cdc
Remove package wide std.algorithm imports from Phobos
2016-09-22 08:36:14 +01:00
Walter Bright
55e5737525
add 'scope' to opApply() parameter
2016-09-14 19:41:41 -07:00
togrue
b450113a4a
Enhancement 16363
...
Issue 16363 (Cannot construct a random access range using frontTransversal)
https://issues.dlang.org/show_bug.cgi?id=16291
- Added the length property to frontTransversal (only if the length is known)
2016-08-29 19:49:22 +02:00
H. S. Teoh
98567ac6bb
Merge pull request #4454 from JackStouffer/patch-17
...
[trivial] Improved docs for std.range.refRange
2016-08-17 10:26:06 -07:00
Rainer Schuetze
0d213a9288
Fix issue 16385: do not pass 0 to bsr, it has undefined return value
2016-08-14 11:31:53 +02:00
David Nadlinger
79d1195724
Merge pull request #4528 from schveiguy/fixgenerate
...
Fix generate to be correctly implemented range.
2016-07-29 19:20:22 +01:00
Steven Schveighoffer
f7d8db5c5e
Add changelog entry, appease travis, fix docs, add unit test
2016-07-29 12:44:30 -04:00
Jack Stouffer
c00e298ef6
Improved docs for std.range.zip
2016-07-27 15:40:26 -04:00
Jack Stouffer
06c9dca2da
[Issue 16073] Fix incorrect uses of random access range primitives in std.range.package
2016-07-26 13:56:21 -04:00