Regular expressions are a powerful practical tool for string processing. But there are simple examples of useful string processing tasks (like, say, removing brackets from an expression (E) -> E
when E
might itself contain brackets) which cannot be represented by a convenient regular expression.
Is there a language of expressions that can be used to conveniently process patterns defined by a context-free grammar?