|
Boost : |
From: Angus Leeming (angus.leeming_at_[hidden])
Date: 2003-10-10 08:42:05
John Maddock wrote:
> There are two errors in your code:
>
> 1) you should check the return value of regex_match to see if there
> is some kind of match before checking what[0].matched to see if it
> was partial or not.
> 2) The second match fails because you called regex_match and the
> expression
> cannot match *all* of the text. If you want to match *some* of the
> text
> then use regex_search. The match_partial flag will only come into
> play if all of the text is matched, but not all of the expression.
Bingo! Many thanks.
Angus
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk