GNU bug report logs - #37036
[PATCH] Inconsistent ASCII and Latin char categories

Previous Next

Package: emacs;

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

Date: Thu, 15 Aug 2019 12:18:02 UTC

Severity: normal

Tags: patch, wontfix

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

Bug is archived. No further changes may be made.

Full log


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

From: Mattias Engdegård <mattiase <at> acm.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 37036 <at> debbugs.gnu.org
Subject: Re: bug#37036: [PATCH] Inconsistent ASCII and Latin char categories
Date: Thu, 15 Aug 2019 19:37:49 +0200
15 aug. 2019 kl. 18.59 skrev Eli Zaretskii <eliz <at> gnu.org>:
> 
> What about "abcdef^A^B"?  Does M-f stop before the control characters?

Yes. Does forward-word use categories?

> I guess I don't understand the rationale for the change.  Categories
> are Emacs's invention, and their purpose is mostly to allow us to use
> regexps for searching certain characters, and other similar
> subtleties.  Your rationale seems to be some attempt to be formally
> "consistent".  But this is not a formal attribute, it is entirely
> ad-hoc, as can be easily seen by just looking at the list of the
> categories.

The more categories are arbitrary, the less useful they are. Why would anyone use categories to discriminate characters if they do not have a sensible, useful and predictable structure? If 'Latin' means 'Latin letters, some symbols, some whitespace, some control chars, Indo-Arabic digits and the occasional Greek letter', which it does today, then who can use it correctly?

Consider the function fill-polish-nobreak-p. It is clearly written with the assumption of a reasonable definition of the Latin category, and it doesn't work as expected because of that. Those who reviewed that function thought it looked reasonable, as did I when I read it.

It is perfectly clear that categories have been introduced in an ad-hoc way to solve problems as they arose, but that doesn't mean that no mistakes were made even for those narrow purposes.





This bug report was last modified 5 years and 275 days ago.

Previous Next


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