summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2018-11-06 18:44:46 -0700
committerKarl Williamson <khw@cpan.org>2018-11-16 10:48:19 -0700
commit25f472ce814259c264beeacdb8dfb8b12209ae43 (patch)
tree862ce963d6309a231431244807a1fee0c6a44e85
parentbd0b62a660635ad32a22aa96c5f1f0c45dc3127d (diff)
downloadperl-25f472ce814259c264beeacdb8dfb8b12209ae43.tar.gz
regcomp.c: Remove now always NULL parameter
This parameter is always NULL. No need to have it in this static function
-rw-r--r--embed.fnc3
-rw-r--r--embed.h2
-rw-r--r--proto.h2
-rw-r--r--regcomp.c20
4 files changed, 9 insertions, 18 deletions
diff --git a/embed.fnc b/embed.fnc
index 0838fa70a6..283f753e24 100644
--- a/embed.fnc
+++ b/embed.fnc
@@ -2399,8 +2399,7 @@ Es |regnode_offset|regclass|NN RExC_state_t *pRExC_state \
|const bool silence_non_portable \
|const bool strict \
|bool optimizable \
- |NULLOK SV** ret_invlist \
- |NULLOK AV** return_posix_warnings
+ |NULLOK SV** ret_invlist
Es |void|add_above_Latin1_folds|NN RExC_state_t *pRExC_state|const U8 cp \
|NN SV** invlist
Ei |regnode_offset|handle_named_backref|NN RExC_state_t *pRExC_state \
diff --git a/embed.h b/embed.h
index a1527764eb..168c19be96 100644
--- a/embed.h
+++ b/embed.h
@@ -1214,7 +1214,7 @@
#define reganode(a,b,c) S_reganode(aTHX_ a,b,c)
#define regatom(a,b,c) S_regatom(aTHX_ a,b,c)
#define regbranch(a,b,c,d) S_regbranch(aTHX_ a,b,c,d)
-#define regclass(a,b,c,d,e,f,g,h,i,j) S_regclass(aTHX_ a,b,c,d,e,f,g,h,i,j)
+#define regclass(a,b,c,d,e,f,g,h,i) S_regclass(aTHX_ a,b,c,d,e,f,g,h,i)
#define regex_set_precedence S_regex_set_precedence
#define reginsert(a,b,c,d) S_reginsert(aTHX_ a,b,c,d)
#define regnode_guts(a,b,c,d) S_regnode_guts(aTHX_ a,b,c,d)
diff --git a/proto.h b/proto.h
index a56ad89440..8ed7b9b9a9 100644
--- a/proto.h
+++ b/proto.h
@@ -5536,7 +5536,7 @@ STATIC regnode_offset S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32
STATIC regnode_offset S_regbranch(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, I32 first, U32 depth);
#define PERL_ARGS_ASSERT_REGBRANCH \
assert(pRExC_state); assert(flagp)
-STATIC regnode_offset S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth, const bool stop_at_1, bool allow_multi_fold, const bool silence_non_portable, const bool strict, bool optimizable, SV** ret_invlist, AV** return_posix_warnings);
+STATIC regnode_offset S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth, const bool stop_at_1, bool allow_multi_fold, const bool silence_non_portable, const bool strict, bool optimizable, SV** ret_invlist);
#define PERL_ARGS_ASSERT_REGCLASS \
assert(pRExC_state); assert(flagp)
STATIC unsigned int S_regex_set_precedence(const U8 my_operator)
diff --git a/regcomp.c b/regcomp.c
index cc64902938..88e5d59948 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -13160,7 +13160,6 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
FALSE, /* don't silence non-portable warnings. */
(bool) RExC_strict,
TRUE, /* Allow an optimized regnode result */
- NULL,
NULL);
if (ret == 0) {
RETURN_FAIL_ON_RESTART_FLAGP_OR_FLAGS(flagp, NEED_UTF8);
@@ -13472,7 +13471,6 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
non-portables */
(bool) RExC_strict,
TRUE, /* Allow an optimized regnode result */
- NULL,
NULL);
RETURN_FAIL_ON_RESTART_FLAGP(flagp);
/* regclass() can only return RESTART_PARSE and NEED_UTF8 if
@@ -15689,8 +15687,7 @@ redo_curchar:
FALSE, /* don't silence non-portable warnings. */
TRUE, /* strict */
FALSE, /* Require return to be an ANYOF */
- &current,
- NULL))
+ &current))
{
FAIL2("panic: regclass returned failure to handle_sets, "
"flags=%#" UVxf, (UV) *flagp);
@@ -15727,9 +15724,7 @@ redo_curchar:
TRUE, /* silence non-portable warnings. */
TRUE, /* strict */
FALSE, /* Require return to be an ANYOF */
- &current,
- NULL
- ))
+ &current))
{
FAIL2("panic: regclass returned failure to handle_sets, "
"flags=%#" UVxf, (UV) *flagp);
@@ -16079,7 +16074,6 @@ redo_curchar:
they're valid on this machine */
FALSE, /* similarly, no need for strict */
FALSE, /* Require return to be an ANYOF */
- NULL,
NULL
);
@@ -16397,8 +16391,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
const bool strict,
bool optimizable, /* ? Allow a non-ANYOF return
node */
- SV** ret_invlist, /* Return an inversion list, not a node */
- AV** return_posix_warnings
+ SV** ret_invlist /* Return an inversion list, not a node */
)
{
/* parse a bracketed class specification. Most of these will produce an
@@ -16524,7 +16517,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
char *not_posix_region_end = RExC_parse - 1;
AV* posix_warnings = NULL;
- const bool do_posix_warnings = return_posix_warnings || ckWARN(WARN_REGEXP);
+ const bool do_posix_warnings = ckWARN(WARN_REGEXP);
U8 op = END; /* The returned node-type, initialized to an impossible
one. */
U8 anyof_flags = 0; /* flag bits if the node is an ANYOF-type */
@@ -16605,7 +16598,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
* caller. This is done each time through the loop so that a later
* class won't zap them before they have been dealt with. */
output_or_return_posix_warnings(pRExC_state, posix_warnings,
- return_posix_warnings);
+ NULL);
}
if (RExC_parse >= stop_ptr) {
@@ -17637,8 +17630,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
if ( posix_warnings && av_tindex_skip_len_mg(posix_warnings) >= 0) {
- output_or_return_posix_warnings(pRExC_state, posix_warnings,
- return_posix_warnings);
+ output_or_return_posix_warnings(pRExC_state, posix_warnings, NULL);
}
/* If anything in the class expands to more than one character, we have to