GNU bug report logs - #36167
[PATCH] Replace manually crafted hex regexes with [[:xdigit:]]

Previous Next

Package: emacs;

Reported by: Konstantin Kharlamov <hi-angel <at> yandex.ru>

Date: Tue, 11 Jun 2019 12:00:02 UTC

Severity: wishlist

Tags: patch

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Konstantin Kharlamov <hi-angel <at> yandex.ru>
To: Robert Pluim <rpluim <at> gmail.com>
Cc: 36167 <at> debbugs.gnu.org
Subject: bug#36167: [PATCH] Replace [0-9a-fA-F] with [[:xdigit:]]
Date: Tue, 11 Jun 2019 16:17:10 +0300

On Вт, июн 11, 2019 at 15:03, Robert Pluim <rpluim <at> gmail.com> 
wrote:
>>>>>>  On Tue, 11 Jun 2019 15:29:25 +0300, Konstantin Kharlamov 
>>>>>> <Hi-Angel <at> yandex.ru> said:
> 
> If this is fixing a bug, then please put '(Bug#36167)' somewhere in
> the commit message (I normally put it as the last thing in the
> preamble, before the detailed list of changes). See 'Commit messages'
> in CONTRIBUTE for extensive documentation.
> 
>     Konstantin> * etc/schema/od-schema-v1.2-os.rnc: replace
>     Konstantin> [0-9a-fA-F] with [[:xdigit:]]
> 
> This is the org schema file for OpenDocument export, not emacs
> lisp. Does that support :xdigit: syntax?

Oh, okay, thanks, I couldn't figure out what it is because Wikipedia 
says that .rnc is just a variation of XML, and README just says it's 
something to map some xml schemas to documents. So I deemed these 
regexps are too used by ELisp.

Can I test it somehow? Either way, not a big deal, I can just drop that 
one.

>     Konstantin> * lisp/calc/calc-aent.el: replace [0-9a-fA-F] with
>     Konstantin> [[:xdigit:]]
> 
> Normally, you'd mention the containing function in the ChangeLog
> entry. Using 'C-x 4 a' (ie 'add-change-log-entry-other-window') with
> point on the code youʼre changing does that for you.

Ah, thanks. At this point I'll probably ask on emacs-devel about adding 
to prepare-commit-msg a code to pre-format the changes, because clearly 
that's a lot of manual work for something that should be automated.

>     Konstantin> * lisp/calc/calc-ext.el: replace [0-9a-fA-F] with
>     Konstantin> [[:xdigit:]]
> 
> And then on subsequent similar changes you can say 'Likewise.' (whilst
> still mentioning the enclosing function)
> 
>     Konstantin> * lisp/calc/calc-lang.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/cedet/semantic/java.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/cedet/semantic/lex.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/emulation/cua-rect.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/gnus/gnus-art.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/gnus/mml-sec.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/gnus/nneething.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/international/mule-cmds.el: replace 
> [0-9a-fA-F] with [[:xdigit:]]
>     Konstantin> * lisp/net/shr-color.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/nxml/rng-cmpct.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/nxml/rng-uri.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/nxml/rng-xsd.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/nxml/xmltok.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/org/org-mobile.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/progmodes/ada-mode.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/progmodes/cc-mode.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/progmodes/cperl-mode.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/progmodes/ebnf-dtd.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/progmodes/hideif.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/progmodes/prolog.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/textmodes/css-mode.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/textmodes/sgml-mode.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
>     Konstantin> * lisp/version.el: replace [0-9a-fA-F] with 
> [[:xdigit:]]
>     Konstantin> * lisp/xml.el: replace [0-9a-fA-F] with [[:xdigit:]]
>     Konstantin> * test/src/emacs-module-tests.el: replace [0-9a-fA-F] 
> with [[:xdigit:]]
> 
> Robert






This bug report was last modified 6 years and 7 days ago.

Previous Next


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