Boost logo

Boost :

From: John Maddock (john_at_[hidden])
Date: 2004-08-16 05:28:07


> Compilation of boost regex v4 (from the CVS) fails with the following
> error under VC6:
>
>
f:\projects\cpptool\cppparser_dependencies\cppparser\include\boost\regex\v4\
> basic_regex.hpp(221) : error C2143: syntax error : missing ',' before '<'
>
>
f:\projects\cpptool\cppparser_dependencies\cppparser\include\boost\regex\v4\
> basic_regex.hpp(298) : see reference to class template instantiation
> 'boost::reg_expression<charT,traits,Allocator>' being compiled
>
>
> Looking at the sources (inside template reg_expression definition):
>
> bool BOOST_REGEX_CALL operator==(const reg_expression& e)const
> { return compare(e) == 0; }
> bool operator != (const basic_regex<charT, traits, Allocator>& e) // <<<
> *** error here ***
> { return compare(e) != 0; }
>
> basic_regex is defined later in the source, hence the compilation
error.
> Also, the fact that operator == & != have different prototype is very
> suspicious... Using reg_expression instead or basic_regex would fix the
> error.

It is an error, and will be fixed in cvs shortly, for some strange reason
though I can't reproduce the error here with VC6 (shrug),

Thanks,

John.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk