unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Ryan Hodges <rphodges@gmail.com>, Richard Stallman <rms@gnu.org>
Cc: 67185@debbugs.gnu.org
Subject: bug#67185: Small bug in the Introduction to Elisp manual
Date: Wed, 15 Nov 2023 14:18:06 +0200	[thread overview]
Message-ID: <83edgrrz0h.fsf@gnu.org> (raw)
In-Reply-To: <CABPno9KBn67Pd5vc3j5pYSanUsysZF-C8nV1o463EUmrvkpBww@mail.gmail.com> (message from Ryan Hodges on Tue, 14 Nov 2023 15:14:53 -0800)

> From: Ryan Hodges <rphodges@gmail.com>
> Date: Tue, 14 Nov 2023 15:14:53 -0800
> 
> In section '8.2.2 Lisp macro' it says, 
> 
>  "The ‘kill-region’ function definition also has an ‘unless’ macro; it
>  is the converse of ‘when’.  The ‘unless’ macro is an ‘if’ without a then clause"
> 
> Instead of saying "converse of 'when'" it should say "inverse of
> 'when'."

I'm not a native English speaker, but "converse" sounds correct to me
in this context.

> Also, that statement about
> 'unless' being an 'if' without a 'then' clause tripped me up. I thought you were trying to say that the
> 'unless' form didn't have a then clause, which isn't correct.  Then I thought the point you were really
> trying to make was that the unless form, like when, doesn't have an 'else' clause.    

No, it says it doesn't have "then", i.e. it only have the "else" part.
Which sounds fine to me.

> Now that I've read the corresponding section in the reference manual I know what you mean.   I think
> we should borrow the examples from the reference manual  to make it clear and also emphasize that
> 'unless' is a convenient mechanism for evaluating multiple statements when a condition is not true.
>  
> Maybe the text should be:
> 
>  "The kill-region function definition also has an 'unless' macro. It is the inverse of 'when'. The
>  form, 
> 
>  (unless CONDITION A B C)
> 
>  is equivalent to the form
> 
>  (when (not (CONDITION)) A B C)
> 
>  The 'unless' form is ideal in situations when multiple expressions should be evaluated when a
>  condition is not true. The 'unless' macro can also be viewed as an 'if' which does nothing in the
>  'then' clause but evaluates one or more statements in the 'else' clause.  In particular,
> 
>  (unless CONDITION A B C)
> 
>  is equivalent to the form,
> 
>  (if CONDITION nil A B C)
> 
>  In other words, if CONDITION is true, the form does nothing.  Otherwise, when CONDITION is
>  false, the form evaluates 'A B C'.
> 
> If you approve of the text or provide me more accurate phrasing, I'll gladly submit a patch.  I also
> understand if you think I'm being a little too verbose.  

This manual was written by a person whose command of the English
language and whose methodological skill are exceptional.  So I'm
adding Richard to this discussion, and ask him to judge this text,
and whether it needs to be improved and how.

Thanks.





  reply	other threads:[~2023-11-15 12:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-14 23:14 bug#67185: Small bug in the Introduction to Elisp manual Ryan Hodges
2023-11-15 12:18 ` Eli Zaretskii [this message]
     [not found]   ` <CABPno9+==Vp-x851SLp6m7E8-e2kr7DAxkzaYC2HF7VjAk2QjQ@mail.gmail.com>
2023-11-15 19:32     ` Eli Zaretskii
2023-11-15 20:18       ` Ryan Hodges
2023-11-17  3:56         ` Richard Stallman
2023-11-17  7:19           ` Eli Zaretskii
2023-11-17 13:22             ` Ryan Hodges
2023-11-19  3:40             ` Richard Stallman
2023-11-19 10:16               ` Eli Zaretskii
2023-11-19 19:01                 ` Ryan Hodges
2023-11-21  2:42                   ` 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

  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=83edgrrz0h.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=67185@debbugs.gnu.org \
    --cc=rms@gnu.org \
    --cc=rphodges@gmail.com \
    /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).