safety0ff
6ff3378c79
Add unittests bug #12889
2014-06-16 19:42:30 -04:00
Dmitry Olshansky
fdf5307d88
Merge pull request #2202 from monarchdodra/swapPointsTo
...
reinsert doesPointTo in swap/move
2014-05-31 06:55:46 -07:00
monarchdodra
b974846d2d
Re-insert doesPointTo in swap/move
2014-05-31 13:44:12 +02:00
Dmitry Olshansky
66fcbadf4d
Merge pull request #2053 from monarchdodra/maxTweak
...
Tweak min and max for yet more efficiency
2014-05-31 04:10:15 -07:00
Dmitry Olshansky
0ae323dc6f
Merge pull request #2167 from monarchdodra/pointsTo
...
Fix issues 9975 & 12479
2014-05-23 22:44:25 +04:00
Walter Bright
c6b3eb0a85
convert jagged array with rectangular one
2014-05-18 00:39:19 -07:00
monarch dodra
a4e448be50
Tweak min and max for yet more efficiency
...
I checked the generated assembly code, and it looks pretty damn good. I've not been able to achieve any better anyways.
2014-05-17 20:06:12 +02:00
monarchdodra
c885157507
Change pointsTo to mayPointTo and doesPointTo
2014-05-14 21:58:02 +02:00
monarch dodra
254290daf7
Merge pull request #2128 from AndrejMitrovic/Fix11253
...
Issue 11253 - std.algorithm.count is not nothrow
2014-05-09 22:08:25 +02:00
monarchdodra
d609bd332f
Sed "@safe pure nothrow"
2014-05-06 08:21:13 +02:00
Andrej Mitrovic
5ad48eb130
Fix Issue 11253 - std.algorithm.count is not nothrow.
2014-04-28 14:40:15 +02:00
Andrej Mitrovic
8c24b1e875
Fix Issue 12293 - Add forward to std.algorithm's cheat-sheet.
2014-04-27 01:00:06 +02:00
Andrej Mitrovic
e549dd037b
Strip spaces.
2014-04-26 21:13:39 +02:00
Andrej Mitrovic
6f05fc3f63
Merge pull request #2075 from monarchdodra/sumInfer
...
safe pure nothrow sort and sum
2014-04-26 01:08:47 +02:00
monarch dodra
79903eb199
Merge pull request #2107 from AndrejMitrovic/Fix7246
...
Issue 7246 - Provide a simpler example for std.algorithm.remove.
2014-04-23 19:56:37 +02:00
Andrej Mitrovic
899155194a
Fix Issue 7246 - Provide a simpler example for std.algorithm.remove.
2014-04-23 16:39:17 +02:00
Andrej Mitrovic
ecddbf64dc
Fix Issue 11462 - std.algorithm.multiSort was missing from the index.
2014-04-22 23:45:29 +02:00
Andrej Mitrovic
d4b0e70c67
Fix Issue 11978 - Fix typos in std.algorithm documentation referencing parameter names.
2014-04-22 22:11:32 +02:00
monarchdodra
6c98c325f9
safe pure nothrow sort and sum
2014-04-09 18:48:24 +02:00
monarchdodra
6123ca3371
Fix Issue 12434 - std.algorithm.sum of immutable array too
...
https://d.puremagic.com/issues/show_bug.cgi?id=12434
Simply uses the inference's `Unqual` type as a seed, rather than the straight up result.
Also add some unittesting while at it.
2014-04-07 07:48:53 +02:00
Dmitry Olshansky
98434a5181
Merge pull request #2052 from monarchdodra/copyAssert
...
Add asserts in Copy (and remove an enforce)
2014-03-30 23:50:27 +04:00
Dmitry Olshansky
66fd049ea9
Make move CTFEable for simple structs and classes
...
memcpy is not CTFEable, so avoid it for structs without
dtor, postblit that can be assigned with plain =.
This leaves as is (compile error in CTFE) structs that contain
immutable/const memebers the fact that moves overwrites such
fields is questionable to begin with.
2014-03-28 00:24:21 +04:00
monarch dodra
dacbef4c98
Add asserts in Copy (and remove an enforce)
...
Adding extra asserts always helps. As for the enforce, I'm unsure why it was there in the first place: All the other branches simply make the assumption the target is large enough.
2014-03-27 18:49:12 +01:00
Andrei Alexandrescu
cecd745cef
Merge pull request #2015 from monarchdodra/emplaceQual
...
Improve emplaceRef for qualified construction
2014-03-26 18:03:39 -07:00
monarch dodra
4e4f73b646
Remove pointsTo in move
...
as well as remove erroneous documentation.
2014-03-25 21:21:33 +01:00
monarch dodra
782441ee1d
Fixup for 9975: swap and pointsTo
...
Fixing 9975 revealed that checking `pointsTo` was creating problems in swap for legitimate use cases.
This is because:
1. pointsTo can sometimes create "false positives"
2. Internal pointing is not outright forbidden, it is just that the runtime is allowed to make the assumption they don't exist.
While swapping aliasing objects is a sign of stink, it should still "just work".
2014-03-25 21:21:33 +01:00
monarch dodra
aec513e542
Revert
2014-03-24 16:39:56 +00:00
monarch dodra
72d78547cf
Update algorithm.d
2014-03-24 16:16:19 +00:00
monarch dodra
7f76f3fc3a
Update algorithm.d
2014-03-24 16:13:29 +00:00
monarch dodra
8370276924
Fix Issue 12449
...
Undefined format in std.algorithm.max
2014-03-24 13:41:44 +00:00
Andrei Alexandrescu
9404dd477f
Merge pull request #1970 from monarchdodra/sumseed
...
Give sum a seed capability
2014-03-19 18:08:06 -07:00
monarchdodra
59ad77ad9f
Improve emplaceRef for qualified construction
2014-03-17 22:48:30 +01:00
monarchdodra
69d181290c
Remove incorrect save
2014-03-14 22:41:34 +01:00
k-hara
6f80f6aa03
Add more local imports
2014-03-13 13:13:04 +09:00
monarch dodra
9231bdd0b3
Tweak map's save
...
Not only does it avoid opAssign issues, but the final code is simpler anyways.
2014-03-12 11:53:21 +01:00
Geod24
4ed10be8bc
Fix issue 12183 : Avoid using floating point in std.algorithm.sort.
...
- Prevent valgrind from aborting (some x87 FP operation are not supported).
- Can be slower on machines that have a soft floating point ABI.
2014-03-11 10:58:29 -07:00
monarchdodra
423f889580
Give sum a seed capability
2014-03-10 07:44:44 +01:00
Yazan S. Dabain
b8c29046f8
[Trivial] Fix documentation typos in std.algorithm
2014-02-28 10:37:44 +02:00
monarch dodra
4d16df5a73
Add sum to std.algorithm
's TOC
2014-02-27 10:05:51 +01:00
monarch dodra
920d8c7651
Fixup sum documentation
2014-02-26 11:09:24 +01:00
monarchdodra
e5c10ca4ab
Fix issue 12169 - sum(int[]) should return a int
2014-02-25 21:07:44 +01:00
Daniel Murphy
4d0892baba
Remove uses of the comma operator
2014-02-18 00:48:40 +11:00
monarchdodra
9ba09aa59c
change emplace for emplaceRef in algorithm
2014-02-16 17:04:34 +01:00
monarchdodra
95152081f3
swap isAssignable and !hasElaborateAssign
2014-02-16 17:04:34 +01:00
monarch dodra
acdb1d0a9a
Merge pull request #1205 from andralex/4725
...
Fix Issue 4725 - std.algorithm.sum()
2014-02-15 08:20:01 +01:00
Andrej Mitrovic
4aab80ef53
Merge pull request #1461 from monarchdodra/issue10039
...
Fix Issue 10039 - std.algorithm enhancements: min, max, clamp
2014-02-14 22:27:05 +01:00
monarchdodra
01ef8978c2
Improve min/max recursion
2014-02-14 19:55:25 +01:00
Peter Alexander
cef8d54a7b
Fix Issue 5753 - Disallow map with void function.
...
https://d.puremagic.com/issues/show_bug.cgi?id=5753
2014-02-12 18:49:40 +00:00
k-hara
b391b2ec9f
Convert to new alias syntax
2014-02-11 15:27:05 +09:00
monarchdodra
9d33fb078d
Coverage for minCount
2014-02-09 20:37:15 +01:00