GNU bug report logs - #73307
Fix ctype(3) usage

Previous Next

Package: emacs;

Reported by: Thomas Klausner <wiz <at> gatalith.at>

Date: Mon, 16 Sep 2024 21:26:01 UTC

Severity: normal

Tags: patch

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


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

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: luangruo <at> yahoo.com, 73307 <at> debbugs.gnu.org, Paul Eggert <eggert <at> cs.ucla.edu>,
 wiz <at> gatalith.at
Subject: Re: bug#73307: Fix ctype(3) usage
Date: Wed, 18 Sep 2024 11:18:21 -0400
> You are testing characters for whitespace syntax, which is AFAIU
> subject to buffer-local syntax tables.  Thus, a strange enough setting
> of buffer syntax could make this code return unexpected results.
>
> Stefan, am I right?

Yup.

> Why can't we use something closer to the original code, which doesn't
> depend on buffer-local customizations?

We could use the global/default syntax table?
[ Or rely on some of the unicode tables?  ]


        Stefan





This bug report was last modified 297 days ago.

Previous Next


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