3 ms·
Why call it a regexp engine? Those are actually parser combinators with backtracking. They can parse much more than just regular languages, but are exponentiall
by cousin_it 15y ago
Why call it a regexp engine? Those are actually parser combinators with backtracking. They can parse much more than just regular languages, but are exponentially slower compared to a proper regexp engine.
- Peaker 15y agoregexps aren't regular, so most "proper" engines also do backtracking. Indeed, if you stick with the regular subset, you can be really fast: http://swtch.com/~rsc/regexp/regexp1.html http://swtch.com/~rsc/regexp/regexp1.html
- Peaker 15y agoThis parser also does not yield any value (besides accepted possibilities) nor does it allow to look at previous results.