mirror of
https://github.com/corda/corda.git
synced 2025-01-08 14:03:06 +00:00
944f5f3567
So far, these are humble beginnings indeed. Based on the descriptions of http://swtch.com/%7Ersc/regexp/regexp2.html I started implementing a Thompson NFA / Pike VM. The idea being that eventually, regular expressions are to be compiled into special-purpose bytecode for the Pike VM that executes a varying number of threads in lock-step over each character of the text to match. The thread count is bounded by the length of the program: two different threads with identical instruction pointer at the same character-to-match would yield exactly the same outcome (and therefore, we can execute just one such thread instead of possibly many). To allow for matching groups, each thread carries a state with it, saving the group offsets acquired so far. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> |
||
---|---|---|
.. | ||
Matcher.java | ||
Pattern.java | ||
PikeVM.java | ||
PikeVMOpcodes.java | ||
TrivialMatcher.java | ||
TrivialPattern.java |