|
Boost : |
From: David Abrahams (dave_at_[hidden])
Date: 2003-08-04 22:26:06
Thanks Alisdair, but these aren't patches. Patches are made with the
diff program (preferably with the -du flags) and show the precise
lines and files of changes. Could you post one as an attachment?
Otherwise, we have to try to figure out which lines are changing.
Thanks,
Alisdair Meredith <alisdair.meredith_at_[hidden]> writes:
> The concept checker ReadableIteratorConcept is causing several failures
> for the new iterator adaptors under BCB6.
>
> I have two possible patches, either of which solve the problem.
>
> # if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x564) )
> typedef BOOST_DEDUCED_TYPENAME
> boost::detail::iterator_traits<Iterator>::value_type value_type;
> typedef BOOST_DEDUCED_TYPENAME
> boost::detail::iterator_traits<Iterator>::reference reference;
> typedef BOOST_DEDUCED_TYPENAME
> boost::access_category<Iterator>::type access_category;
> # else
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::detail::iterator_traits<Iterator>::value_type value_type;
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::detail::iterator_traits<Iterator>::reference reference;
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::access_category<Iterator>::type access_category;
> # endif
>
> In this case, simply removing the global qualifier 'fixes' the parser.
> Alternatively:
>
> # if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x564) )
> typedef ::boost::detail::iterator_traits<Iterator> traits_type;
> typedef traits_type::value_type value_type;
> typedef traits_type::reference reference;
> typedef traits_type::type access_category;
> # else
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::detail::iterator_traits<Iterator>::value_type value_type;
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::detail::iterator_traits<Iterator>::reference reference;
> typedef BOOST_DEDUCED_TYPENAME
> ::boost::access_category<Iterator>::type access_category;
> # endif
>
> By introducing an intermediate typedef, the global-namespace qualifier
> is preserved. I am not clear why there are no dependent typenames in
> this second version, or if that is another BCB bug.
>
> Likewise, I'm not clear which form of patch is to be preferred, so
> present both <g>
>
> [I suspect the same patch will be required for the Kylix compiler,
> 0x570, as well, but don't have that available for testing]
>
> --
> AlisdairM
> Team Thai Kingdom
>
> _______________________________________________
> Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
>
-- Dave Abrahams Boost Consulting www.boost-consulting.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk