Subject: Re: [boost] [math distributions] where to check for validity of distribution variables?
From: John Maddock (john_at_[hidden])
Date: 2008-11-22 14:25:55
Thijs van den Berg wrote:
>> Would it be safe for me to assume that
>> * if a distribution validate its parameters in the constructor
>> * if the constructor doesn't throw an error
>> * there is no need to check the distribution parameters anymore after
>> construction, e.g. in a non-member function.
No, the parameters may be invalid, but the current policy may dictate
returning an error *value*, in such cases the constructor has to defer
signally the error until some other function is called that tries to use the
distribution and which returns a value.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk