Mercurial > hg > xemacs-beta
comparison lisp/cl.el @ 2092:f557693c61de
[xemacs-hg @ 2004-05-21 20:56:26 by james]
Batch of fixes and new functions for bignums, ratios, and bigfloats.
author | james |
---|---|
date | Fri, 21 May 2004 20:56:32 +0000 |
parents | 0f60caa73962 |
children | 9d6ec778e1e8 |
comparison
equal
deleted
inserted
replaced
2091:0221e454fe63 | 2092:f557693c61de |
---|---|
309 ;;; Symbols. | 309 ;;; Symbols. |
310 | 310 |
311 (defun cl-random-time () | 311 (defun cl-random-time () |
312 (let* ((time (copy-sequence (current-time-string))) (i (length time)) (v 0)) | 312 (let* ((time (copy-sequence (current-time-string))) (i (length time)) (v 0)) |
313 (while (>= (decf i) 0) (setq v (+ (* v 3) (aref time i)))) | 313 (while (>= (decf i) 0) (setq v (+ (* v 3) (aref time i)))) |
314 (if (featurep 'number-types) | 314 (if (featurep 'bignum) |
315 (coerce-number v 'fixnum) | 315 (coerce-number v 'fixnum) |
316 v))) | 316 v))) |
317 | 317 |
318 (defvar *gensym-counter* (* (logand (cl-random-time) 1023) 100)) | 318 (defvar *gensym-counter* (* (logand (cl-random-time) 1023) 100)) |
319 | 319 |