unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#65064: Macro definition using C-h f
@ 2023-08-05  6:42 Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-08-05  7:15 ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-08-05  6:42 UTC (permalink / raw)
  To: 65064

Have done the following macro, but calling `C-h f tak` shows the definition
as 

(tak &rest ARGS)

rather than

(tak &rest _ARGS)

(defmacro tak (&rest _args)
  "Performs no action, no matter how many arguments are passed."

  nil)





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

* bug#65064: Macro definition using C-h f
  2023-08-05  6:42 bug#65064: Macro definition using C-h f Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-08-05  7:15 ` Eli Zaretskii
  2023-08-05  7:39   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-09-02 16:44   ` Stefan Kangas
  0 siblings, 2 replies; 5+ messages in thread
From: Eli Zaretskii @ 2023-08-05  7:15 UTC (permalink / raw)
  To: Heime, Stefan Monnier; +Cc: 65064

tags 65064 notabug
thanks

> Date: Sat, 05 Aug 2023 06:42:57 +0000
> From:  Heime via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> 
> Have done the following macro, but calling `C-h f tak` shows the definition
> as 
> 
> (tak &rest ARGS)
> 
> rather than
> 
> (tak &rest _ARGS)
> 
> (defmacro tak (&rest _args)
>   "Performs no action, no matter how many arguments are passed."
> 
>   nil)

This is a feature: the leading '_' is an indication that the argument
is unused, but the argument's name is 'args', without the underscore.

This is not a bug.





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

* bug#65064: Macro definition using C-h f
  2023-08-05  7:15 ` Eli Zaretskii
@ 2023-08-05  7:39   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-08-09 12:53     ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-09-02 16:44   ` Stefan Kangas
  1 sibling, 1 reply; 5+ messages in thread
From: Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-08-05  7:39 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 65064, Stefan Monnier


------- Original Message -------
On Saturday, August 5th, 2023 at 7:15 PM, Eli Zaretskii <eliz@gnu.org> wrote:


> tags 65064 notabug
> thanks
> 
> > Date: Sat, 05 Aug 2023 06:42:57 +0000
> > From: Heime via "Bug reports for GNU Emacs,
> > the Swiss army knife of text editors" bug-gnu-emacs@gnu.org
> > 
> > Have done the following macro, but calling `C-h f tak` shows the definition
> > as
> > 
> > (tak &rest ARGS)
> > 
> > rather than
> > 
> > (tak &rest _ARGS)
> > 
> > (defmacro tak (&rest _args)
> > "Performs no action, no matter how many arguments are passed."
> > 
> > nil)
> 
> 
> This is a feature: the leading '_' is an indication that the argument
> is unused, but the argument's name is 'args', without the underscore.
> 
> This is not a bug.

Don't you need to show users that the argument is unused?






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

* bug#65064: Macro definition using C-h f
  2023-08-05  7:39   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-08-09 12:53     ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 0 replies; 5+ messages in thread
From: Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-08-09 12:53 UTC (permalink / raw)
  To: Heime; +Cc: 65064, Eli Zaretskii

> Don't you need to show users that the argument is unused?

We could add that as a new feature, but usually the docstring says it
instead, so it would often be redundant.


        Stefan






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

* bug#65064: Macro definition using C-h f
  2023-08-05  7:15 ` Eli Zaretskii
  2023-08-05  7:39   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-09-02 16:44   ` Stefan Kangas
  1 sibling, 0 replies; 5+ messages in thread
From: Stefan Kangas @ 2023-09-02 16:44 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 65064-done, Heime, Stefan Monnier

Eli Zaretskii <eliz@gnu.org> writes:

> tags 65064 notabug
> thanks
>
>> Date: Sat, 05 Aug 2023 06:42:57 +0000
>> From:  Heime via "Bug reports for GNU Emacs,
>>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>>
>> Have done the following macro, but calling `C-h f tak` shows the definition
>> as
>>
>> (tak &rest ARGS)
>>
>> rather than
>>
>> (tak &rest _ARGS)
>>
>> (defmacro tak (&rest _args)
>>   "Performs no action, no matter how many arguments are passed."
>>
>>   nil)
>
> This is a feature: the leading '_' is an indication that the argument
> is unused, but the argument's name is 'args', without the underscore.
>
> This is not a bug.

I'm therefore closing this bug report.





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

end of thread, other threads:[~2023-09-02 16:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-05  6:42 bug#65064: Macro definition using C-h f Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-05  7:15 ` Eli Zaretskii
2023-08-05  7:39   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-08-09 12:53     ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-09-02 16:44   ` Stefan Kangas

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