Re:A Regular Expression Matcher (2007)
by abecedarius on Thursday February 13, 2020 @03:29PM
(#22321145)
Wow. That's quite a tricky test, too -- if you study Thompson's original paper you can see plenty of pitfalls. E.g. his main code would loop forever on a star of a star, and he solves this in an appendix with a preprocessor to rewrite regexes of that kind, only it looked like that rewriting would blow up the size of the regex exponentially in the length of the stack of stars. No hire!
[ Parent
| on HN ]