Find a regular expression that matches a string?
- by Mirai
I need a model for finding all of the regular expressions that would match a particular string. Basically, I need an algorithm for doing what I do to generate a regex search string from some pattern.
My purpose for this to create a list of potential regular expressions from a selection of text and order that list from least specific (i.e. string of characters with abitrary length) to most specific (i.e. the string itself) to be used in text editor.