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

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

bug#37036: [PATCH] Inconsistent ASCII and Latin char categories


From: Mattias Engdegård
Subject: 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@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.






reply via email to

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