GNU bug report logs - #32276
char-width of a space is 0 when display-table entry has a face.

Previous Next

Package: emacs;

Reported by: Keith David Bershatsky <esq <at> lawlist.com>

Date: Thu, 26 Jul 2018 03:35:02 UTC

Severity: normal

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: Eli Zaretskii <eliz <at> gnu.org>
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: esq <at> lawlist.com, 32276 <at> debbugs.gnu.org
Subject: bug#32276: char-width of a space is 0 when display-table entry has a face.
Date: Sun, 29 Jul 2018 17:45:14 +0300
> Cc: 32276 <at> debbugs.gnu.org, Keith David Bershatsky <esq <at> lawlist.com>
> From: Paul Eggert <eggert <at> cs.ucla.edu>
> Date: Sat, 28 Jul 2018 15:37:50 -0700
> 
> Unfortunately that change causes the emacs-26 build to fail for me:

Sorry about that.

> make[1]: Entering directory '/home/eggert/src/gnu/emacs/emacs-26-sc/src'
>    CC       character.o
> In file included from character.c:34:0:
> character.c: In function ‘char_width’:
> lisp.h:1682:11: error: ‘c’ may be used uninitialized in this function 
> [-Werror=maybe-uninitialized]
>      ? ((a) + (unsigned) 0) op ((b) + (unsigned) 0)   \
>             ^
> character.c:292:10: note: ‘c’ was declared here
>        int c;
>            ^
> cc1: all warnings being treated as errors
> Makefile:376: recipe for target 'character.o' failed
> 
> Although the attached patch fixes this and presumably speeds up the code a bit 
> when optimized, is this the right thing to do? I have not looked into the code 
> carefully.

I preferred to keep the modified code work the same as before that
change, i.e. count any non-characters (which now shouldn't happen, I
think) as having a width of zero.  So I pushed a slightly different
fix.




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

Previous Next


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