Commit Graph

15 Commits (8534174ea1d83d3d8a7ed9e8e837cd075daaa5e0)

Author SHA1 Message Date
Aadhavan Srinivasan cca8c7cda2 Got rid of transitions parameter, changed how kleene state is processed
I replaced the transition parameter for nfaState, replacing it with a
single nfaState pointer. This is because any non-alternation state will
only have one next state, so the map was just added complexity.

I changed alternation processing - instead of having their own dedicated
fields, they just use the new 'next' parameter, and another one called
'splitState'.

I also changed the kleene state processing to remove the unecessary
empty state in the right-side alternation (it actually messed up my
matching).
1 month ago
Aadhavan Srinivasan e0253dfaf3 Change kleene() to an alternation-style construct 1 month ago
Aadhavan Srinivasan de0d7345a8 Store left and right branches of alternation separately 1 month ago
Aadhavan Srinivasan 1fd48ae614 Store the current string pointer as a 'thread variable' (allows us to simulate backtracking) 1 month ago
Aadhavan Srinivasan ad0f7d0178 Added new state fields to tell if a state is a question or alternation 1 month ago
Aadhavan Srinivasan b129d83c3f Added function to reset threads 1 month ago
Aadhavan Srinivasan 8eda5055ff Replaced call to 'FindAllMatches' with call to 'FindAll' or 'FindAllSubmatch' depending on whether I need submatches 1 month ago
Aadhavan Srinivasan ee51e39d59 Added support for start-of-input (\A) and end-of-input (\Z) assertions 1 month ago
Aadhavan Srinivasan 7e792f1248 Renamed more constants to avoid exporting 1 month ago
Aadhavan Srinivasan 7aee4280cc Renamed 'EPSILON' to 'epsilon' to avoid exporting 1 month ago
Aadhavan Srinivasan 93474c5159 Renamed 'state' to 'nfaState' because 'state' by itself means nothing 1 month ago
Aadhavan Srinivasan d81b2ddaaa Renamed 'State' to 'state' to avoid exposing the insides of the engine 1 month ago
Aadhavan Srinivasan 429d286439 Renamed variable to avoid conflicting with type name 1 month ago
Aadhavan Srinivasan 289bba35e2 Updated assertion constants so that they aren't exported 1 month ago
Aadhavan Srinivasan aef8152fc1 Renamed package 'greg' to 'regex' 1 month ago