emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] fix/bug-31311-pcase-doc 684d82c 4/9: rewrite ‘defmac pcas


From: Thien-Thi Nguyen
Subject: [Emacs-diffs] fix/bug-31311-pcase-doc 684d82c 4/9: rewrite ‘defmac pcase-defmacro’ first para
Date: Sun, 20 May 2018 14:39:28 -0400 (EDT)

branch: fix/bug-31311-pcase-doc
commit 684d82c6e0955ae2526fcda6b7d55b76d99cdd9c
Author: Thien-Thi Nguyen <address@hidden>
Commit: Thien-Thi Nguyen <address@hidden>

    rewrite ‘defmac pcase-defmacro’ first para
    
    - drop pre-block grousing comment
    - elide "will be invoked"
    - use "‘pcase’ expands" and "function call"
    - use "whose job it is" (iffy)
---
 doc/lispref/control.texi | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/doc/lispref/control.texi b/doc/lispref/control.texi
index 4ae9ad0..6444338 100644
--- a/doc/lispref/control.texi
+++ b/doc/lispref/control.texi
@@ -855,13 +855,12 @@ This subsection describes @code{pcase-defmacro} and
 that eases structural matching.  (These patterns were
 defined with @code{pcase-defmacro}.)
 
address@hidden Hmm, shouldn't this be named ‘pcase-defpattern’?
address@hidden I suppose it's too late now....  --ttn
 @defmac pcase-defmacro name args [doc] &rest body
-Define a new kind of pattern for @code{pcase}.  The new pattern will
-be invoked as @code{(@var{name} @var{actual-args})}.  The @var{body}
-should describe how to rewrite the pattern @var{name} into some other
-pattern.  The rewriting will be the result of evaluating @var{body}
+Define a new kind of pattern for @code{pcase}, to be invoked
+as @address@hidden(@var{name} @var{actual-args})}}.
+The @code{pcase} macro expands this into a function call
+that evaluates @var{body}, whose job it is to
+rewrite the invoked pattern into some other pattern,
 in an environment where @var{args} are bound to @var{actual-args}.
 
 Additionally, arrange to display @var{doc} along with



reply via email to

[Prev in Thread] Current Thread [Next in Thread]