summaryrefslogtreecommitdiff
path: root/regcomp.c
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2015-02-19 19:42:33 -0700
committerKarl Williamson <khw@cpan.org>2015-02-19 23:05:53 -0700
commit06ae27223f8f0af5633beb82c8be873ecadaaae3 (patch)
treef672431de09958d3a1cef7db44b18dc6cb820834 /regcomp.c
parentd3e558c4cd58bf26578bbee7f0852f8472539397 (diff)
downloadperl-06ae27223f8f0af5633beb82c8be873ecadaaae3.tar.gz
Add \b{sb}
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/regcomp.c b/regcomp.c
index 291a208a82..6052dc3d32 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -11823,6 +11823,12 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
}
FLAGS(ret) = GCB_BOUND;
break;
+ case 's':
+ if (length != 2 || *(RExC_parse + 1) != 'b') {
+ goto bad_bound_type;
+ }
+ FLAGS(ret) = SB_BOUND;
+ break;
case 'w':
if (length != 2 || *(RExC_parse + 1) != 'b') {
goto bad_bound_type;
@@ -16808,6 +16814,7 @@ Perl_regprop(pTHX_ const regexp *prog, SV *sv, const regnode *o, const regmatch_
const char * const bounds[] = {
"", /* Traditional */
"{gcb}",
+ "{sb}",
"{wb}"
};
sv_catpv(sv, bounds[FLAGS(o)]);