unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Basil L. Contovounesios" via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 61049@debbugs.gnu.org
Subject: bug#61049: 29.0.60; xfaces.c:font_maybe_unset_attribute unused in nox build
Date: Wed, 25 Jan 2023 01:15:06 +0000	[thread overview]
Message-ID: <87a627za79.fsf@tcd.ie> (raw)

[-- Attachment #1: Type: text/plain, Size: 348 bytes --]

Severity: minor
Tags: patch

Building emacs-29 --without-x emits the following warning:

xfaces.c:6021:1: warning: ‘font_maybe_unset_attribute’ defined but not used [-Wunused-function]
 6021 | font_maybe_unset_attribute (Lisp_Object font_object,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~

Okay to fix on emacs-29, or not important enough?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Pacify-without-x-unused-function-warning.patch --]
[-- Type: text/x-diff, Size: 1164 bytes --]

From befe5396b2b5aa7852ebb30988d1ed388c2d763a Mon Sep 17 00:00:00 2001
From: "Basil L. Contovounesios" <contovob@tcd.ie>
Date: Wed, 25 Jan 2023 01:02:30 +0000
Subject: [PATCH] Pacify --without-x unused function warning

* src/xfaces.c (font_maybe_unset_attribute): Move definition...
[HAVE_WINDOW_SYSTEM] (font_maybe_unset_attribute): ...to here, since
the function is used only when we HAVE_WINDOW_SYSTEM.
---
 src/xfaces.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/xfaces.c b/src/xfaces.c
index 68f7cc493cc..35b79154805 100644
--- a/src/xfaces.c
+++ b/src/xfaces.c
@@ -6012,7 +6012,6 @@ realize_non_ascii_face (struct frame *f, Lisp_Object font_object,
 
   return face;
 }
-#endif	/* HAVE_WINDOW_SYSTEM */
 
 /* Remove the attribute at INDEX from the font object if SYMBOL
    appears in `font-fallback-ignored-attributes'.  */
@@ -6031,6 +6030,7 @@ font_maybe_unset_attribute (Lisp_Object font_object,
 	ASET (font_object, index, Qnil);
     }
 }
+#endif /* HAVE_WINDOW_SYSTEM */
 
 /* Realize the fully-specified face with attributes ATTRS in face
    cache CACHE for ASCII characters.  Do it for GUI frame CACHE->f.
-- 
2.39.0


[-- Attachment #3: Type: text/plain, Size: 2858 bytes --]


Thanks,

-- 
Basil

$ gcc --version
gcc (Debian 12.2.0-14) 12.2.0
Copyright (C) 2022 Free Software Foundation, Inc.

In GNU Emacs 29.0.60 (build 1, x86_64-pc-linux-gnu) of 2023-01-25 built
 on tia
Repository revision: ecf500b5e34f3767df6b41f110efcf307c74ebc9
Repository branch: wt/emacs-29-nox
System Description: Debian GNU/Linux bookworm/sid

Configured using:
 'configure 'CFLAGS=-O2 -march=native' --prefix=/home/blc/.local
 --program-suffix=-29-nox --with-file-notification=yes
 --with-x-toolkit=no --without-x'

Configured features:
ACL DBUS GMP GNUTLS GPM JSON LCMS2 LIBSELINUX LIBSYSTEMD LIBXML2 MODULES
NOTIFY INOTIFY PDUMPER SECCOMP SOUND SQLITE3 THREADS TREE_SITTER XIM
ZLIB

Important settings:
  value of $LANG: en_IE.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
None found.

Features:
(shadow regexp-opt sort mail-extr emacsbug message mailcap yank-media
puny dired dnd dired-loaddefs rfc822 mml mml-sec password-cache epa
derived epg rfc6068 epg-config gnus-util text-property-search time-date
subr-x mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader cl-loaddefs cl-lib sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils term/xterm xterm byte-opt gv
bytecomp byte-compile rmc iso-transl tooltip cconv eldoc paren electric
uniquify ediff-hook vc-hooks lisp-float-type elisp-mode tabulated-list
replace newcomment text-mode lisp-mode prog-mode register page tab-bar
menu-bar rfn-eshadow isearch easymenu timer select mouse jit-lock
font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq
simple cl-generic indonesian philippine cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite emoji-zwj charscript charprop case-table
epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button
loaddefs theme-loaddefs faces cus-face macroexp files window
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget keymap hashtable-print-readable backquote threads dbusbind
inotify lcms2 multi-tty make-network-process emacs)

Memory information:
((conses 16 47477 6970)
 (symbols 48 5698 0)
 (strings 32 14970 1708)
 (string-bytes 1 435117)
 (vectors 16 8387)
 (vector-slots 8 104002 7945)
 (floats 8 24 40)
 (intervals 56 200 0)
 (buffers 984 10))

             reply	other threads:[~2023-01-25  1:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-25  1:15 Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2023-01-25 12:12 ` bug#61049: 29.0.60; xfaces.c:font_maybe_unset_attribute unused in nox build Eli Zaretskii
2023-01-25 14:33   ` Basil L. Contovounesios via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a627za79.fsf@tcd.ie \
    --to=bug-gnu-emacs@gnu.org \
    --cc=61049@debbugs.gnu.org \
    --cc=contovob@tcd.ie \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).