GNU bug report logs - #46910
27.1; (elisp) RX doc

Previous Next

Package: emacs;

Reported by: Drew Adams <drew.adams <at> oracle.com>

Date: Wed, 3 Mar 2021 23:17:02 UTC

Severity: wishlist

Found in version 27.1

Done: Mattias Engdegård <mattiase <at> acm.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 46910 in the body.
You can then email your comments to 46910 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#46910; Package emacs. (Wed, 03 Mar 2021 23:17:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Drew Adams <drew.adams <at> oracle.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 03 Mar 2021 23:17:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: 27.1; (elisp) RX doc
Date: Wed, 3 Mar 2021 23:15:59 +0000
1. `Rx Constructs' doesn't explain that the "constructs" are used in
arguments to macro `rx'.

E.g.: "some-string" is not an RX expression.
      (rx "some-string") is an RX expression.

Please make this clear.

2. `Rx Constructs': Don't show things like `\sCODE' without saying what
CODE means.  If the column title for the table explaining RX names is
`Syntax character' or `Category character' then that's apparently what
CODE corresponds to for `\sCODE' or `\cCODE'.  But there's no way to
know that unless you're already familiar with `\s' and `\c' syntax.

3. `Rx Constructs', `Zero-width assertions': Call this `Zero-width
matching' or some such.

4. `Rx Functions': RX-EXPR is used as parameter name for what is, I
guess an Rx construct (the language used in `Rx Construct').  Expression
or construct?  Make it clear that RX-EXPR is an RX construct, if that's
what it is.  And consider adding an xref to `Rx Construct'.

5. `Rx Functions': A couple places talk about `'regexp' forms', but
those are specified nowhere, AFAICT.  The same places talk about
'literal' forms, which are specified, but which don't seem to work (?).
(See bug #46909.)


In GNU Emacs 27.1 (build 1, x86_64-w64-mingw32)
 of 2020-08-12
Repository revision: 86d8d76aa36037184db0b2897c434cdaab1a9ae8
Windowing system distributor `Microsoft Corp.', version 10.0.19041
Configured using:
 `configure --without-dbus --host=x86_64-w64-mingw32
 --without-compress-install 'CFLAGS=-O2 -static''





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#46910; Package emacs. (Sat, 25 Sep 2021 15:26:02 GMT) Full text and rfc822 format available.

Message #8 received at 46910 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: Mattias Engdegård <mattiase <at> acm.org>,
 46910 <at> debbugs.gnu.org
Subject: Re: bug#46910: 27.1; (elisp) RX doc
Date: Sat, 25 Sep 2021 08:25:38 -0700
Drew Adams <drew.adams <at> oracle.com> writes:

> 1. `Rx Constructs' doesn't explain that the "constructs" are used in
> arguments to macro `rx'.
>
> E.g.: "some-string" is not an RX expression.
>       (rx "some-string") is an RX expression.
>
> Please make this clear.
>
> 2. `Rx Constructs': Don't show things like `\sCODE' without saying what
> CODE means.  If the column title for the table explaining RX names is
> `Syntax character' or `Category character' then that's apparently what
> CODE corresponds to for `\sCODE' or `\cCODE'.  But there's no way to
> know that unless you're already familiar with `\s' and `\c' syntax.
>
> 3. `Rx Constructs', `Zero-width assertions': Call this `Zero-width
> matching' or some such.
>
> 4. `Rx Functions': RX-EXPR is used as parameter name for what is, I
> guess an Rx construct (the language used in `Rx Construct').  Expression
> or construct?  Make it clear that RX-EXPR is an RX construct, if that's
> what it is.  And consider adding an xref to `Rx Construct'.
>
> 5. `Rx Functions': A couple places talk about `'regexp' forms', but
> those are specified nowhere, AFAICT.  The same places talk about
> 'literal' forms, which are specified, but which don't seem to work (?).
> (See bug #46909.)

Mattias, is this perhaps something you could take a look at?  I guess
it's about (info "(elisp) Rx Notation").




Reply sent to Mattias Engdegård <mattiase <at> acm.org>:
You have taken responsibility. (Sun, 26 Sep 2021 12:45:02 GMT) Full text and rfc822 format available.

Notification sent to Drew Adams <drew.adams <at> oracle.com>:
bug acknowledged by developer. (Sun, 26 Sep 2021 12:45:02 GMT) Full text and rfc822 format available.

Message #13 received at 46910-done <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 46910-done <at> debbugs.gnu.org, Drew Adams <drew.adams <at> oracle.com>
Subject: Re: bug#46910: 27.1; (elisp) RX doc
Date: Sun, 26 Sep 2021 14:44:42 +0200
25 sep. 2021 kl. 17.25 skrev Stefan Kangas <stefan <at> marxist.se>:
> 
> Drew Adams <drew.adams <at> oracle.com> writes:
> 
>> 1. `Rx Constructs' doesn't explain that the "constructs" are used in
>> arguments to macro `rx'.

Yes, I've added an explanation.

>> 2. `Rx Constructs': Don't show things like `\sCODE' without saying what
>> CODE means.  If the column title for the table explaining RX names is
>> `Syntax character' or `Category character' then that's apparently what
>> CODE corresponds to for `\sCODE' or `\cCODE'.  But there's no way to
>> know that unless you're already familiar with `\s' and `\c' syntax.

That's a valid point; now elaborated.

If anything I'd like to move the tables of syntax and (especially) category names to a separate page since they are rarely consulted and take up a lot of space. Not sure how to best do that.

>> 3. `Rx Constructs', `Zero-width assertions': Call this `Zero-width
>> matching' or some such.

Thank you, but it's established terminology and immediately explained in the first sentence.

>> 4. `Rx Functions': RX-EXPR is used as parameter name for what is, I
>> guess an Rx construct

That was a clear mistake, now fixed -- thanks.

>> 5. `Rx Functions': A couple places talk about `'regexp' forms', but
>> those are specified nowhere

The `regexp` and `literal` forms are both documented on the previous page.

For good measure, I also added some examples to illustrate the difference between `rx` and `rx-to-string`.





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 25 Oct 2021 11:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 155 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.