mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
Warn duplicated characters in character class of regexp. [ruby-core:24593]
* include/ruby/oniguruma.h (ONIG_SYN_WARN_CC_DUP): defined. * regparse.h (ScanEnv): add warnings_flag. * regparse.c (CC_DUP_WARN): defined for warn duplicated characters in character class of regexp. [ruby-core:24593] (add_code_range_to_buf): add CC_DUP_WARN. (next_state_val): add CC_DUP_WARN. (OnigSyntaxRuby): add ONIG_SYN_WARN_CC_DUP. (SET_ALL_MULTI_BYTE_RANGE): add env to arguments. (add_code_range): ditto. (add_code_range_to_buf): ditto. (not_code_range_buf): ditto. (or_code_range_buf): ditto. (and_code_range1): ditto. (and_code_range_buf): ditto. (and_cclass): ditto. (or_cclass): ditto. (add_ctype_to_cc_by_range): ditto. (add_ctype_to_cc): ditto. (parse_char_class): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
38107457a3
commit
60ab77a16a
4 changed files with 103 additions and 51 deletions
|
@ -306,6 +306,7 @@ typedef struct {
|
|||
int curr_max_regnum;
|
||||
int has_recursion;
|
||||
#endif
|
||||
int warnings_flag;
|
||||
} ScanEnv;
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue