From: K.Kosako Date: Tue, 30 Jul 2019 05:23:56 +0000 (+0900) Subject: refactoring X-Git-Tag: v6.9.3~12 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ecef60c08dd37d4087ed65c8d5e8e62d4cf8ee86;p=onig refactoring --- diff --git a/src/regcomp.c b/src/regcomp.c index e624c60..6bce252 100644 --- a/src/regcomp.c +++ b/src/regcomp.c @@ -974,7 +974,7 @@ compile_length_quantifier_node(QuantNode* qn, regex_t* reg) { int len, mod_tlen; int infinite = IS_INFINITE_REPEAT(qn->upper); - enum BodyEmpty emptiness = qn->emptiness; + enum BodyEmptyType emptiness = qn->emptiness; int tlen = compile_length_tree(NODE_QUANT_BODY(qn), reg); if (tlen < 0) return tlen; @@ -1048,7 +1048,7 @@ compile_quantifier_node(QuantNode* qn, regex_t* reg, ScanEnv* env) { int i, r, mod_tlen; int infinite = IS_INFINITE_REPEAT(qn->upper); - enum BodyEmpty emptiness = qn->emptiness; + enum BodyEmptyType emptiness = qn->emptiness; int tlen = compile_length_tree(NODE_QUANT_BODY(qn), reg); if (tlen < 0) return tlen; @@ -4031,7 +4031,7 @@ expand_case_fold_string(Node* node, regex_t* reg, int state) } #ifdef USE_INSISTENT_CHECK_CAPTURES_IN_EMPTY_REPEAT -static enum BodyEmpty +static enum BodyEmptyType quantifiers_memory_node_info(Node* node) { int r = BODY_IS_EMPTY_POSSIBILITY; diff --git a/src/regparse.h b/src/regparse.h index a2160a4..231f7b5 100644 --- a/src/regparse.h +++ b/src/regparse.h @@ -66,7 +66,7 @@ enum GimmickType { #endif }; -enum BodyEmpty { +enum BodyEmptyType { BODY_IS_NOT_EMPTY = 0, BODY_IS_EMPTY_POSSIBILITY = 1, BODY_IS_EMPTY_POSSIBILITY_MEM = 2, @@ -101,7 +101,7 @@ typedef struct { int lower; int upper; int greedy; - enum BodyEmpty emptiness; + enum BodyEmptyType emptiness; struct _Node* head_exact; struct _Node* next_head_exact; int is_refered; /* include called node. don't eliminate even if {0} */