|
Boost : |
From: Dean Michael Berris (mikhailberis_at_[hidden])
Date: 2007-02-04 13:06:29
On 2/3/07, Sohail Somani <s.somani_at_[hidden]> wrote:
> I'm not sure I see the value in that vs:
>
> BOOST_REQUIRE_IS_DIVISIBLE_BY(result,3)
>
> I must be missing something
>
The question with the above interface is that "which one are you
requiring to be divisible by what?" which is not always obvious.
Saying that "this value should be divisible by three" is translated
(almost) directly as
value(result).should.be_divisible_by(3);
At least that's how I see it.
HTH!
-- Dean Michael C. Berris http://cplusplus-soup.blogspot.com/ mikhailberis AT gmail DOT com +63 928 7291459
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk