unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Compiler warning in xdisp.c
       [not found] <87h7c35hfs.fsf.ref@yahoo.com>
@ 2021-11-23  9:50 ` Po Lu
  2021-11-23 12:48   ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: Po Lu @ 2021-11-23  9:50 UTC (permalink / raw)
  To: emacs-devel

Compiling master, I get:

In file included from composite.h:29,
                 from xdisp.c:441:
xdisp.c: In function ‘produce_stretch_glyph’:
dispextern.h:1891:10: warning: ‘face’ may be used uninitialized in this function [-Wmaybe-uninitialized]
 1891 |   return face_for_char (f, face, character, pos, object);
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
xdisp.c:30063:16: note: ‘face’ was declared here
30063 |   struct face *face;
      |                ^~~~

I'm not comfortable enough with that code to fix it.  The problem may
also exist in Emacs 28.  Thanks.



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Compiler warning in xdisp.c
  2021-11-23  9:50 ` Compiler warning in xdisp.c Po Lu
@ 2021-11-23 12:48   ` Eli Zaretskii
  0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2021-11-23 12:48 UTC (permalink / raw)
  To: Po Lu; +Cc: emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Date: Tue, 23 Nov 2021 17:50:47 +0800
> 
> In file included from composite.h:29,
>                  from xdisp.c:441:
> xdisp.c: In function ‘produce_stretch_glyph’:
> dispextern.h:1891:10: warning: ‘face’ may be used uninitialized in this function [-Wmaybe-uninitialized]
>  1891 |   return face_for_char (f, face, character, pos, object);
>       |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> xdisp.c:30063:16: note: ‘face’ was declared here
> 30063 |   struct face *face;
>       |                ^~~~

A bogus warning, which should be fixed now (on the release branch;
soon on master).  Meanwhile, you can safely disregard it.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-11-23 12:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <87h7c35hfs.fsf.ref@yahoo.com>
2021-11-23  9:50 ` Compiler warning in xdisp.c Po Lu
2021-11-23 12:48   ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).