Commit Graph

22 Commits (7c62ba6bfdf9db60de31e61d49445fbc3e66e5da)

Author SHA1 Message Date
Aadhavan Srinivasan 7c62ba6bfd Started implementing Thompson's algorithm for matching, because the old one was completely backtracking (so it would enter infinite loops on something like '(a*)*' )
The git diff claims that a ton of code was changed, but most of it was just indentation changes.
1 month ago
Aadhavan Srinivasan d4e8cb74fd Replaced pointer to nfaState with nfaState 1 month ago
Aadhavan Srinivasan 3ce611d121 More work towards implementing PCRE matching 1 month ago
Aadhavan Srinivasan 753e973d82 Started rewrite of matching algorithm, got concatenation and alternation done, kleene and zero-state stuff is next 1 month ago
Aadhavan Srinivasan ad273b0c68 Trying to emulate backtracking by using string pointers within threads (something similar to rsc's 2nd regexp article) 1 month ago
Aadhavan Srinivasan bc32e0cb76 Started working on converting to PCRE matching rules (prefer left branch of alternation) 1 month ago
Aadhavan Srinivasan b6ab54f6dd Reset threads when findAllSubmatchHelper is called 1 month ago
Aadhavan Srinivasan a46d2f4546 Updated comments 1 month ago
Aadhavan Srinivasan c88ebd1aa5 Added comments explaining what a Match is 1 month ago
Aadhavan Srinivasan 6d692d0dfc Rename Group.toString() to Group.String() 1 month ago
Aadhavan Srinivasan b5e6bc112c Wrote 'reg.FindSubmatch()' which returns the leftmost match with submatches, renamed 'isValid' to 'IsValid' to export it, renamed 'ToString' to 'String' 1 month ago
Aadhavan Srinivasan 6869cd00a2 Return error instead of nil when 'Find' fails 1 month ago
Aadhavan Srinivasan 037ac75ea6 Wrote new method to return 0-group of leftmost match; reorganized some functions for better clarity; made 'FindNthMatch' a method 1 month ago
Aadhavan Srinivasan b685d2fd5f Renamed 'findAllMatchesHelper' to 'findAllSubmatchHelper' 1 month ago
Aadhavan Srinivasan e22822e619 Renamed 'FindAllMatches' to 'FindAll' and made it a method; made it return a slice of 0-groups; the functionality of 'FindAllMatches' is now in 'FindAllSubmatch' 1 month ago
Aadhavan Srinivasan 0d19664044 Cleared up some comments, wrote a skeleton for FindAllString 1 month ago
Aadhavan Srinivasan 1bfb09b6c7 Made 'FindString' a method of 'Reg' 1 month ago
Aadhavan Srinivasan b8f5b9af7c Updated one more reference to epsilon 1 month ago
Aadhavan Srinivasan be60f2fb51 Updated references to 'epsilon' 1 month ago
Aadhavan Srinivasan 93474c5159 Renamed 'state' to 'nfaState' because 'state' by itself means nothing 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