Is there a high-level API for doing search-and-replace with regexes in Haskell? In particular, I\'m looking at the Text.Regex.TDFA or Text.Regex.Posix
Text.Regex.TDFA
Text.Regex.Posix
How about the Text.Regex.subRegex in package regex-compat?
regex-compat
Prelude> import Text.Regex (mkRegex, subRegex) Prelude> :t mkRegex mkRegex :: String -> Regex Prelude> :t subRegex subRegex :: Regex -> String -> String -> String Prelude> subRegex (mkRegex "foo") "foobar" "123" "123bar"