From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.devel Subject: Re: Question on pcase Date: Fri, 30 Oct 2015 02:11:46 +0100 Message-ID: <877fm5kvn1.fsf@web.de> References: <871tcngdv2.fsf@gmail.com> <87k2qe1u09.fsf@web.de> <83r3kmrtat.fsf@gnu.org> <87r3kl22zk.fsf@web.de> <837fmdzpf2.fsf@gnu.org> <87oafp659p.fsf@web.de> <831tclzly9.fsf@gnu.org> <87fv115t20.fsf@web.de> <87io5tzkt8.fsf@gmail.com> <87fv0xd2jr.fsf@web.de> <87egggya6e.fsf@gmail.com> <87twpcidyl.fsf@web.de> <87h9lcid0g.fsf@web.de> <87fv0ukgx2.fsf@web.de> <87ziz280wh.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1446167550 15356 80.91.229.3 (30 Oct 2015 01:12:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 30 Oct 2015 01:12:30 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 30 02:12:22 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZryEv-0003x9-TT for ged-emacs-devel@m.gmane.org; Fri, 30 Oct 2015 02:12:22 +0100 Original-Received: from localhost ([::1]:47905 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZryEv-0004i5-Cn for ged-emacs-devel@m.gmane.org; Thu, 29 Oct 2015 21:12:21 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33048) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZryEc-0004OY-9p for emacs-devel@gnu.org; Thu, 29 Oct 2015 21:12:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZryEY-00061N-B0 for emacs-devel@gnu.org; Thu, 29 Oct 2015 21:12:02 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:35762) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZryEY-000615-48 for emacs-devel@gnu.org; Thu, 29 Oct 2015 21:11:58 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1ZryET-0003Wr-Vo for emacs-devel@gnu.org; Fri, 30 Oct 2015 02:11:54 +0100 Original-Received: from ip-90-186-1-82.web.vodafone.de ([90.186.1.82]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 30 Oct 2015 02:11:53 +0100 Original-Received: from michael_heerdegen by ip-90-186-1-82.web.vodafone.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 30 Oct 2015 02:11:53 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 15 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: ip-90-186-1-82.web.vodafone.de User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:cdBc6MGsSVQzPslHcjm1SazTmtc= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:192936 Archived-At: Oleh Krehel writes: > I think that we should at least encourage `pcase' to macroexpand to a > simple `cond' with a regular structure every time. If you mean to expand a single branch into a `cond' with a regular structure: The semantics of `pcase' is too complex for that. In general, you have a decision _tree_, because patterns can depend on each other, hence you can't expand to a `cond' form in the general case. Instead, you have a tree of nested `if's, combined with let bindings (that are used to construct the environment of bindings created by the pattern parts matched "so far"). Michael.