all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: chad <yandros@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: "Bruno Félix Rezende Ribeiro" <oitofelix@gnu.org>,
	emacs-devel <emacs-devel@gnu.org>
Subject: Re: Technically correct or conceptually easier?
Date: Fri, 3 Apr 2020 19:09:11 -0700	[thread overview]
Message-ID: <CAO2hHWbdKMudFzc4kwYSVNMymCpSPHxO1bh=3nC4AXaNuMhOpg@mail.gmail.com> (raw)
In-Reply-To: <jwvv9mhlh8x.fsf-monnier+emacs@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 1348 bytes --]

As a practical matter, could this specific instance be addressed by
something like "...if the value is a (non-nil) list, ...."?

On Thu, Apr 2, 2020 at 2:22 PM Stefan Monnier <monnier@iro.umontreal.ca>
wrote:

> > The first sentence of the documentation says:
> >
> >   Non-nil means disregard read-only status of buffers or characters.
> >
> > OK.  And what nil means?  I guess the omission of its meaning implies
> > its meaning is the exact opposite of the one given to a non-nil value;
> > and apparently this conjecture can be factually verified by
> > experimentation.
>
> Yes, we often rely on the abuse of "if" to mean "if and only if".
> Usually those abuses allow for less verbose text, so there's
> a trade-off.  I think here the trade-off is worthwhile.  At some other
> places we correctly add an explicit mention of what happens if it's nil.
> And of course at yet other places we made the wrong call :-(
>
> >   If the value is a list, disregard ‘buffer-read-only’ and disregard a
> >   ‘read-only’ text property if the property value is a member of the
> >   list.
> >
> > Well, nil is a list.
>
> I think this case is a documentation error: it should say "a non-empty
> list", although admittedly, the context makes it clearish what is meant.
>
>
>         Stefan "who likes `iff`"
>
>
>

[-- Attachment #2: Type: text/html, Size: 1799 bytes --]

  reply	other threads:[~2020-04-04  2:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-02 20:23 Technically correct or conceptually easier? Bruno Félix Rezende Ribeiro
2020-04-02 21:22 ` Stefan Monnier
2020-04-04  2:09   ` chad [this message]
2020-04-10 14:00   ` Bruno Félix Rezende Ribeiro
2020-04-04  1:24 ` Richard 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

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

  git send-email \
    --in-reply-to='CAO2hHWbdKMudFzc4kwYSVNMymCpSPHxO1bh=3nC4AXaNuMhOpg@mail.gmail.com' \
    --to=yandros@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=oitofelix@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.