From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Philip Kaludercic Newsgroups: gmane.emacs.devel Subject: Re: [ELPA] A Setup package Date: Mon, 15 Mar 2021 00:39:47 +0100 Message-ID: <87pn01gv98.fsf@posteo.net> References: <874kis6ots.fsf@posteo.net> <87pn186c5s.fsf@posteo.net> <87blbpk6l8.fsf@posteo.net> <87mtv6j0tf.fsf@posteo.net> <87zgz5hfk7.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30603"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Mar 15 00:41:12 2021 Return-path: Envelope-to: ged-emacs-devel@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 1lLaMC-0007ru-3H for ged-emacs-devel@m.gmane-mx.org; Mon, 15 Mar 2021 00:41:12 +0100 Original-Received: from localhost ([::1]:43756 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lLaMB-0003jP-2m for ged-emacs-devel@m.gmane-mx.org; Sun, 14 Mar 2021 19:41:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45854) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lLaKw-0002YP-9m for emacs-devel@gnu.org; Sun, 14 Mar 2021 19:39:54 -0400 Original-Received: from mout01.posteo.de ([185.67.36.65]:54306) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lLaKt-000875-Sm for emacs-devel@gnu.org; Sun, 14 Mar 2021 19:39:53 -0400 Original-Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 4A8A316005C for ; Mon, 15 Mar 2021 00:39:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1615765188; bh=9v7Tk+NOKZQw1Wh/Uv6e88Tbr2M2Sv/XVspwsFl+wY8=; h=From:To:Cc:Subject:Date:From; b=VKP3zarCQsazPlFagu8GTj/dhsV/xSfF5NwOqYHcq2n2HwiwtcB/Dv1OlKQPv4ROS nbqBgp68LjMxqN+U8/1SbMkSYYURmO+Jt1d/Sy+hor/jDhLdHmQcHsRNFXPPhimlhu n8iodjJIu9dY19PPMVyH/VodEUpXJCBhp9HvzwD/aKkVKwmdG81fodB7Tipn96KOut 1EGFhpzkL4aKgg3/oqIpHDmRWMcSoydWAtZNqrrZSbuAyrhQcEhRTuazMbCpaf58qQ G1G1LpY8XSMv9oVxEu3Px2PwzklIQvkKS1VITRkUWIP+2knFMpl1W1I+UQE9R/IWtF 3ffGqwTZJXnIQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4DzGHR58kGz6tmR; Mon, 15 Mar 2021 00:39:47 +0100 (CET) In-Reply-To: (Stefan Monnier's message of "Sun, 14 Mar 2021 16:19:14 -0400") Received-SPF: pass client-ip=185.67.36.65; envelope-from=philipk@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:266469 Archived-At: Stefan Monnier writes: >>> We don't yet have http://elpa.gnu.org/packages/setup.html OTOH because >>> the 0.1.0 version of the code is missing the copyright changes (the >>> release is made from the commit in which you bump the version number). >>> So if you want to make a release based on this code, you'll want to bump >>> up the version number. >> What exactly is missing? > > You missed this part: > > (the release is made from the commit in which you bump the version > number) > > the commit in which you changed `Version:` to the current 0.1.0 did not > have a "copyright FSF" line. Oops, my bad. I get it now. >> Why use help--make-usage at all? > > To avoid reinvent the wheel. I could reduce it to (mapcar (lambda (arg) (if (string-match "\\`&" (symbol-name arg)) arg (intern (upcase (symbol-name arg))))) (get sym 'setup-signature)) which does the job. >> It might be better to save the specification in a separate variable and >> modify this destructively for every setup-define call, so as to avoid >> the overhead of redefining the entire specification all the time. > > I wouldn't bother, no. In the patch below I instead did the > spec-processing when setting `setup-debug` (and I also dropped the > `none` support because I don't see what it gains: for a macro that > takes no arguments, `&rest sexp` works as well). > And there is a better option for Emacs-28 and after. The reason I introduced `none` was that :hide-mode is not repeatable and has no arguments, resulting in the edebug specification (":hide-mode" sexp) However this always fails to match. I am thinking about solving this by checking for a non-nil signature. The only thing I'm not yet sure of if this could have unintended side effects. -- Philip K.