[PATCH] Use regexp types in defcustom where appropriate

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[PATCH] Use regexp types in defcustom where appropriate

Mattias Engdegård-2
This clean-up patch uses the type 'regexp' instead of 'string' in defcustom forms where the value actually is a regexp. Instances were found by means of an ad-hoc script.

Using the 'regexp' type gives better error checking (syntax errors are caught by the customisation machinery). It also allows for extending the system to use alternative regexp syntaxes, like rx, in the future.

Eli, is this acceptable for master now or should it wait until after the branch has been made?


0001-Use-regexp-type-for-regexps-in-defcustom-declaration.patch (45K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH] Use regexp types in defcustom where appropriate

Paul Eggert
On 12/21/19 10:44 AM, Mattias Engdegård wrote:
> This clean-up patch uses the type 'regexp' instead of 'string' in defcustom forms where the value actually is a regexp. Instances were found by means of an ad-hoc script.

Thanks for doing that. The changes look good to me, and I hope Eli likes them too.

Did you miss some instances in rcirc-coding-system-alist?

Reply | Threaded
Open this post in threaded view
|

Re: [PATCH] Use regexp types in defcustom where appropriate

Eli Zaretskii
In reply to this post by Mattias Engdegård-2
> From: Mattias Engdegård <[hidden email]>
> Date: Sat, 21 Dec 2019 19:44:38 +0100
>
> Eli, is this acceptable for master now or should it wait until after the branch has been made?

Please wait, and thanks for working on this.

Reply | Threaded
Open this post in threaded view
|

Re: [PATCH] Use regexp types in defcustom where appropriate

Mattias Engdegård-2
In reply to this post by Paul Eggert
21 dec. 2019 kl. 20.21 skrev Paul Eggert <[hidden email]>:

> Did you miss some instances in rcirc-coding-system-alist?

So I did! Updating my script revealed no further positives, however.
Thanks for the quick review; patch updated.





0001-Use-regexp-type-for-regexps-in-defcustom-declaration.patch (46K) Download Attachment