2 ms·
I initially started with this article when I first looked into the issue of regex performance https://swtch.com/~rsc/regexp/regexp1.html https://swtch.com/~rsc
by tmaly 11y ago
I initially started with this article when I first looked into the issue of regex performance
https://swtch.com/~rsc/regexp/regexp1.html https://swtch.com/~rsc/regexp/regexp1.html
To generate state machines
For C there is re2c http://re2c.org/ http://re2c.org/
For Go there is https://github.com/opennota/re2dfa https://github.com/opennota/re2dfa
My patterns do not change that often, so I end up hand coding them.
If you are looking to continue using regex for matching, I would look at using the TCL regex library as it has some optimizations that other regex libraries do not have.