Skip to content

Commit 6159afc

Browse files
committed
RExC_state_t: convert in_multi_char_class to boolean
1 parent cc8c9ac commit 6159afc

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

regcomp.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1695,7 +1695,7 @@ Perl_re_op_compile(pTHX_ SV ** const patternp, int pat_count,
16951695
RExC_in_lookaround = false;
16961696
RExC_seen_zerolen = *exp == '^' ? -1 : 0;
16971697
RExC_recode_x_to_native = false;
1698-
RExC_in_multi_char_class = 0;
1698+
RExC_in_multi_char_class = false;
16991699

17001700
RExC_start = RExC_copy_start_in_constructed = RExC_copy_start_in_input = RExC_precomp = exp;
17011701
RExC_precomp_end = RExC_end = exp + plen;
@@ -10822,7 +10822,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
1082210822
RExC_parse_set( RExC_start );
1082310823
RExC_copy_start_in_constructed = RExC_start + constructed_prefix_len;
1082410824
RExC_end = RExC_parse + len;
10825-
RExC_in_multi_char_class = 1;
10825+
RExC_in_multi_char_class = true;
1082610826

1082710827
ret = reg(pRExC_state, 1, &reg_flags, depth+1);
1082810828

@@ -10832,7 +10832,7 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth,
1083210832
RExC_parse_set(save_parse);
1083310833
RExC_start = RExC_copy_start_in_constructed = RExC_copy_start_in_input = save_start;
1083410834
RExC_end = save_end;
10835-
RExC_in_multi_char_class = 0;
10835+
RExC_in_multi_char_class = false;
1083610836
SvREFCNT_dec_NN(multi_char_matches);
1083710837
SvREFCNT_dec(properties);
1083810838
SvREFCNT_dec(cp_list);

regcomp_internal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ struct RExC_state_t {
143143
bool in_lookaround;
144144
bool contains_locale;
145145
bool recode_x_to_native;
146-
I32 in_multi_char_class;
146+
bool in_multi_char_class;
147147
int code_index; /* next code_blocks[] slot */
148148
struct reg_code_blocks *code_blocks;/* positions of literal (?{})
149149
within pattern */

0 commit comments

Comments
 (0)