bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#36237: Support (rx (and (regexp EXPR) (regexp-quote EXPR)))


From: Noam Postavsky
Subject: bug#36237: Support (rx (and (regexp EXPR) (regexp-quote EXPR)))
Date: Sun, 23 Jun 2019 11:46:04 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)

Mattias Engdegård <mattiase@acm.org> writes:
>
> what I meant is that the docs frequently use "form" for the `rx'
> whatchamacallits even though they aren't Lisp expressions. The
> terminology is a mess; use whatever you find understandable.

Well, the rest of the rx docstring uses SEXP for the `rx'
whatchamacallits, so I think leaving it as (eval FORM) should be fine.
And hopefully we'll be able to deprecate eval soon enough so it won't
matter too much.

>>squash! Support (rx (and (regexp EXPR) (literal EXPR))) (Bug#36237)
>
> Remnants of rebase editing?

Oops, yes.  I wish git would comment out the "squash!..." line
automatically.

> since the order of the branches matters. Maybe it's the regexp string
> that should be the other way around; hard to tell without any context.

Yeah, I switched the regexp string instead, on the grounds that
otherwise "$" would almost never match (except at end of buffer) since
[^:] already matches \n.

> +`(regexp REGEXP-EXPR)'
> +     include REGEXP-EXPR in string notation in the result, where
> +     REGEXP-EXPR is any lisp expression that evaluates a string
> +     containing a valid regexp.
>
> Missed "to" after "evaluate"?

Oops.

> I'm happy with the patch after the obvious fixes.

I'll wait a few more days in case something else comes up.

Drew Adams <drew.adams@oracle.com> writes:

> Minor:
>
>  "at run-time" -> "at run time"
>
> Emacs docs seem to use "runtime" as
> adjective and "run time" as noun, which
> is fairly conventional.  Sometimes,
> outside Emacs, "runtime" is used for both.

The elisp manual has a couple of "run-time" as well, but more cases of
"run time" so I went with that.

Attachment: 0001-Support-rx-and-regexp-EXPR-literal-EXPR-Bug-36237.patch
Description: patch


reply via email to

[Prev in Thread] Current Thread [Next in Thread]