Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/smasher164/matcher
A regular expression engine.
https://github.com/smasher164/matcher
Last synced: about 2 months ago
JSON representation
A regular expression engine.
- Host: GitHub
- URL: https://github.com/smasher164/matcher
- Owner: smasher164
- License: mit
- Created: 2016-12-08T02:05:00.000Z (about 8 years ago)
- Default Branch: dfa
- Last Pushed: 2017-03-23T16:48:55.000Z (almost 8 years ago)
- Last Synced: 2024-06-20T06:24:46.878Z (7 months ago)
- Language: Go
- Homepage: https://godoc.org/github.com/smasher164/matcher
- Size: 178 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# matcher
This regular expression package is inspired from Russ Cox's
article "Regular Expression Matching Can Be Simple And Fast".
https://swtch.com/~rsc/regexp/regexp1.htmlUses Thompson construction for the NFA from
Communications of the ACM
Volume 11 Issue 6, June 1968
"Programming Techniques: Regular expression search algorithm"DFA construction is based off of powerset construction while
caching the result after each state.Lexer is inspired by Rob Pike's lecture: "Lexical Scanning in Go"
https://youtu.be/HxaD_trXwREDocumentation: https://godoc.org/github.com/smasher164/matcher
```
c matches any literal character c
. matches any single character
* matches zero or more occurrences of the previous character
| matches the previous character or the next character
```Slides for presentation at http://go-talks.appspot.com/github.com/smasher164/matcher/pres/matcher.slide.