Raymond Toy pushed to branch master at cmucl / cmucl
Commits:
-
395af224
by Raymond Toy at 2017-12-29T15:57:59-08:00
1 changed file:
Changes:
... | ... | @@ -474,8 +474,11 @@ |
474 | 474 |
(declare (inline %random-single-float %random-double-float))
|
475 | 475 |
(cond
|
476 | 476 |
((typep arg '(integer 1 #x100000000))
|
477 |
- ;; Let the compiler deftransform take care of this case.
|
|
478 |
- (%random-integer arg state))
|
|
477 |
+ ;; Do the same thing as the deftransform would do.
|
|
478 |
+ (if (= arg (expt 2 32))
|
|
479 |
+ (random-chunk state)
|
|
480 |
+ (values (bignum::%multiply (random-chunk state)
|
|
481 |
+ arg))))
|
|
479 | 482 |
((and (typep arg 'single-float) (> arg 0.0F0))
|
480 | 483 |
(%random-single-float arg state))
|
481 | 484 |
((and (typep arg 'double-float) (> arg 0.0D0))
|