
Hi I'm getting a compile error in Visual Studio 8 with boost 1.33.1 It looks like the boost namespace is not being honored, as ATL::CString has no business here. I don't know how to get around it, other than rewriting this function: boost::split( splitVec, csText, boost::is_any_of(",") ); The boost::is_any_of call triggers the error. 1>w:\boost\boost_1_33_1\boost\range\const_iterator.hpp(36) : error C2039: 'const_iterator' : is not a member of 'ATL::CStringT<BaseType,StringTraits>' 1> with 1> [ 1> BaseType=char, 1> StringTraits=StrTraitMFC_DLL<char> 1> ] 1> w:\boost\boost_1_33_1\boost\range\result_iterator.hpp(35) : see reference to class template instantiation 'boost::range_const_iterator<C>' being compiled 1> with 1> [ 1> C=CString 1> ] 1> w:\boost\boost_1_33_1\boost\algorithm\string\iter_find.hpp(144) : see reference to class template instantiation 'boost::range_result_iterator<C>' being compiled 1> with 1> [ 1> C=CString 1> ] 1> w:\boost\boost_1_33_1\boost\algorithm\string\split.hpp(148) : see reference to function template instantiation 'SequenceSequenceT &boost::algorithm::iter_split<SequenceSequenceT,RangeT,boost::algorithm::detail::token_finderF<PredicateT>>(SequenceSequenceT &,RangeT &,FinderT)' being compiled 1> with 1> [ 1> SequenceSequenceT=std::vector<std::string>, 1> RangeT=CString, 1> PredicateT=boost::algorithm::detail::is_any_ofF<char>, 1> FinderT=boost::algorithm::detail::token_finderF<boost::algorithm::detail::is_any_ofF<char>> 1> ] 1> c:\codejock apps\qp charts\charts\exportlisttoasciidlg.cpp(98) : see reference to function template instantiation 'SequenceSequenceT &boost::algorithm::split<std::vector<_Ty>,CString,boost::algorithm::detail::is_any_ofF<CharT>>(SequenceSequenceT &,RangeT &,PredicateT,boost::algorithm::token_compress_mode_type)' being compiled 1> with 1> [ 1> SequenceSequenceT=std::vector<std::string>, 1> _Ty=std::string, 1> CharT=char, 1> RangeT=CString, 1> PredicateT=boost::algorithm::detail::is_any_ofF<char> 1> ] Any help is certainly appreciated. Best regards, Gary Lyben

----Original Message---- From: boost-bounces@lists.boost.org [mailto:boost-bounces@lists.boost.org] On Behalf Of gary Sent: 27 October 2006 05:26 To: boost@lists.boost.org Subject: [boost] bug visual studio 8
Hi
I'm getting a compile error in Visual Studio 8 with boost 1.33.1
It looks like the boost namespace is not being honored, as ATL::CString has no business here.
I don't know how to get around it, other than rewriting this function: boost::split( splitVec, csText, boost::is_any_of(",") );
What is the type of splitVec and csText? ATL:CString has business everywhere because the ATL headers have a "using namespace ATL;" in them. Is the problem something to do with the fact that "," is getting implicitly converted to CString?
see reference to class template instantiation 'boost::range_const_iterator<C>' being compiled 1> with 1> [ 1> C=CString 1> ] 1>
Maybe you need to specialize boost::range_const_iterator<CString> With luck, somebody who knows something about boost::range will be along shortly to explain why all of the above is rubbish. I have added a [range] token to the title to encourage that to happen. -- Martin Bonner Martin.Bonner@Pitechnology.com Pi Technology, Milton Hall, Ely Road, Milton, Cambridge, CB24 6WZ, ENGLAND Tel: +44 (0)1223 203894

Hello Thank you for taking a look at this. The problem was indeed that csText was a CString. Once I converted it to a std::string, the compile was clean. I've been using mfc forever, but am pretty new to boost and std, so I have to get used to the error messages. Best regards, Gary Lyben ----- Original Message ----- From: "Martin Bonner" <martin.bonner@pitechnology.com> To: <boost@lists.boost.org> Sent: Friday, October 27, 2006 5:03 AM Subject: Re: [boost] [range] bug visual studio 8
----Original Message---- From: boost-bounces@lists.boost.org [mailto:boost-bounces@lists.boost.org] On Behalf Of gary Sent: 27 October 2006 05:26 To: boost@lists.boost.org Subject: [boost] bug visual studio 8
Hi
I'm getting a compile error in Visual Studio 8 with boost 1.33.1
It looks like the boost namespace is not being honored, as ATL::CString has no business here.
I don't know how to get around it, other than rewriting this function: boost::split( splitVec, csText, boost::is_any_of(",") );
What is the type of splitVec and csText?
ATL:CString has business everywhere because the ATL headers have a "using namespace ATL;" in them.
Is the problem something to do with the fact that "," is getting implicitly converted to CString?
see reference to class template instantiation 'boost::range_const_iterator<C>' being compiled 1> with 1> [ 1> C=CString 1> ] 1>
Maybe you need to specialize boost::range_const_iterator<CString>
With luck, somebody who knows something about boost::range will be along shortly to explain why all of the above is rubbish. I have added a [range] token to the title to encourage that to happen.
-- Martin Bonner Martin.Bonner@Pitechnology.com Pi Technology, Milton Hall, Ely Road, Milton, Cambridge, CB24 6WZ, ENGLAND Tel: +44 (0)1223 203894 _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
participants (2)
-
gary
-
Martin Bonner