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

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

bug#51089: 28.0.60; Using read-symbol-shorthands (("-" . "foo-")) should


From: Eli Zaretskii
Subject: bug#51089: 28.0.60; Using read-symbol-shorthands (("-" . "foo-")) shouldn't shadow the '-' symbol
Date: Sat, 09 Oct 2021 14:52:52 +0300

> From: João Távora <joaotavora@gmail.com>
> Cc: 51089@debbugs.gnu.org,  rms@gnu.org
> Date: Sat, 09 Oct 2021 12:21:36 +0100
> 
> > Actually, do we care about non-ASCII characters in this context?
> > Because if we only care about ASCII punctuation, it would be easier to
> > provide an explicit string made of such characters and see if the
> > character to test is in the string.  WDYT?
> 
> You mean iterate the string being analysed by bytes, and use strchr() on
> byte_i and a constant you'll provide me?  And if we reach a byte that's
> part of a multibyte one, we bail, knowing that it's not all ASCII
> punctuation...  Is that the idea?  Should work, yes.

Yes.  But I think we could use strcspn for an easier, one-line, test
of the same.





reply via email to

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