* Re: [Emacs-diffs] emacs-25 d7a93ef: Minor improvements to 'pcase' documentation
[not found] ` <E1aP5Zi-00006V-7V@vcs.savannah.gnu.org>
@ 2016-01-29 14:14 ` Stefan Monnier
2016-01-29 15:38 ` Eli Zaretskii
0 siblings, 1 reply; 2+ messages in thread
From: Stefan Monnier @ 2016-01-29 14:14 UTC (permalink / raw)
To: emacs-devel; +Cc: Eli Zaretskii
> +@c FIXME: There should be an example here showing how a 'pcase' that
> +@c uses QPatterns can be rewritten using UPatterns.
For example:
`(k . ,v)
macro-expands (via (funcall (get '\` 'pcase-macroexpander) '(k . ,v))) to:
(funcall (get '\` 'pcase-macroexpander) '(k . ,v))
=>
(and (pred consp) (app car `k) (app cdr `,v))
=>
(and (pred consp) (app car 'k) (app cdr v))
-- Stefan
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Emacs-diffs] emacs-25 d7a93ef: Minor improvements to 'pcase' documentation
2016-01-29 14:14 ` [Emacs-diffs] emacs-25 d7a93ef: Minor improvements to 'pcase' documentation Stefan Monnier
@ 2016-01-29 15:38 ` Eli Zaretskii
0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2016-01-29 15:38 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: Eli Zaretskii <eliz@gnu.org>
> Date: Fri, 29 Jan 2016 09:14:11 -0500
>
> > +@c FIXME: There should be an example here showing how a 'pcase' that
> > +@c uses QPatterns can be rewritten using UPatterns.
>
> For example:
>
> `(k . ,v)
>
> macro-expands (via (funcall (get '\` 'pcase-macroexpander) '(k . ,v))) to:
>
> (funcall (get '\` 'pcase-macroexpander) '(k . ,v))
> =>
> (and (pred consp) (app car `k) (app cdr `,v))
> =>
> (and (pred consp) (app car 'k) (app cdr v))
Thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-01-29 15:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20160129094242.352.60019@vcs.savannah.gnu.org>
[not found] ` <E1aP5Zi-00006V-7V@vcs.savannah.gnu.org>
2016-01-29 14:14 ` [Emacs-diffs] emacs-25 d7a93ef: Minor improvements to 'pcase' documentation Stefan Monnier
2016-01-29 15:38 ` Eli Zaretskii
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).