On Thu, 25 Aug 2022 09:24:20 GMT, Raffaello Giulietti <d...@openjdk.org> wrote:

>> Add support for named groups to java.util.regex.MatchResult
>
> Raffaello Giulietti has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   8065554: MatchResult should provide values of named-capturing groups

Overall the specs, code, and tests look pretty good. I do think some areas of 
the spec need updating; sorry I didn't get to this before you created the CSR.

The test is OK, but it's starting to get to the point where it would be 
profitable to use TEST-NG data providers to collapse some of the test cases. We 
have two implementations of MatchResult: one is Matcher itself, and the other 
is the internal implementation returned by toMatchResult(). The setup for them 
differs somewhat, but the assertions should all be the same. This is kind of 
hard to see with separate test methods for Matcher and MatchResult. The test is 
reasonable as it stands, but we'll see what it looks like after the cases for 
checking exceptions from start(String), end(String), and group(String) are 
expanded.

-------------

PR: https://git.openjdk.org/jdk/pull/10000

Reply via email to