Andrei Alexandrescu
331dd3a489
Moved split from string to array, made one more pass through array
2011-01-19 06:44:46 +00:00
Andrei Alexandrescu
cf33c1999a
Moved join from std.string to std.array, plus a few cosmetic changes
2011-01-17 20:43:54 +00:00
SHOO
cdc546892d
Retry Issue 5340
...
http://d.puremagic.com/issues/show_bug.cgi?id=5340
And added some unittest.
The changes of std.base64 are caused by char[] NOT being OutputRange.
is(R2 == char[]) && isOutputRange!(R2, char) always returns false.
2010-12-10 15:01:25 +00:00
SHOO
9d3ae0ad70
Revert.
...
Sorry, unittest was failure..
std\base64.d(404): Error: template std.base64.Base64Impl!('+','/').encode(R1,R2) if (isArray!(R1) && is(ElementType!(R1) : ubyte) && is(R2 == char[]) && isOutputRange!(R2,char)) does not match any function template declaration.
....
It seems to be necessary to check behavior of std.base64.
2010-12-10 11:44:55 +00:00
SHOO
28ed751472
Fixed: Issue 5340 - isOutputRange!(Appender!string, int) must be false
...
http://d.puremagic.com/issues/show_bug.cgi?id=5340
2010-12-10 11:24:36 +00:00
David Simcha
8331c70969
More 64 fixes for semantic errors that only show up when templates are instantiated via unittests. Now I'm actually serious about Phobos passing semantic analysis, except for a few modules due to weird druntime issues.
2010-11-10 05:25:50 +00:00
David Simcha
91bc314e2d
Fix a few minor, unlisted bugs in InputRangeObject.
2010-11-08 03:07:54 +00:00
Lars T. Kyllingstad
53275d8851
5052: take!(Take!R) should return Take!R, not Take!(Take!R)
2010-10-14 07:15:19 +00:00
Shin Fujishiro
3ec3fee75a
Ddoc: Fixed bug 4634 and some trivial doc isues in std.algorithm & range.
...
- Bug 4634: typo in levenshteinDistanceAndPath documentation
- Got rid of mentions of iterator-age begin(r)
- equal() not equals()
2010-10-13 05:40:03 +00:00
Shin Fujishiro
3c048ac456
Migration of tup.field[k] to tup[k].
...
Replaced ad-hoc 'is tuple?' checks with isTuple template.
The "this._cache" change in std.range is just a workaround for bug 5046.
2010-10-13 05:39:53 +00:00
David Simcha
1fd3b635c5
Bug 5035: Schrödinger's Stride
2010-10-13 00:18:02 +00:00
Andrei Alexandrescu
822a29cf89
unittest to avoid regression for bugzilla 3181
2010-09-27 01:22:14 +00:00
Andrei Alexandrescu
58b0b79703
Fix for bugzilla 2930
2010-09-26 22:28:31 +00:00
David Simcha
b597d23f83
Bug 4888: Heavy reliance on Bug 3534 in Phobos range usage. I used a different approach here than the first one I tried. I only did what was necessary to make Phobos work instead of trying to fix the deeper issue of making std.algorithm to work w/ const/immutable arrays.
2010-09-18 21:00:52 +00:00
David Simcha
ab60a7d7a1
Fix std.range.Zip.
2010-09-18 00:48:42 +00:00
David Simcha
5bc6e09d2b
Mitigate const issues in std.range. Everything except Zip now at least works with const/immutable arrays of primitives.
2010-09-18 00:34:20 +00:00
David Simcha
a1c63984cc
Fix debug code in SortedRange.
2010-09-17 04:06:56 +00:00
David Simcha
a0162ed834
Make SortedRange work with const/immutable arrays.
2010-09-17 00:32:28 +00:00
Andrei Alexandrescu
bf93b229c1
Replaced the random number generator with a cheaper one in SortedRange's constructor
2010-09-16 18:22:48 +00:00
Andrei Alexandrescu
627023c5d9
Fixed unlisted bug in SortedRange's constructor
2010-09-16 18:15:30 +00:00
David Simcha
72d6bf1217
Add back lowerBound, upperBound, canFindSorted, equalRange to std.algorithm, but with "scheduled for deprecaton" pragmas on instantiation.
2010-09-15 23:02:23 +00:00
David Simcha
f252d5e611
Support pointers to structs in std.range.put().
2010-09-15 22:41:50 +00:00
Andrei Alexandrescu
a92a8a9c4e
Fix for bugzilla 4861
2010-09-13 22:58:10 +00:00
David Simcha
ff0c2b3d3b
Support moveFront() and friends and assignable elements where possible.
2010-09-13 01:53:39 +00:00
Walter Bright
0b091d3eac
add Source link
2010-09-12 05:11:46 +00:00
David Simcha
89c9bf697d
Zip shouldn't require ranges to define moveFront and friends if elements don't have elaborate copy c'tors.
2010-09-12 04:46:48 +00:00
David Simcha
f7dbbfdedd
Assignable element support for Stride.
2010-09-12 04:08:40 +00:00
David Simcha
1015641e6f
Support assignable elements for Retro.
2010-09-12 03:49:13 +00:00
David Simcha
326760ef35
Iota should Unqual all its parameters to work w/ const/immutable since its parameters can't have indirection anyhow.
2010-09-09 20:46:37 +00:00
Andrei Alexandrescu
efb5c12066
Fixed Zip, added SortedRange
2010-09-08 13:19:58 +00:00
David Simcha
817dc10f95
Fix hasElaborateCopyConstructor and hasElaborateAssign to look at whole representation. Also make std.range use hasElaborateCopyConstructor instead of rolling its own.
2010-09-04 19:35:27 +00:00
David Simcha
6b799db785
Fix some trivial documentation issues from Bugzilla. No changes to actual code.
2010-09-03 23:28:05 +00:00
David Simcha
08cf0ed9c7
hasPostblit needs to transitively search subobjects.
2010-09-03 04:22:04 +00:00
Steven Schveighoffer
7e89201cda
Rewrote Appender to be safer and to not corrupt memory.
...
Fixed all places that use appender to use the safer interface.
bugzilla 4681: Appender access violation
2010-08-26 11:49:50 +00:00
David Simcha
6d5e623f26
InputRangeObject/OutputRangeObject
2010-08-22 18:46:09 +00:00
David Simcha
372641585f
Clean up std.range enforce vs. assert situation. Also, a few small fixes for bugs discovered while reading the code.
2010-08-22 14:51:36 +00:00
David Simcha
63c6e670a9
Fix boundary case bug in stride slicing.
2010-08-22 14:24:10 +00:00
David Simcha
82bcaca481
Clean up std.range.Take a little, properly handle ref return stuff.
2010-08-21 19:41:02 +00:00
David Simcha
9471b3f525
Default moveBack, moveAt implementations for elements w/o postblit. This was fixed a long time ago for moveFront.
2010-08-20 04:41:28 +00:00
David Simcha
b6ab569a4a
Lockstep opApply should take a scope delegate.
2010-08-20 00:40:16 +00:00
David Simcha
9b7cb69f99
More infiniteness propagation for std.range, remove faulty assumption that infinite ranges don't have ref return in Zip.
2010-08-20 00:34:30 +00:00
David Simcha
b4798c3f34
Bug 4603: array(iota(1, 0)) error
2010-08-20 00:06:06 +00:00
David Simcha
a95bb745ee
One more Lockstep issue: _ranges should be shallow copied for consistency with regular foreach.
2010-08-19 04:58:37 +00:00
David Simcha
98f98a744e
Optimize Lockstep and work around some compiler bugs.
2010-08-19 03:44:24 +00:00
David Simcha
096ddcad2a
Fix a few silly mistakes in std.range. Also, add self as author, as I feel I've earned it.
2010-08-17 02:30:45 +00:00
David Simcha
c03041e5fd
Clean up std.range.chain, fix several unlisted bugs and make the code more readable.
2010-08-17 02:26:46 +00:00
David Simcha
3235b577a7
Bug 3877: std.range.chain do not manage infinite ranges correctly
2010-08-17 00:50:06 +00:00
David Simcha
abb54f279c
Lockstep StoppingPolicy should be a runtime arg, not a compile time one.
2010-08-16 03:31:59 +00:00
David Simcha
0318457f7c
Two related bugs: 3123: std.algorithm.zip fails on 'lazy' ranges ,
...
4402: std.range.Zip doesn't work w/ non-lvalue ranges.
2010-08-16 02:55:02 +00:00
David Simcha
c4cdd64f14
Add index variable support to Lockstep, since it ended up being trivial.
2010-08-16 00:14:26 +00:00