Opened 8 years ago
Closed 8 years ago
#10114 closed Bugs (fixed)
Incorrect position of partial match when using u32regexes
Reported by: | Owned by: | John Maddock | |
---|---|---|---|
Milestone: | To Be Determined | Component: | regex |
Version: | Boost 1.55.0 | Severity: | Problem |
Keywords: | regex icu | Cc: | mkrasowski@… |
Description
Hi,
I got a problem with results of partial matches when using ICU Unicode strings and u32regex_iterator. The regular expression is created with default flags and search is done using match_perl | match_partial. Tested on 64bit Linux, boost compiled against ICU 53 with gcc 4.9.
When searched for regular experession: "summary" in string "in summary in math we are using sum", and for regular expressions based on std::string got the following results:
match length: 7 match position: 3 matched: summary match length: 0 match position: 32 matched: sum
when doing search using icu::UnicodeString and u32regex_iterator got the following result:
match length: 7 match position: 3 matched: summary match length: 0 match position: 35 matched:
So in both cases the partial match is found but in the latter the returned position is incorrect.
I attached a simple application I used for testing.
Regards, marcin
Attachments (1)
Change History (2)
by , 8 years ago
Attachment: | regex_iter.cc added |
---|
comment:1 by , 8 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
With apologies for the delay, fixed in https://github.com/boostorg/regex/commit/f6a9bce728c8451d212836460aece6dfb7aa0896
simple program used for testing