unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Juanma Barranquero <lekktu@gmail.com>
Cc: Emacs Devel <emacs-devel@gnu.org>
Subject: Re: sit-for arg old-nodisp not documented
Date: Sun, 31 Jul 2005 17:11:30 +0200	[thread overview]
Message-ID: <f7ccd24b050731081132ecfb85@mail.gmail.com> (raw)
In-Reply-To: <42EC8331.3050702@student.lu.se>

> `sit-for' has an argument old-nodisp that is not described in the doc
> string.

Not exactly. If you read it again carefully, you'll notice `sit-for'
has two modes of invocation:

  - (modern):  (sit-for SECONDS &optional NODISP)
  - (old): (sit-for SECONDS &optional MILLISECONDS NODISP)

So the function is really defined as

  (sit-for SECONDS &optional NODISP OLD-NODISP)

which is accurate, but does not help argument highlighting
(MILLISECONDS is not highlighted) and does not match the description
(which uses NODISP for the OLD-NODISP argument).

The "correct" thing to do would be to define the function (or at
least, the docstring) as

  (sit-for SECONDS &optional NODISP-OR-MILLISECONDS IGNORED-OR-NODISP)

but that would be ugly.

After the 22.1 release I'll take a deep look at the many docstrings
that still have irregularities which are not easy to resolve. I don't
want to be forced to add "\(fn ...)" sections to more docstrings
(there are already too many, I'd like to remove some), and also don't
want to start changing argument names because of dynamic binding
issues (sometimes is difficult to see whether an argument is used as a
local binding in another function higher in the call stack).

-- 
                    /L/e/k/t/u

  reply	other threads:[~2005-07-31 15:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-31  7:52 sit-for arg old-nodisp not documented Lennart Borgman
2005-07-31 15:11 ` Juanma Barranquero [this message]
2005-07-31 15:37   ` Lennart Borgman
2005-07-31 16:02     ` Juanma Barranquero
2005-07-31 16:12       ` Lennart Borgman
2005-07-31 20:17         ` Juanma Barranquero
2005-07-31 21:12           ` Lennart Borgman
2005-08-01  0:46 ` Richard M. Stallman

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=f7ccd24b050731081132ecfb85@mail.gmail.com \
    --to=lekktu@gmail.com \
    --cc=emacs-devel@gnu.org \
    /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).