Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] zsh/random module [UPDATED]
Firstly, thanks for your work on this Clinton and for being patient with us.
Bart Schaefer wrote:
> Actually this could be done with -ap for SRANDOM and -af for zrandom,
> as well, but they're much simpler and the only reasonable quibble
> might be with the name "zrandom".
Bash appears to have an SRANDOM and if this is compatible with that then
I'd see no issue with having that feature autoload the module.
The builtin's option letter API looks good to me.
If we're going to quibble about naming, many of our modules use 'z'
prefixes on their builtins so I'd favour zrandom for the builtin too.
The use of "get" and "set" in naming is often superfluous and "get"
implies the fetching of something that already exists rather than
of something that needs to be created.
What issue do you see with "zrandom" on the math function? Most of the
existing math functions correspond fairly closely to libc counterparts.
Distinguishing it from those seems reasonable.
The question of why $RANDOM isn't backed by some secure modern and fancy
implementation seems to come up roughly yearly. It's not a feature I use
especially often and I certainly don't care, either about stability or
security, on the rare occasion I use *(oe:REPLY=\$RANDOM:) to shuffle
a few mp3 files when playing them. Neither would I have any special
attachment to the existing $RANDOM implementation if it was changed in a
compatible way.
Given that it can be autoloaded, could we move $RANDOM to the module
too?
Oliver
Messages sorted by:
Reverse Date,
Date,
Thread,
Author