From: Stefan Kangas <stefankangas@gmail.com>
To: Pip Cet <pipcet@protonmail.com>, emacs-devel@gnu.org
Subject: Re: scratch/no-purespace 976196cba66 07/13: Pure storage removal: Replace calls to removed functions
Date: Wed, 21 Aug 2024 20:03:55 +0000 [thread overview]
Message-ID: <CADwFkm=sOKHLSaAQ=SNhDjtP9nBKLe8MA-Ma3wvGRd2aSBF6Ng@mail.gmail.com> (raw)
In-Reply-To: <20240820194248.35A31C1CAF2@vcs2.savannah.gnu.org>
Pip Cet via Mailing list for Emacs changes <emacs-diffs@gnu.org> writes:
> branch: scratch/no-purespace
> commit 976196cba66992bcc0aa581403f2d215136547d6
> Author: Pip Cet <pipcet@protonmail.com>
> Commit: Pip Cet <pipcet@protonmail.com>
>
> Pure storage removal: Replace calls to removed functions
With clang, I get this warning now:
alloc.c:6706:13: warning: variable 'po' set but not used
[-Wunused-but-set-variable]
void *po = XPNTR (obj);
The below seems to fix it, but maybe there's a cleaner fix:
diff --git a/src/alloc.c b/src/alloc.c
index 974fb14115f..ae40a7f6686 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -6703,7 +6703,9 @@ process_mark_stack (ptrdiff_t base_sp)
{
Lisp_Object obj = mark_stack_pop ();
mark_obj: ;
+#if GC_CHECK_MARKED_OBJECTS
void *po = XPNTR (obj);
+#endif
#if GC_REMEMBER_LAST_MARKED
last_marked[last_marked_index++] = obj;
@@ -6950,7 +6952,11 @@ #define CHECK_ALLOCATED_AND_LIVE_SYMBOL() ((void) 0)
set_string_marked (XSTRING (ptr->u.s.name));
mark_interval_tree (string_intervals (ptr->u.s.name));
/* Inner loop to mark next symbol in this bucket, if any. */
+#if GC_CHECK_MARKED_OBJECTS
po = ptr = ptr->u.s.next;
+#else
+ ptr = ptr->u.s.next;
+#endif
if (ptr)
goto nextsym;
}
next parent reply other threads:[~2024-08-21 20:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <172418296207.12694.9697430583864173962@vcs2.savannah.gnu.org>
[not found] ` <20240820194248.35A31C1CAF2@vcs2.savannah.gnu.org>
2024-08-21 20:03 ` Stefan Kangas [this message]
2024-08-22 6:17 ` scratch/no-purespace 976196cba66 07/13: Pure storage removal: Replace calls to removed functions Pip Cet
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='CADwFkm=sOKHLSaAQ=SNhDjtP9nBKLe8MA-Ma3wvGRd2aSBF6Ng@mail.gmail.com' \
--to=stefankangas@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=pipcet@protonmail.com \
/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).