From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Matt Wette Newsgroups: gmane.lisp.guile.user Subject: Re: syntax taste: use of unquote in macros Date: Mon, 30 Mar 2020 16:43:47 -0700 Message-ID: <2fc3bffd-da8d-eb4b-094b-649cf76e3fee@gmail.com> References: <91a7553d-2f04-4319-3437-fbe05cddde47@posteo.de> <20200330103402.GC22399@tuxteam.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="74765"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Tue Mar 31 01:44:07 2020 Return-path: Envelope-to: guile-user@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jJ44c-000JL5-U0 for guile-user@m.gmane-mx.org; Tue, 31 Mar 2020 01:44:06 +0200 Original-Received: from localhost ([::1]:58140 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJ44b-0005xd-GG for guile-user@m.gmane-mx.org; Mon, 30 Mar 2020 19:44:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33278) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJ44Q-0005w8-BB for guile-user@gnu.org; Mon, 30 Mar 2020 19:43:55 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jJ44P-0007hn-60 for guile-user@gnu.org; Mon, 30 Mar 2020 19:43:54 -0400 Original-Received: from mail-pf1-x431.google.com ([2607:f8b0:4864:20::431]:35130) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jJ44O-0007cB-UC for guile-user@gnu.org; Mon, 30 Mar 2020 19:43:53 -0400 Original-Received: by mail-pf1-x431.google.com with SMTP id u68so9418914pfb.2 for ; Mon, 30 Mar 2020 16:43:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding:content-language; bh=/OST4VSgsrf57TlB/4/8FEmVZ7RUDw1CnffxP1aU3bo=; b=nvquxdbeEX1MTHCm1cq4hgwInXM47Y2v4vr/ipvxmQNONSsc134c/a4SI9AtyqP5jn DIUQ3vyIOMZSDmeH1ZnlcXZKn4a2X0ZlmfO+Foqoa+gW74IicOQhhahAeTTHgc1jP7gs E09lQSfYI36sHhhoDTNNnMiG8Y0JJpoebVQ+DgqYQ6ACw2eCGOiBPIh8Tc3zpdzrls+d KoWrLIayxMmtxCSpEa7Q963ZxiEhuWydYU50+9dPXJ8t6tTN1PkeJoTQSzjmh7gQpmll bWp8+eEMnu8kn7FEr7FvRG5hkS0SSI/Y03Lu8OKmMtMICFoauICINa5VXWrvA8mf8oG8 591A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=/OST4VSgsrf57TlB/4/8FEmVZ7RUDw1CnffxP1aU3bo=; b=diqHhiTtkN6OQI3UtfYC3xdTNzlJGWfKINyeCh5eBQfcOIyhmb5eUELLzKP5rjhpRY QO9+Yd6ANbWDppweI2fUCl+ZQFweZLZxu9B1s4HTdsmFtHFURshKjAHjTWC9mHxWR1bs e7McVQ0tIAE8womdaosZJNEuc5Yep/MBBi0eOJhnvgvCD3CKz8oFJ9Y/G89OQkIDp0xg vDVQcpqZQEdMtONFsJgYyD9914Im8At2h5WsRiR25pUr8Q0oO6NrBdxdKn1qw4ygssfh Vm4WdXNOweiIoJQXJKGJD3e6/0exzVFefzzNJ6W9PDFxfXt2Bv+rsMtj/KYnz+R0y4SD Ytxw== X-Gm-Message-State: ANhLgQ3oSFjJOaeKPLDUlCusXGeC+KLYxeqhxBaqGGzcp7DH3m9WaMMJ bjNmsi/dGqn0Gc/wQohd9xqI+N0r X-Google-Smtp-Source: ADFU+vsReXtRF6GPSIg2QEn6Lyfh9HxbqhoLyuaJrumx/GAZeEiLd2qBWLEB3F078mRaeOz3j5f8LQ== X-Received: by 2002:a63:1d4:: with SMTP id 203mr15363954pgb.416.1585611829944; Mon, 30 Mar 2020 16:43:49 -0700 (PDT) Original-Received: from [192.168.2.183] (64-52-176-132.championbroadband.com. [64.52.176.132]) by smtp.gmail.com with ESMTPSA id f22sm10397531pgl.20.2020.03.30.16.43.48 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 30 Mar 2020 16:43:49 -0700 (PDT) In-Reply-To: <20200330103402.GC22399@tuxteam.de> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::431 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:16358 Archived-At: On 3/30/20 3:34 AM, tomas@tuxteam.de wrote: > On Mon, Mar 30, 2020 at 12:07:07AM +0200, Zelphir Kaltstahl wrote: >> On 3/29/20 5:11 PM, Matt Wette wrote: >>> Hi All, >>> >>> I'm not sure if you know about this, but there is a discrepancy in the >>> way some folks define macros to use unquote (aka ,).   For example, > [pmatch vs. match] > >> I'm not sure where I first read about pmatch doing the quasiquote >> internally automatically and I of course had already forgotten about it, > [...] > > I didn't even know about `pmatch'. Is it supposed to be equivalent > to `match' (except that outer quasiquote, that is)? > > With the caveat that I don't have much of a stylistic feeling for > Scheme, I'd clearly prefer `match': the writer has the choice of > quote or quasiquote, as appropriate to the case -- and the reader > sees what's going on (after all, quote and quasiquote are "low > weight" primitives: everyone more or less knows what they do. > > But perhaps I misunderstood what you're after? > > Cheers > -- tomás The other thing about match that is attractive is that use of quasiquote+unquote is "reflexive" (or maybe self-adjoint?) in the following sense: '(foo "bar") => (match-lambda (`(foo ,val) `(foo ,val))) => '(foo "bar")