diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2016-04-28 06:47:22 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2016-04-28 06:47:22 -0700 |
commit | 0c18458bd242489babcd9a1aee30ba9fd0620e25 (patch) | |
tree | 51958c2205ee15fc7fd978c877f97b7c79566c61 /tests | |
parent | 2e0639abc56dcad0ce4b5933604d0c8657ac094b (diff) | |
download | txr-0c18458bd242489babcd9a1aee30ba9fd0620e25.tar.gz txr-0c18458bd242489babcd9a1aee30ba9fd0620e25.tar.bz2 txr-0c18458bd242489babcd9a1aee30ba9fd0620e25.zip |
Clean-up rand code; implement configurable warmup.
* lib.c (copy): Pass new second argument to make_random_state.
* rand.c (random_warmup): New macro.
(random_warmup_s): New symbol variable.
(make_random_state): New warmup argument. Code restructured to
avoid copy flag. Fill code and initialization of r->cur made
common.
(rand_compat_fixup): Pass second argument to
make_random_state.
(rand_init): Pass second argument to make_random_state.
Initialize random_warmup_s with interned symbol. Register
*random-warmup* special variable. Fix registration of
make-random-state to two-argument function type.
* rand.h (make_random_state): Declaration updated.
* txr.1: Document *random-warmup* variable and warup
argument of make-random-state.
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions