summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Williamson <public@khwilliamson.com>2010-10-31 09:11:39 -0600
committerFather Chrysostomos <sprout@cpan.org>2010-10-31 14:49:11 -0700
commiteba1359ea44dc786981104981f7f0c719920e6ba (patch)
tree40c63d6e3178fac7b3ee48a8e2b4cd70ea93f400
parent8ff01ef0717d3f418692ebdcfbeff3221e20f9f8 (diff)
downloadperl-eba1359ea44dc786981104981f7f0c719920e6ba.tar.gz
regexec.c: Document existing reginclass behavior
-rw-r--r--regexec.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/regexec.c b/regexec.c
index 842afafe5f..cd7f74efb4 100644
--- a/regexec.c
+++ b/regexec.c
@@ -6181,10 +6181,16 @@ Perl_regclass_swash(pTHX_ const regexp *prog, register const regnode* node, bool
- reginclass - determine if a character falls into a character class
The n is the ANYOF regnode, the p is the target string, lenp
- is pointer to the maximum length of how far to go in the p
+ is pointer to the maximum number of bytes of how far to go in the p
(if the lenp is zero, UTF8SKIP(p) is used),
utf8_target tells whether the target string is in UTF-8.
+ Returns true if matched; false otherwise. For utf8 strings, if lenp is not
+ NULL, on return from a successful match, the value it points to will be
+ updated to how many bytes in p were matched. The value is undefined,
+ possibly changed from the input if there was no match.
+ For non-utf8 strings, *lenp is unchanged.
+
*/
STATIC bool