From: Andy Little (andy_at_[hidden])
Date: 2005-02-28 06:51:23
What is the current status of compile time fractions / rationals?
Various directions are
1 Alexei Gurovois in boost/mpl/math/rational_c.hpp
2 Cromwell Enages work on the files section
3 Hugo Duncans:
However the three are not compatible with each other
In Cromwells (named fraction_c) and Hugo Duncans the numerator and
denominator are mpl Integral Constants not values, as in Alexeis original.
mpl::rational_c<int,1,2>::denominator; // == 2
mpl::rational_c<int,1,2>::denominator::value; == 2
Cromwell's version is not a nullary_metafunction whereas Hugo Duncans
and Alexeis are. This is the right thing IMO because the type can be reduced
eg 2/2 ---> 1,
I appreciate that there my be advantages to Cromwells and Hugo Duncans
versions.. Ultimately either the version in the release should be removed/
modified or 'lived with'.
Anyone have any thoughts. And is anyone still working on this?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk