|
Boost Users : |
Subject: Re: [Boost-users] [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
From: vicente.botet (vicente.botet_at_[hidden])
Date: 2010-06-20 07:22:23
----- Original Message -----
From: "joel falcou" <joel.falcou_at_[hidden]>
To: <boost-users_at_[hidden]>
Sent: Sunday, June 20, 2010 12:10 PM
Subject: Re: [Boost-users] [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
>
> vicente.botet wrote:
>> What do you mean by a "real MPL arithmetic types " I'm aware of mpl integral constants, but I don't know other that can be used as arithmetic constants. What a re the requirements for these MPL arithmetic types? Could you elaborate?
>>
> MPL arithmetic types should model the MPL Integral Constant concepts as
> specified here:
>
> http://www.boost.org/doc/libs/1_43_0/libs/mpl/doc/refmanual/integral-constant.html
>
> the idea is just to have your rational type being usable like:
>
> boost::mpl::plus<R1,R2>::type
>
> instead of using ratio_plus etc...
Joel, arithmetic and integral are not the same thing for me. I don't see how I can make ratio be a model of a MPL Integral constant as ratio is not integral, value_type can not be defined, there is no next, nor prior. Am I missing something?
Are you suggesting that I write an specialization of boost::mpl::plus for ratio?
Thanks,
Vicente
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net