S
Simon Strandgaard
download:
http://rubyforge.org/frs/?group_id=18&release_id=465
play with regexp online:
http://neoneye.dk/regexp.rbx
RAA entry:
http://raa.ruby-lang.org/list.rhtml?name=regexp
I am proud to present an Regexp-engine written entirely in Ruby,
fairly compatible with Ruby's native engine (GNU).
There are 2 major changes since last version:
* Added lookbehind positive/negative of variable-width.
/g(?<=(a.*)g)o./ ~= 'goa algol goto' #-> ['gol', 'a al']
For instance the Oniguruma engine chokes on such expressions
because it only supports fixed-width lookbehind.
* I now preserve subcaptures (Earlier I accidentially cleared subcaptures).
/a(|ab)*b/ ~= 'aaabbb' #-> ['aabb', 'ab']
For instance the Oniguruma engine very often clears subcaptures,
and in this case it outputs ['aabb', ''].. which is less desired.
http://rubyforge.org/frs/?group_id=18&release_id=465
play with regexp online:
http://neoneye.dk/regexp.rbx
RAA entry:
http://raa.ruby-lang.org/list.rhtml?name=regexp
I am proud to present an Regexp-engine written entirely in Ruby,
fairly compatible with Ruby's native engine (GNU).
There are 2 major changes since last version:
* Added lookbehind positive/negative of variable-width.
/g(?<=(a.*)g)o./ ~= 'goa algol goto' #-> ['gol', 'a al']
For instance the Oniguruma engine chokes on such expressions
because it only supports fixed-width lookbehind.
* I now preserve subcaptures (Earlier I accidentially cleared subcaptures).
/a(|ab)*b/ ~= 'aaabbb' #-> ['aabb', 'ab']
For instance the Oniguruma engine very often clears subcaptures,
and in this case it outputs ['aabb', ''].. which is less desired.