Lloyd Zusman writes: > [ ... ] > > As an example, this proposed function/macro would convert the expression > marked as "Perl" to the one marked "Emacs" (note that I'm writing these > as if they would appear inside of an Elisp string, and therefore, the > backslashes are all doubled): > > Perl: ^(.+?\\.)+(com|net|org)$ > Emacs: ^\\(.+?\\.\\)+\\(com\\|net\\|org\\)$ > > [ ... ] Well, I found something. In case anyone is interested, I'm enclosing it. It's something that was originally called "rx.el", and it implements some functions and macros that permit a less-backslash-laden regular expression syntax. It's by Will Mengarini and it was written in 1998/1999. Because its name conflicts with the current "rx.el", I have renamed it to "xr.el" (with the package name being "xr" instead of "rx"). It implements the syntax I want, with the small exception being that it uses the backtick (`) instead of the backslash (\) as its escape character. To me, that's a small price to pay for more readability. The xr syntax for the regular expression above would be this: ^(.+?`.)+(com|net|org)$ It also implements a few functions that correspond to standard elisp functions, but which use this alternate regexp syntax: xr= corresponds to `string-match' xr@ corresponds to `looking-at' xr-search-forward corresponds to `re-search-forward' xr-search-backward corresponds to `re-search-backward' xr-query-replace corresponds to `query-replace-regexp' I've already put this package into much of my commonly used elisp code, and it is working very nicely.