k-hara
644e11ea46
fix Issue 9665 - Structure constant members can not be initialized if have opAssign
2013-10-14 21:42:26 +09:00
ibuclaw
88b44697bb
Fixup std.math unittests for new math implementations.
2013-08-18 16:28:16 +01:00
H. S. Teoh
8411eaa6b4
Expand tab.
2013-07-15 07:49:15 -07:00
H. S. Teoh
658a6d648d
Use typeid.getHash instead of rt.util.hash.hashOf which is not
...
accessible from outside druntime.
2013-07-09 07:12:11 -07:00
H. S. Teoh
70d4c03fe2
Fix issues 8435, 10118.
2013-07-09 07:12:11 -07:00
Andrei Alexandrescu
e54288b6b7
Merge pull request #1231 from Safety0ff/master
...
Fix std.BigInt bug #9548 plus other new discovered bugs.
2013-05-25 23:36:32 -07:00
Robert BuRnEr Schadek
cab595ec0f
bigint pure
...
the only exception is toString as it takes a delegate and this makes
things more tricky
2013-05-10 05:23:44 +02:00
Robert BuRnEr Schadek
0bf5632e80
Merge branch 'master' into bigintpure
...
Conflicts:
std/bigint.d
2013-05-09 06:40:26 +02:00
Robert BuRnEr Schadek
a686647f54
bigint purity
2013-05-09 06:24:26 +02:00
safety0ff
202d182152
Fix std.BigInt bug #9548 plus other new discovered bugs.
2013-04-08 23:24:30 -04:00
kai
8f34d9a05e
Fix big endian issue in std.internal.math.biguintcore.d
...
The unit tests passes with this change on Linux/PPC64.
2013-04-07 14:55:29 +02:00
safety0ff
835fca54e9
BigInt enhancement: make std.math.abs work with BigInt (issue 6486)
2013-03-31 18:54:15 -04:00
Walter Bright
e422fb7e9c
fix int overflow
2013-03-26 21:21:24 -07:00
Jernej Krempuš
f880870009
Added igammaTemmeLarge to std.internal.math.gammafunction.
2012-11-23 03:00:43 +01:00
alexrp
b202180295
Remove all uses of sizediff_t in favor of ptrdiff_t.
2012-10-15 04:24:09 +02:00
Don Clugston
15c655f1b5
Fix issue 8164 BigInt from char[] too
2012-06-22 07:05:06 +02:00
Don Clugston
a79bb20ea7
Fix issue 7993 BigInt divide-by-1 error
...
Thanks to c.m.brandeburg for the fix.
2012-06-21 18:36:22 +02:00
Karl Broman
320c92d355
Change second paramater of gammaIncompleteComplInverse from x to p
...
- more meaningful for it to be p rather than x
- also, this matches the corresponding internal function in
std.internal.math.gammafunction
- revise comments to match
2012-05-21 06:10:34 -05:00
Daniel Murphy
b9ad889cf3
real.min -> real.min_normal
2012-02-06 00:58:11 +11:00
k-hara
7dcb93621d
Supplemental change of issue 3382 - [tdpl] Implement uniform function call syntax
2011-12-26 22:57:49 +09:00
Walter Bright
add73f61ea
try again to get it to work for 64 bits
2011-12-07 23:44:01 -08:00
Walter Bright
4cf3a6e91c
would not compile for 64 bits
2011-12-07 22:30:14 -08:00
Don Clugston
b828057506
BigInt: uint->size_t in nonasm primitives
...
Causes incorrect results for bigints larger than 2^^34 bytes long.
2011-12-07 10:09:04 +01:00
Brad Roberts
3980990974
fix 32 vs 64bit-ism in bituintcore.d
2011-11-26 14:42:31 -08:00
Don Clugston
1b6bb96de7
Add more comments for Biguint.pow
...
The memory usage calculation was complicated and deserved more explanation.
I've also rewritten it in a way which is clearer.
2011-10-20 15:13:50 +02:00
Don Clugston
c0b25d0903
6819 BigInt ^^ fails for some big numbers (powers)
...
I've also greatly improved the comments for pow.
2011-10-18 15:00:24 +02:00
k-hara
c5c1c0dbbf
detab/entab
2011-09-02 20:56:40 +09:00
jmdavis
302323559a
Revert "not really pure"
...
This reverts commit 4f28db6ffb
.
Since Walter put weakly pure back in, these changes need to be undone.
Conflicts:
std/datetime.d
2011-07-07 01:40:07 -07:00
Walter Bright
4f28db6ffb
not really pure
2011-06-25 19:58:09 -07:00
Ilya
e1b504b627
Just unused variables.
2011-06-12 16:57:27 +04:00
Don Clugston
134d9e14a9
5285 bigint won't compile in 64 bit
2011-04-30 04:57:52 +08:00
Don Clugston
0d8d3d5229
Remove assignment of immutable to mutable
...
This compiles with the current DMD, but should generate an error.
2011-04-15 07:29:12 +08:00
Brad Roberts
919eec2765
Fix biguintnoasm.d on x86-64
2011-03-27 12:55:27 -07:00
Don Clugston
ab1b7d621a
5654 BigInt returns ZERO with strings of single digit number with leading zeros
...
A straightforward bug.
2011-03-26 15:20:14 -07:00
donc
69d8b2e514
Fix Bigint unittest failure
...
Ensure the new, harsher function preconditions for recursiveDivMod are
satisfied when called from blockDivMod.
2011-02-25 00:08:59 +08:00
Don Clugston
9ecf947290
5568 A problem with BigInt modulus
...
This is quite subtle. The recursive division algorithm has a possibility of one
bit of overflow in the second recursive call, in cases where the top quarter of
the dividend is identical to the top half of the divisor.
The description of the recursive division algorithm in "Modern Computer
Arithmetic" 0.5.9 is rather vague about this (which is why I missed it
originally, though the test case does cause assert failure in biguint).
Unfortunately it requires fairly substantial changes to the function, which
makes the algorithm a lot less elegant. But I have managed to implement it
without any change to the basic division algorithm (which is very fast).
2011-02-23 21:20:48 +01:00
Don Clugston
dd4f4a1827
Fix code indentation for biguintcore
...
This commit changes code formatting only. No changes to code.
2011-02-18 22:15:35 +01:00
Don Clugston
6b0a96289e
5608 BigInt(1)-1 problem
...
A stupid typo.
2011-02-18 20:59:53 +01:00
Don Clugston
eb9eb0c01c
Bigint fromDecimal: remove leading zeros after conversion
...
For very large numbers, the estimated length can be an overestimate by more
than 1 BigDigit. This could cause the BigUint invariant to fail.
2011-02-18 10:07:11 +01:00
Brad Roberts
f368104f37
A bunch of 64 bit fixes, including disabling tests that don't pass
2010-12-23 20:39:22 +00:00
David Simcha
8aede6061f
Attempt number 2: Work around Bug 4298 in gammafunction and errorfunction code.
2010-11-29 13:57:37 +00:00
Don Clugston
6d5104ceb5
Relaxed tolerance on betaIncompleteInv unit test. The fact that a 0.8-bit error in log() caused a 38 bit change in the result, is a nice demonstration of how difficult this function is to calculate. BTW Mathematica crashes on this calculation.
2010-11-29 08:31:51 +00:00
Don Clugston
5db6dad8c1
Increase tolerance of this test, now that we know that failure is caused by a small imprecision in AMD's microcode.
2010-11-28 20:11:36 +00:00
Don Clugston
d0c8affabc
Some tougher, more accurate unit tests for betaIncomplete. Possibly these will shed more light on the AMD/Intel difference.
2010-11-23 21:50:05 +00:00
David Simcha
172ec1dc1a
Revert the last changeset.
2010-11-20 22:48:31 +00:00
David Simcha
66bdf06479
Work around Bug 4298 in gammafunction and errorfunction code.
2010-11-20 22:02:35 +00:00
Don Clugston
09667828b6
Enable unittests which used to fail, but are working now.
2010-11-19 22:25:28 +00:00
Don Clugston
876bf9789d
Added std.mathspecial. Only 14 functions are included at this stage.
2010-11-18 19:55:57 +00:00
Don Clugston
1afd555921
pure/nothrow internal compatibility for BigInt. (Not yet marked as such).
2010-11-12 08:10:27 +00:00
Don Clugston
9d7622586a
Fix for BigInt assign for 64 bit compilers. Also a few steps towards const correctness, and some comment fixes.
2010-10-25 07:30:38 +00:00