Improve wxRegEx::GetMatch() return value documentation
Don't imply that the function returns false for the empty capture groups because this is not the case (and never was). See #22708.
This commit is contained in:
parent
f242ad534b
commit
537f11fd4d
1 changed files with 6 additions and 2 deletions
|
|
@ -240,8 +240,12 @@ public:
|
|||
May only be called after successful call to Matches() and only if @c wxRE_NOSUB
|
||||
was @b not used in Compile().
|
||||
|
||||
Returns @false if no match or if an error occurred.
|
||||
|
||||
This function only returns @false if the regex didn't match at all or
|
||||
one of the arguments is invalid (e.g. @a index is greater or equal than
|
||||
the number of captures) and returns @true in all the other cases, even
|
||||
if the corresponding capture group didn't match anything, which can be
|
||||
the case when using captures in different alternation (@c "|"). In this
|
||||
case the returned @a len is @c 0 and @a start is @c -1.
|
||||
*/
|
||||
bool GetMatch(size_t* start, size_t* len, size_t index = 0) const;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue