all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Juanma Barranquero <lekktu@gmail.com>
To: Drew Adams <drew.adams@oracle.com>
Cc: emacs-devel@gnu.org
Subject: Re: delete-windows-on
Date: Fri, 2 Oct 2009 18:30:44 +0200	[thread overview]
Message-ID: <f7ccd24b0910020930t5c2baaeai5d80a4396bc0f9df@mail.gmail.com> (raw)
In-Reply-To: <A2F6D0D459974541AE70D009D55CA66C@us.oracle.com>

On Fri, Oct 2, 2009 at 18:16, Drew Adams <drew.adams@oracle.com> wrote:

> 3. It raises an error if you pass the name of a non-existent buffer, or if you
> pass anything that is not a string or a buffer (except nil - see #2). Why? Why
> doesn't it just do nothing if the BUFFER arg is not an existing buffer or its
> name?
>
> A nil value of BUFFER means there is no such buffer. The same is true of a
> string that doesn't name an existing buffer. The same is true of a non-string
> such as the number 42. In one case (#2), we currently do nothing and return nil;
> in all other cases (#3), we currently raise an error. That's not very
> consistent.

I think it is quite consistent. Passing "whatever" (when "whatever"
exists) is a clear way to say 'act upon "whatever"'. Passing nil (or
omitting the 1st arg) clearly says "act upon the default buffer".
IMHO, passing 42 or "nonexistent-buffer-name" clearly means "Oops,
someone or something just fucked up".

    Juanma




  reply	other threads:[~2009-10-02 16:30 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-02 16:16 delete-windows-on Drew Adams
2009-10-02 16:30 ` Juanma Barranquero [this message]
2009-10-02 16:47   ` delete-windows-on Drew Adams
2009-10-02 16:51     ` delete-windows-on Juanma Barranquero
2009-10-02 17:25       ` delete-windows-on martin rudalics
2009-10-02 17:55         ` delete-windows-on Drew Adams
2009-10-02 20:31           ` delete-windows-on Drew Adams
2009-10-03  5:52             ` delete-windows-on Stephen J. Turnbull
2009-10-02 17:37       ` delete-windows-on Drew Adams
2009-10-02 18:27         ` delete-windows-on Stephen J. Turnbull
2009-10-02 17:25 ` delete-windows-on martin rudalics
2009-10-02 17:39   ` delete-windows-on Drew Adams

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f7ccd24b0910020930t5c2baaeai5d80a4396bc0f9df@mail.gmail.com \
    --to=lekktu@gmail.com \
    --cc=drew.adams@oracle.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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.