From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dale Mellor Newsgroups: gmane.lisp.guile.user Subject: Help: equivalent syntax-case to defmacro Date: Tue, 05 May 2020 18:34:25 +0100 Organization: DM Bespoke Computer Solutions Ltd Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="67094"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Evolution 3.30.5-1.1 To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Tue May 05 22:08:26 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 1jW3re-000HMB-Ba for guile-user@m.gmane-mx.org; Tue, 05 May 2020 22:08:26 +0200 Original-Received: from localhost ([::1]:37606 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jW3rd-0002a7-Bc for guile-user@m.gmane-mx.org; Tue, 05 May 2020 16:08:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48320) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jW1tl-0007gI-JR for guile-user@gnu.org; Tue, 05 May 2020 14:02:29 -0400 Original-Received: from ec2-52-19-174-175.eu-west-1.compute.amazonaws.com ([52.19.174.175]:50892 helo=rdmp.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jW1tk-00075x-7r for guile-user@gnu.org; Tue, 05 May 2020 14:02:29 -0400 Original-Received: from [127.0.0.1] (helo=localhost) by rdmp.org with esmtp (Exim 4.92) (envelope-from ) id 1jW1Sc-00083l-EF for guile-user@gnu.org; Tue, 05 May 2020 17:34:26 +0000 Received-SPF: softfail client-ip=52.19.174.175; envelope-from=guile-qf1qmg@rdmp.org; helo=rdmp.org X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/05 13:34:26 X-ACL-Warn: Detected OS = ??? X-Spam_score_int: 5 X-Spam_score: 0.5 X-Spam_bar: / X-Spam_report: (0.5 / 5.0 requ) BAYES_00=-1.9, RDNS_DYNAMIC=0.982, SPF_HELO_SOFTFAIL=0.732, SPF_SOFTFAIL=0.665 autolearn=_AUTOLEARN X-Spam_action: no action X-Mailman-Approved-At: Tue, 05 May 2020 16:08:11 -0400 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:16430 Archived-At: Been struggling with this for a while, and nothing I try works. In test-suite/tests/getopt-long there is (defmacro deferr (name-frag re) (let ((name (symbol-append 'exception: name-frag))) `(define ,name (cons 'quit ,re)))) (deferr no-such-option "no such option") (display exception:no-such-option) and I would like to know how the equivalent with define-syntax... syntax-case would look. Thanks, Dale