On 12/12/11 15:01, Larry Evans wrote:
On 12/12/11 13:41, Robert Ramey wrote: [snip]
The example below illustrates one of the problems I'm having. The intent is to test the concept. for next<I>, the concept check is invoked recurrsively until the end of iteration is encountered. (I'm assuming it's a list in this test). But the is_end
branch is always invoked [snip] template<typename S> struct ForwardSequence { typedef typename end<S>::type t2; BOOST_CONCEPT_ASSERT(( ForwardIterator<t2> )); Shouldn't this:
is_end
branch is always invoked be expected since end<S>::type is being passed to ForwardIterator? [snip] OOPS, never mind. I see you intentionally passed the end<S>::type to show the very problem you mentioned. IOW, even though end<S>::type is passed, the false_ branch is taken instead of the true_ brancch.
Sorry for noise. However I haved tried to compile the attached: and, with gcc4.7, I'm getting: ramey_iter_concept_check.cpp:19:14: error: explicit specialization in non-namespace scope 'struct boost::mpl::ForwardIterator<I>' ramey_iter_concept_check.cpp:20:12: error: template parameters not used in partial specialization: