<div class="gmail_quote">On Wed, Nov 28, 2012 at 9:41 AM, Robert Jones <span dir="ltr">&lt;<a href="mailto:robertgbjones@gmail.com" target="_blank">robertgbjones@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Here&#39;s the compiler output....<br><br>
<div><div>|| ~/local/gcc-4.6.2/bin/g++ -std=c++0x -I ~/local/boost_1_48_0/include -g -W -fno-strict-aliasing -fno-inline -Wno-uninitialized -Wcast-align -Wwrite-strings -Wnon-virtual-dtor -Wextra   -c -o range_for.o range_for.cpp</div>


<div>In file included from /home/rjones/local/boost_1_48_0/include/boost/iterator/iterator_categories.hpp|15| 0,</div><div>||                  from /home/rjones/local/boost_1_48_0/include/boost/iterator/detail/facade_iterator_category.hpp:7,</div>


<div>||                  from /home/rjones/local/boost_1_48_0/include/boost/iterator/iterator_facade.hpp:14,</div><div>||                  from /home/rjones/local/boost_1_48_0/include/boost/range/iterator_range_core.hpp:23,</div>


<div>||                  from /home/rjones/local/boost_1_48_0/include/boost/range/counting_range.hpp:18,</div><div>||                  from range_for.cpp:1:</div><div>|| /home/rjones/local/boost_1_48_0/include/boost/mpl/eval_if.hpp: In instantiation of ‘boost::mpl::eval_if_c&lt;false, boost::range_const_iterator&lt;int&gt;, boost::range_mutable_iterator&lt;int&gt; &gt;’:</div>


<div>/home/rjones/local/boost_1_48_0/include/boost/range/iterator.hpp|63 col 63| instantiated from ‘boost::range_iterator&lt;int&gt;’</div><div>/home/rjones/local/boost_1_48_0/include/boost/range/value_type.hpp|30 col 12| instantiated from ‘boost::range_value&lt;int&gt;’</div>


<div>range_for.cpp|9 col 47| instantiated from here</div><div>/home/rjones/local/boost_1_48_0/include/boost/mpl/eval_if.hpp|60 col 31| error: no type named ‘type’ in ‘boost::mpl::eval_if_c&lt;false, boost::range_const_iterator&lt;int&gt;, boost::range_mutable_iterator&lt;int&gt; &gt;::f_ {aka struct boost::range_mutable_iterator&lt;int&gt;}’</div>


<div>|| /home/rjones/local/boost_1_48_0/include/boost/mpl/eval_if.hpp: In instantiation of ‘boost::mpl::eval_if_c&lt;true, boost::range_const_iterator&lt;int&gt;, boost::range_mutable_iterator&lt;const int&gt; &gt;’:</div>


<div>/home/rjones/local/boost_1_48_0/include/boost/range/iterator.hpp|63 col 63| instantiated from ‘boost::range_iterator&lt;const int&gt;’</div><div>/home/rjones/local/boost_1_48_0/include/boost/range/value_type.hpp|30 col 12| instantiated from ‘boost::range_value&lt;const int&gt;’</div>


<div>range_for.cpp|9 col 47| instantiated from here</div><div>/home/rjones/local/boost_1_48_0/include/boost/mpl/eval_if.hpp|60 col 31| error: no type named ‘type’ in ‘boost::mpl::eval_if_c&lt;true, boost::range_const_iterator&lt;int&gt;, boost::range_mutable_iterator&lt;const int&gt; &gt;::f_ {aka struct boost::range_const_iterator&lt;int&gt;}’</div>


<div>|| gmake: *** [range_for.o] Error 1</div></div></blockquote><div><br>Looks like gcc is instantiating the unary overloads of counting_range (with template parameter int) even though you&#39;re supplying 2 arguments...I&#39;m not sure if that is standard behavior or not; MSVC9 seems to do okay with it.<br>
<br>Is this is a real hindrance or merely curiosity?<br><br>- Jeff<br><br></div></div>

