all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: 31350@debbugs.gnu.org
Subject: bug#31350: 27.0; `pcase' message: "Redundant pcase pattern"
Date: Thu, 3 May 2018 11:18:45 -0700 (PDT)	[thread overview]
Message-ID: <c21ac6a1-31f4-46ef-9bc2-2466b2b91882@default> (raw)
In-Reply-To: <87d0ydilna.fsf@web.de>

> > But the interpreted code worked as I wanted.  Apparently it was the
> > first of the two clauses (not the second, which had the "unused"
> > lexical variable) that was ignored when interpreting.  That lexical 
> > variable was used when interpreting.
> 
> Are you sure?

No, not at this point.

> I get
> (macroexpand-1
>  '(pcase foo
>     (`,a `(not ,a))
>     ((and a (guard (not recursivep))) `(not ,a))))
> ==>
>  (let ((a foo))
>   `(not ,a))
> 
> and when running the pcase form, the lexical binding of RECURSIVEP is
> ignored for me, e.g.
> 
> (let ((recursivep t))
>   (pcase 1
>     (`,a `(not ,a))
>     ((and a (guard (not recursivep))) `(not ,a))))
> ==> (not 1)   (instead of nil)

OK, thanks.  The rest of the bug report stands, though.





  reply	other threads:[~2018-05-03 18:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-03  0:48 bug#31350: 27.0; `pcase' message: "Redundant pcase pattern" Drew Adams
2018-05-03  1:16 ` Michael Heerdegen
2018-05-03 18:18   ` Drew Adams [this message]
2020-08-20 15:55 ` Lars Ingebrigtsen
2020-10-03 22:52   ` Michael Heerdegen
2020-10-03 22:58     ` Drew Adams
2020-10-04  1:37       ` Michael Heerdegen
2020-10-04  2:06         ` Drew Adams
2020-10-04 14:03         ` Lars Ingebrigtsen
2020-10-04 17:45           ` Drew Adams
2020-10-04 23:55             ` Michael Heerdegen
2020-10-04 23:54           ` Michael Heerdegen
2020-12-12 13:24           ` Lars Ingebrigtsen
2020-12-12 17:00             ` Drew Adams
2020-12-12 19:01               ` Eli Zaretskii

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=c21ac6a1-31f4-46ef-9bc2-2466b2b91882@default \
    --to=drew.adams@oracle.com \
    --cc=31350@debbugs.gnu.org \
    --cc=michael_heerdegen@web.de \
    /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.