unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: "Daniel Martín" <mardani29@yahoo.es>
To: "Clément Pit-Claudel" <cpitclaudel@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: [PATCH] A program to overlay Elisp regular expressions in rx form
Date: Mon, 16 Nov 2020 20:20:44 +0100	[thread overview]
Message-ID: <m1lff1un03.fsf@yahoo.es> (raw)
In-Reply-To: <c6f5718e-ab84-9307-6836-ce7dad7d3974@gmail.com> ("Clément Pit-Claudel"'s message of "Sun, 15 Nov 2020 09:03:51 -0500")

Clément Pit-Claudel <cpitclaudel@gmail.com> writes:

> On 11/15/20 6:16 AM, Daniel Martín wrote:
>> Is there general interest in this kind of functionality as a free
>> program?  I don't know if this could be a new feature of the xr package
>> (most probably), or if it could be its own separate package.
> This is very nice.  I have a version of this in my local Emacs config,
> but it's on by default and it doesn't put the buffer in read-only
> more: it uses an overlay to display the rx regexp instead of the
> string-based one instead.  I've attached the code if you want to have
> a look; what's missing is logic to automatically "unprettify" the
> regexp when the point is in it, to make edits easy.
>
> I was originally planning to include this in the easy-escape package, but I haven't found the time to do it, so feel free to go ahead :)
>
> Clément.

Thanks for the link, your approach looks simpler, which is nice.  As you
said, the workflow is a little bit different: Your package prettifies
every regular expression at once and mine does so on a case by case
basis; I think it's a matter of preference.  I also prettify the final
rx form to make it more readable.

I didn't know about the easy-escape package.  I see it was suggested to
be included in Emacs core around 2017, but there were no responses back
then.  Maybe we could have this kind of functionality at least in ELPA?
I think it's a generally useful package.



  reply	other threads:[~2020-11-16 19:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <m1a6vi27kr.fsf.ref@yahoo.es>
2020-11-15 11:16 ` [PATCH] A program to overlay Elisp regular expressions in rx form Daniel Martín
2020-11-15 11:21   ` tumashu
2020-11-15 11:50   ` [PATCH] " Jean Louis
2020-11-15 14:03   ` Clément Pit-Claudel
2020-11-16 19:20     ` Daniel Martín [this message]
2020-11-15 18:15   ` Drew Adams
2020-11-16 13:25     ` Daniel Martín

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m1lff1un03.fsf@yahoo.es \
    --to=mardani29@yahoo.es \
    --cc=cpitclaudel@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).