From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id yOv1FB8yB2DMMgAA0tVLHw (envelope-from ) for ; Tue, 19 Jan 2021 19:25:19 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id +PO3EB8yB2BccAAAB5/wlQ (envelope-from ) for ; Tue, 19 Jan 2021 19:25:19 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 03F2E9403A6 for ; Tue, 19 Jan 2021 19:25:19 +0000 (UTC) Received: from localhost ([::1]:42588 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l1wcv-0007Zp-QG for larch@yhetil.org; Tue, 19 Jan 2021 14:25:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:50566) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1vsF-0004gC-5p for emacs-orgmode@gnu.org; Tue, 19 Jan 2021 13:37:03 -0500 Received: from mout-p-201.mailbox.org ([2001:67c:2050::465:201]:65024) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1l1vsA-0001XZ-W2 for emacs-orgmode@gnu.org; Tue, 19 Jan 2021 13:37:02 -0500 Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4DKy6r1p38zQlWR; Tue, 19 Jan 2021 19:36:52 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de Received: from smtp2.mailbox.org ([80.241.60.241]) by spamfilter02.heinlein-hosting.de (spamfilter02.heinlein-hosting.de [80.241.56.116]) (amavisd-new, port 10030) with ESMTP id R5Idf7JJW5ra; Tue, 19 Jan 2021 19:36:49 +0100 (CET) From: Kevin Foley To: Ihor Radchenko , emacs-orgmode@gnu.org Subject: Re: Custom Bulk Functions With Prompt In-Reply-To: <878s8qwrvb.fsf@localhost> References: <871rekxgpf.fsf@localhost> <87lfcrvvro.fsf@localhost> <878s8qwrvb.fsf@localhost> Date: Tue, 19 Jan 2021 13:36:46 -0500 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-MBO-SPAM-Probability: X-Rspamd-Score: -2.10 / 15.00 / 15.00 X-Rspamd-Queue-Id: 370EC170F X-Rspamd-UID: 1ddc47 Received-SPF: pass client-ip=2001:67c:2050::465:201; envelope-from=kevin@kevinjfoley.me; helo=mout-p-201.mailbox.org X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -2.35 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 03F2E9403A6 X-Spam-Score: -2.35 X-Migadu-Scanner: scn1.migadu.com X-TUID: mzZJpM4Er9GL Ihor Radchenko writes: > You need to add extra matcher `(,_ ,argf ,f). My idea is to keep allow the user to optionally pass a list of argf and f instead of just a function. For example if no args need to be collected: '((?R set-category) (?C bulk-cut)) but if arguments needs to be collected for set-category: '((?R (set-category set-category-args)) (?C bulk-cut)) I mostly went with this because I'm not very familiar with `pcase'. I've confirmed it works as expected but let me know if you still think another approach is better. Kevin