sebfisch / haskell-regexp

Regular Expression Matching in Haskell
http://sebfisch.github.com/haskell-regexp/
Other
34 stars 5 forks source link

lazy quantification #15

Closed sebfisch closed 14 years ago

sebfisch commented 14 years ago

Some implementations allow the quantifiers *? and +? to avoid the longest match policy. For example <.*> matches <a><b> completely whereas <.*?> would match <a> and <b> separately.

Our implementation currently does not only compute longest but all matchings and we can filter them according to a policy such as longest or shortest match. On the other hand we cannot mix longest and shortest match in a single regular expression.

sebfisch commented 14 years ago

matching policies are now implemented as semiring instances.