* regcomp.c (print_indent_tree): make a function for debug static.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57420 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regcomp.c (get_min_match_length): Fix compile error with old version
of fcc (Fujitsu C Compiler) on Solaris 10. [Bug #13059][ruby-dev:49909]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* meta character \X matches Unicode 9.0.0 characters with some workarounds
for UTR #51 Unicode Emoji, Version 4.0 emoji zwj sequences.
[Feature #12831] [ruby-core:77586]
The term "character" can have many meanings bytes, codepoints, combined
characters, and so on. "grapheme cluster" is highest one of such words,
which means user-perceived characters.
Unicode Standard Annex #29 UNICODE TEXT SEGMENTATION specifies how to
handle grapheme clusters (extended grapheme cluster).
But some specs aren't updated to current situation because Unicode Emoji
is rapidly extended without well definition.
It breaks the precondition of UTR#29 "Grapheme cluster boundaries can be
easily tested by looking at immediately adjacent characters". (the
sentence will be removed in the next version)
Though some of its detail are described in Unicode Technical Report #51
UNICODE EMOJI but it is not merged into UTR#29 yet.
http://unicode.org/reports/tr29/http://unicode.org/reports/tr51/http://unicode.org/Public/emoji/4.0/
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56949 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Ruby's Regexp doesn't allow normal numbered groups if the regexp
has named groups. On such case it optimizes out related NT_ENCLOSE.
But even on the case it can use \g<0>.
This fix not to remove NT_ENCLOSE whose regnum is 0.
[ruby-core:75828] [Bug #12454]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
[bug] fix problem with optimization of \z (Issue #16) [Bug #8210]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40276 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
children bug. patched by Suraj Kurapati. [ruby-core:40964]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33754 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
AnchorNode's type is ANCHOR_PREC_BEHIND or ANCHOR_PREC_BEHIND_NOT
and divide_look_behind_alternatives() divided it to NT_ALT or
NT_LIST. [ruby-core:33370]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29939 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
in prelude (or other boot processes) or not.
* regcomp.c (optimize_node_left): use onig_is_prelude for printing.
* regcomp.c (set_optimize_info_from_tree): ditto.
* regcomp.c (onig_compile): ditto.
* regcomp.c (print_compiled_byte_code_list): print its address.
* regcomp.c (print_indent_tree): print its contents tree of
ANCHOR_PREC_READ(_NOT) and ANCHOR_PREC_BEHIND(_NOT).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29928 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regcomp.c (print_optimize_info): use %ld because the type of
calcutated value of integers is long.
* regexec.c (onig_print_compiled_byte_code): add prototype.
* regexec.c (match_at): add 2nd argument.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29926 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regcomp.c (op2name): constify return value.
* regcomp.c (onig_print_compiled_byte_code): use PRIuPTR and
uintptr_t to clean warnings.
* regcomp.c (print_indent_tree): use PRIxPTR and intptr_t.
* regexec.c (match_at): use PRIdPTR and intptr_t.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29811 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Without this change, captured groups in anchors (look-ahead,
look-behind, and so on) are not removed and
unintended invalid backref error occur. [ruby-core:28235]
* regcomp.c (renumber_by_map): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26796 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
converting into (?>.*), which does not backtrack. [ruby-core:27791]
* test/ruby/test_regexp.rb: add a test for above.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This bug also affects original Oniguruma. [ruby-core:27247]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regsyntax.c, unicode.c: new files along with Oniguruma 5.x.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e