unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Advice function needs argument not used in function, how to avoid compiler warning?
@ 2022-10-05 21:20 Jean Louis
  2022-10-05 22:30 ` Michael Heerdegen
  2022-10-05 23:46 ` Emanuel Berg
  0 siblings, 2 replies; 3+ messages in thread
From: Jean Louis @ 2022-10-05 21:20 UTC (permalink / raw)
  To: Help GNU Emacs

I realize that advice function need argument such as &rest args, but I
am not using it in the function. And I do not understand what is that
argument receiving. Anybody may explain it?

I have to do (ignore args) to avoid compiler warning. What does args receive?

(defun hyperscope-after-sort (&rest args)
  (ignore args)
  (hyperscope-highlight))

(advice-add 'tabulated-list-col-sort :after 'hyperscope-after-sort)
(advice-add 'tabulated-list-sort :after 'hyperscope-after-sort)


--
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

In support of Richard M. Stallman
https://stallmansupport.org/



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

end of thread, other threads:[~2022-10-05 23:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-05 21:20 Advice function needs argument not used in function, how to avoid compiler warning? Jean Louis
2022-10-05 22:30 ` Michael Heerdegen
2022-10-05 23:46 ` Emanuel Berg

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).