From b3314ac5c43414a5de518794d002aa3801ed809f Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 10 Oct 2019 06:00:20 +0200 Subject: [PATCH] identity, ignore: Make arg names more consistent with docs * lisp/subr.el (ignore): Rename argument IGNORE to ARGUMENTS. * src/fns.c (Fidentity): Rename ARG to ARGUMENT. * doc/lispref/functions.texi (Calling Functions): Fix references. --- doc/lispref/functions.texi | 8 ++++---- lisp/subr.el | 4 ++-- src/fns.c | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/doc/lispref/functions.texi b/doc/lispref/functions.texi index d082225dd00..eced3a24474 100644 --- a/doc/lispref/functions.texi +++ b/doc/lispref/functions.texi @@ -929,12 +929,12 @@ that accept function arguments are often called @dfn{functionals}. function as the argument. Here are two different kinds of no-op function: -@defun identity arg -This function returns @var{arg} and has no side effects. +@defun identity argument +This function returns @var{argument} and has no side effects. @end defun -@defun ignore &rest args -This function ignores any arguments and returns @code{nil}. +@defun ignore &rest arguments +This function ignores any @var{arguments} and returns @code{nil}. @end defun Some functions are user-visible @dfn{commands}, which can be called diff --git a/lisp/subr.el b/lisp/subr.el index e361b8324f7..010443a56b5 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -332,9 +332,9 @@ PREFIX is a string, and defaults to \"g\"." (setq gensym-counter (1+ gensym-counter))))) (make-symbol (format "%s%d" (or prefix "g") num)))) -(defun ignore (&rest _ignore) +(defun ignore (&rest _arguments) "Do nothing and return nil. -This function accepts any number of arguments, but ignores them." +This function accepts any number of ARGUMENTS, but ignores them." (interactive) nil) diff --git a/src/fns.c b/src/fns.c index 37c581f15b8..fc1abe8b18a 100644 --- a/src/fns.c +++ b/src/fns.c @@ -49,11 +49,11 @@ static bool internal_equal (Lisp_Object, Lisp_Object, enum equal_kind, int, Lisp_Object); DEFUN ("identity", Fidentity, Sidentity, 1, 1, 0, - doc: /* Return the argument unchanged. */ + doc: /* Return the ARGUMENT unchanged. */ attributes: const) - (Lisp_Object arg) + (Lisp_Object argument) { - return arg; + return argument; } DEFUN ("random", Frandom, Srandom, 0, 1, 0, -- 2.39.5