Commit graph

128 commits

Author SHA1 Message Date
Sebastian Wilzbach
d548e8830a Replace LUCKY links with actual links 2017-02-28 23:46:54 +01:00
Sebastian Wilzbach
a1bb0515fc Automatically add spaces to binary operators (>=)
command:

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-23 00:57:47 +01:00
Sebastian Wilzbach
d905ef53b1 Automatically add spaces to binary operators (<=)
command:

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-23 00:57:47 +01:00
Sebastian Wilzbach
0b33b50812 Automatically add spaces to binary operators (!=)
command:

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-23 00:57:47 +01:00
Sebastian Wilzbach
a2c6398332 Automatically add spaces to binary operators (==)
command:

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-23 00:57:47 +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
Martin
2891479985 Fix std.numeric compile error for non-DigitalMars branch 2017-02-18 20:38:45 +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
18ecb6b72c Make more modules publicly runnable on dlang.org 2017-01-06 23:29:55 +01:00
Alexandru Razvan Caciulescu
6b4c2585fe Fix Issue 4125 - std.numeric.gcd can use a binary GCD 2016-12-12 15:39:40 +02:00
ZombineDev
d9abb1028d Use assert instead of enforce in std.numeric
And also use onOutOfMemoryError instead of allocating and throwing a new
exception when malloc fails.
2016-08-04 01:27:21 +03:00
Walter Bright
aa017e5001 Merge pull request #4587 from wilzbach/test-codecov
show code coverage with Codecov.io
2016-07-27 23:27:09 -07:00
Sebastian Wilzbach
11b4c1fb1e fix weird compiler error of std.numeric.entropy 2016-07-27 16:37:17 +02:00
Ilya Yaroshenko
13b9ab8074 Merge pull request #4635 from JackStouffer/immutable2
[trivial] Added immutable to several variables in std.numeric
2016-07-22 12:44:15 +02:00
Jack Stouffer
471a50e843 Removed package wide std.algorithm imports from std.numeric 2016-07-21 15:04:59 -04:00
Jack Stouffer
447726bc5b Removed global std.exception import from std.numeric 2016-07-21 15:02:52 -04:00
Jack Stouffer
897dffc43f Added immutable to several variables in std.numeric 2016-07-21 14:48:48 -04:00
Jack Stouffer
f6c64e0df4 Removed unused variables from std.numeric 2016-07-12 11:15:45 -04:00
Atila Neves
0a896934e5 Add @system and @safe to std.numeric unit tests 2016-07-02 11:16:33 +02:00
Jack Stouffer
e86c28fd59 Fixed local imports in std.numeric 2016-06-30 18:20:02 -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
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
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
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
18b8abf60a remove the deprecated wiki macros 2016-05-27 05:52:23 +02:00
Dmitry Olshansky
c110eac0f4 Merge pull request #3559 from 9il/patch-2
Add findLocalMin
2016-04-29 14:19:21 +04:00
Ilya Yaroshenko
ce4f1692be fix style in std.numeric 2016-04-29 11:04:33 +02:00
Sebastian Wilzbach
3d67cd228c style fix: space between operators 2016-04-26 22:26:20 +03:00
Ilya Yaroshenko
fe4df8df52 Fix FPTemporary 2016-04-19 16:40:39 +02:00
Ilya Yaroshenko
4cfa177fb5 add findLocalMin 2016-04-19 15:39:07 +02:00
tsbockman
9da546b2a6 core.bitop bsr(), bsf(), and popcnt() now support ulong inputs even on a 32-bit arch.
This also fixes a few small issues:
* In std.numeric, `Ulong union` didn't consider endianness, and
* in `roundDownToPowerOf2()`, this expression: (1 << bsr(num)) is always 32-bit,
    whereas it should, at a minimum, match the bit-ness of num.
* ilogb() supports integer inputs, but this was undocumented.
2016-01-13 13:54:27 -08:00
Dragos Carp
d698887729 Remove obsolete TypeTuple references
Replace following names:
std.typetuple      -> std.meta
TypeTuple          -> AliasSeq
ParameterTypeTuple -> Parameters
FieldTypeTuple     -> Fields

std.traits requires more work than search/replace and is left unchanged.
2015-10-13 20:37:44 +02:00
Rainer Schuetze
adab223837 remove trailing whitespace, detab, tolf 2015-05-31 11:24:01 +02:00
Walter Bright
d9a9826e55 Revert "Introducing std.meta package" 2015-05-06 14:36:45 -07:00
Dicebot
1c9ae027ef Rename old std.typetuple symbols inside Phobos
staticIndexOf -> indexOf
allSatisfy -> all
anySatisfy -> any
staticMap -> Map
2015-05-05 22:22:11 +03:00
Dicebot
82f54a38d3 TypeTuple -> MetaList inside Phobos 2015-05-05 22:22:11 +03:00
Dicebot
73f773838d import std.typetuple -> import std.meta 2015-05-05 22:22:10 +03:00
Ilya Yaroshenko
33e8972c64 fix docs 2015-03-20 21:13:11 +03:00
Martin Nowak
27d3a41158 Merge pull request #3028 from 9il/fr
findRoot: fix Issue 14231
2015-03-14 06:57:04 +01:00
Denis Shelomovskij
62279377e4 [Minor] Fix last std.numeric.findRoot overload without tolerance delegate. 2015-03-06 19:51:25 +03:00
Ilya Yaroshenko
5b8cf59961 fix Issue 14231
fix findRoot documatntation
2015-03-05 14:58:09 +03:00
Ilya Yaroshenko
f4ea980d21 fix docs for 2.067
fix comment

fix docs
2015-02-27 18:54:11 +03:00
Robert burner Schadek
ced096ccf2 documentation update for numeric.d
* moved examples to unittests
* removed dead code
2015-01-26 15:08:49 +01:00
Ilya Yaroshenko
2c744b54e1 std.range: constraints => primitives
See discussion and voting in #2661
2014-11-23 20:05:20 +03:00
David Nadlinger
7e80e67630 Merge pull request #2728 from 9il/typecons
std.typecons: remake toString to template, clean module imports
2014-11-20 22:11:54 +01:00
Ilya Yaroshenko
af02101ab9 std.typecons: remake toString to template, clean module imports
update datetime unittests
2014-11-20 23:08:33 +03:00
Lars T. Kyllingstad
96583fe46b isNaN() is not a property
...so it shouldn't be used as one.
2014-11-20 20:22:00 +01:00
k-hara
4f5a6e5811 Add missing imports 2014-11-21 00:16:47 +09:00