|
Boost : |
From: Nathan Myers (ncm_at_[hidden])
Date: 1998-12-13 02:51:28
Kevlin wrote:
> I do not see that having alternative implementations of a random number
> generator is necessarily a bad thing, esp as the one I was proposing had
> different usage properties (ie template parameterisation), performance
> characteristics and explores a different model consistent with other parts
> of the standard library.
>
> * Random number generation, using a generator function conforming to std
> requirements.
> * An adaptor class, templated on (and initialised by an instance of) a
> random generator type, that allows a generator to be used as a forward
> iterator to const.
> * An adaptor that creates the effect of a pseudo-container by taking a
> begin iterator and count -- this last is more general purpose.
I like the idea of separating the source of random bits from the
rest of the packaging. I see viewing them as functions, iterators,
and streams all reasonable, and I would not like to have to choose
just one view. What we need in Boost is a primitive form with
optimal performance, and suitable to attach to adapters that don't
add overhead.
Nathan Myers
ncm_at_[hidden]
------------------------------------------------------------------------
Free Web-based e-mail groups -- http://www.eGroups.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk