[Python-checkins] python/nondist/sandbox/twister _random.c,1.9,1.10

tim_one@users.sourceforge.net tim_one@users.sourceforge.net
Sat, 28 Dec 2002 23:33:21 -0800


Update of /cvsroot/python/python/nondist/sandbox/twister
In directory sc8-pr-cvs1:/tmp/cvs-serv28480

Modified Files:
	_random.c 
Log Message:
Restored original code's credit to Isaku Wada.


Index: _random.c
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/twister/_random.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** _random.c	29 Dec 2002 07:30:43 -0000	1.9
--- _random.c	29 Dec 2002 07:33:19 -0000	1.10
***************
*** 130,136 ****
   * 9007199254740992 == 2**53; I assume they're spelling "/2**53" as
   * multiply-by-reciprocal in the (likely vain) hope that the compiler will
!  * optimize the division away at compile-time).  67108864 is 2**26.  In
   * effect, a contains 27 random bits shifted left 26, and b fills in the
   * lower 26 bits of the 53-bit numerator.
   */
  static PyObject *
--- 130,137 ----
   * 9007199254740992 == 2**53; I assume they're spelling "/2**53" as
   * multiply-by-reciprocal in the (likely vain) hope that the compiler will
!  * optimize the division away at compile-time.  67108864 is 2**26.  In
   * effect, a contains 27 random bits shifted left 26, and b fills in the
   * lower 26 bits of the 53-bit numerator.
+  * The orginal code credited Isaku Wada for this algorithm, 2002/01/09.
   */
  static PyObject *