summaryrefslogtreecommitdiffstats
path: root/regex.c
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2024-07-01 18:10:49 -0700
committerKaz Kylheku <kaz@kylheku.com>2024-07-01 18:10:49 -0700
commit77deceded0e5c9143e01d07a19eb219b3273151b (patch)
treef2447cc6c50cf459a3c271c25a7b4d4437b6280b /regex.c
parentc23882b230f65ddc87742e206a56270d09c73684 (diff)
downloadtxr-77deceded0e5c9143e01d07a19eb219b3273151b.tar.gz
txr-77deceded0e5c9143e01d07a19eb219b3273151b.tar.bz2
txr-77deceded0e5c9143e01d07a19eb219b3273151b.zip
New functions: cshuffle and cnshuffle.
These functions find random cyclic permutations. * eval.c (eval_init): Register cshuffle and cnshuffle intrinsics. * lib.c (nshuffle_impl): New static function, formed out of nshuffle. (nhuffle): Now wrapper around nshuffle_impl. (shuffle): Also wraps nshuffle_impl rather than nshuffle. (cnshuffle, cshuffle): New funtions. * lib.h (cnshuffle, cshuffle): Declared. * txr.1: Documented new functions. Also added warning about limitations on permutation reachability in relation to PRNG state size.
Diffstat (limited to 'regex.c')
0 files changed, 0 insertions, 0 deletions