From: David Richardson (dgr24_at_[hidden])
Date: 2003-10-14 13:39:01


Deane Yang wrote:
> David Abrahams wrote:
<snip>
>> The fractional power thing is strange, but OK. Anyway, it's
>> essentially the same approach as mine. What Hugo's explanation is
>> missing is any demonstration of how to compute the new Dimensions type
>> which results from multiplication or division.
>>
>
> Darn, that's the crucial point. Using Hugo's approach, the resulting
> type should be a typelist that contains the union of the two
> input typelists, with the rational exponents equal to the sum
> of the corresponding exponents in the input typelist.

The code I've upload is capable of handling fractional exponents.
  It uses ints for the numerator and denominator. I considered
using arbitray length compile time integers, but that seemed like
too much work.

I'm cleaning up the code I put in yahoo (fixed a few bugs, gotten
it to compile on another compiler) and will send an update soon.

David Richardson