Re: [boost] [fusion] implementing distance_impl<>

Eric Niebler wrote:
But now there is code in algorithm/iteration/detail/for_each.hpp like this:
for_each_unrolled< result_of::distance<begin, end>::value
::call(fusion::begin(seq), f);
The problem is with distance<begin, end>::value. My distance_impl<> doesn't provide a nested value. It provides a nested type. If this were distance<begin, end>::type::value, it works. It also works if I change my distance_impl<> specialization, but I don't think I should have to. Bug?
From what I can see in the MPL docs, a numeric metafunction is only required to return ::type, and ::value is just a convenience that I shouldn't count on. So I agree, a bug. I'll patch up shortly, thanks for picking this up.
Cheers Dan ___________________________________________________________ What kind of emailer are you? Find out today - get a free analysis of your email personality. Take the quiz at the Yahoo! Mail Championship. http://uk.rd.yahoo.com/evt=44106/*http://mail.yahoo.net/uk
participants (1)
-
dan marsden