|
Boost : |
From: Gennaro Prota (gennaro_prota_at_[hidden])
Date: 2006-07-27 15:04:30
On Thu, 27 Jul 2006 13:38:46 -0500, Rene Rivera
<grafikrobot_at_[hidden]> wrote:
>Gennaro Prota wrote:
>> On Thu, 27 Jul 2006 18:48:12 +0100, "John Maddock"
>> <john_at_[hidden]> wrote:
>>
>>> Gennaro Prota wrote:
>>>> Hi,
>>>>
>>>> I'd like to point your attention toward the current status of our
>>>> regression testing. I'll not express opinions, but these are some
>>>> facts about 1.34:
>>>> The list is not exhaustive.
>>> Nope, my pet hate at present is http://tinyurl.com/jqe7j where the results
>>>from one test (an expected failure, marked up) are being listed under a
>>> completely different test :-(
>>
>> Argh :-(
>>
>> John, while you are here, I saw that you didn't reply about
>> identifying min/max guideline violations in comments being difficult
>> via regexes. That made me think twice, as I supposed it was pretty
>> easy to do with sub_matches or alternation. The basis seems to be
>> "//.*$" for single-line comments and "/\*.*?\*/" for multi-line ones.
>> What am I missing? :-)
>
>Comment looking substring embedded in string constants:
>
>const char *x = "/* something";
>/* whatever */
>
>And comments within comments:
>
>/**/ something /*/ another /**/
>
>/**
>something();
>//*/
>another();
>/**/
>
>/* something
>/* another
>*/
>
>Probably more combinations possible :-)
Ah sure. Also "my" "/\*.*?\*/" doesn't match /* */ style comments
which actually span multiple lines (:-O). But the intent wasn't to be
as accurate as a parser. We were talking about "tweaking" the regexes
a bit to avoid false positives. In short we wanted them to be just
more accurate than they are(n't) now. If there's no danger to let
violations go unnoticed with this, it seems still better than the
current code. Example: this gives a false positive in
boost/graph/maximum_cardinality_matching.hpp:
//[the Tutte-Berge]
//formula guarantees that
//
// 2 * M(G) = min ( |V(G)| + |U| + o(G - U) )
//
//where the minimum is taken over all subsets U of
//V(G).
It wouldn't if we filtered out one-line comments. And if that were in
a /* */ style comment, then simply adding "//" in front of the formula
line would do the trick.
PS: did you read my suggestion about commit triggers?
-- [ Gennaro Prota, C++ developer for hire ]
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk