From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#70589: [PATCH] Refine the Custom type of generated '*-modes' options Date: Fri, 26 Apr 2024 13:58:15 +0300 Message-ID: <86frv8z8zc.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36327"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 70589@debbugs.gnu.org, Stefan Monnier To: Eshel Yaron Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 26 12:59:04 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1s0JIF-0009Dn-T1 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 26 Apr 2024 12:59:04 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s0JI6-0007YG-IE; Fri, 26 Apr 2024 06:58:54 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s0JI3-0007XU-Is for bug-gnu-emacs@gnu.org; Fri, 26 Apr 2024 06:58:51 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s0JI3-0007cQ-75 for bug-gnu-emacs@gnu.org; Fri, 26 Apr 2024 06:58:51 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s0JIL-000581-4z for bug-gnu-emacs@gnu.org; Fri, 26 Apr 2024 06:59:09 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 26 Apr 2024 10:59:08 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70589 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 70589-submit@debbugs.gnu.org id=B70589.171412913619555 (code B ref 70589); Fri, 26 Apr 2024 10:59:08 +0000 Original-Received: (at 70589) by debbugs.gnu.org; 26 Apr 2024 10:58:56 +0000 Original-Received: from localhost ([127.0.0.1]:34060 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s0JI1-00054J-Bj for submit@debbugs.gnu.org; Fri, 26 Apr 2024 06:58:54 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57660) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s0JHs-00051c-U4 for 70589@debbugs.gnu.org; Fri, 26 Apr 2024 06:58:45 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s0JHV-0007XV-A5; Fri, 26 Apr 2024 06:58:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=thu0HyoJx9ws8m1+R9f/NncDzaB0O+wapSjK0zeMn3A=; b=ax8WwdnhmIBn +cv+hQ04G8zk7UteHMkv7Km4BPKSe12KtDH3nEMHZ2tRQljTmTSISfSm8QDOW+b3Aep2w2vhxuQew G4qeYltVYjB3IMNU58EOh3mpt6qgD/ZI3zXqpgA4P8MudVms+LJTPHrjtxF23NKfWv1eSj6mMhrnv YMfzsvSu05aevTKkaR/6rm4M2piCGUSDrYnh7qFE0CDz7kK9DBrOeauypo8oy0tApRLzVa4XDvsko WkEjf6HssFLvIEvoeUd/zhOBudPiu9CfYs55saSyQAUikfWdy/rCZy4jqs0bheBPCFM6zR6Y3dz+w 5LzA6J/hveikpJcQlEABwg==; In-Reply-To: (bug-gnu-emacs@gnu.org) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:283978 Archived-At: > Date: Fri, 26 Apr 2024 11:49:19 +0200 > From: Eshel Yaron via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > --- a/lisp/emacs-lisp/easy-mmode.el > +++ b/lisp/emacs-lisp/easy-mmode.el > @@ -580,7 +580,19 @@ define-globalized-minor-mode > and nil means \"don't use\". There's an implicit nil at the end of the > list." > mode) > - :type '(repeat sexp) > + :type '(choice (const :tag "Enable in all major modes" t) > + (const :tag "Don't enable in any major mode" nil) > + (repeat :tag "Only enable in" > + (choice > + (const :tag "All major modes" t) > + (const :tag "No major mode" nil) > + (symbol :value fundamental-mode > + :tag "Specific major mode") > + (cons :tag "Exclude modes" > + (const :tag "Exclude..." not) > + (repeat > + (symbol :value fundamental-mode > + :tag "Major mode")))))) Why does it make sense to have the "all" and "none" alternatives twice?