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.devel Subject: Re: 29.0.60; keymap-local-set and keymap-global-set became less strict Date: Wed, 01 Feb 2023 15:50:02 +0200 Message-ID: <83sffpze9h.fsf@gnu.org> References: <5876987d-2479-f512-5767-218c8c16a909@daniel-mendler.de> <875ycngyji.fsf@gnus.org> <87zg9zvzuc.fsf@gmail.com> <831qna3frm.fsf@gnu.org> <87mt5yogct.fsf@gmail.com> <83y1pi1wz4.fsf@gnu.org> <87ilgmodk4.fsf@gmail.com> <83mt5y1r5u.fsf@gnu.org> <87bkmdo8e4.fsf@gmail.com> <831qn91qo0.fsf@gnu.org> <137753af-777d-2da3-c111-7e2d414633f1@daniel-mendler.de> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22412"; mail-complaints-to="usenet@ciao.gmane.io" Cc: rpluim@gmail.com, larsi@gnus.org, emacs-devel@gnu.org, monnier@iro.umontreal.ca To: Daniel Mendler Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Feb 01 14:50:45 2023 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 1pNDVd-0005gP-4J for ged-emacs-devel@m.gmane-mx.org; Wed, 01 Feb 2023 14:50:45 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pNDV6-0002kk-T7; Wed, 01 Feb 2023 08:50:12 -0500 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 1pNDV1-0002gu-6u for emacs-devel@gnu.org; Wed, 01 Feb 2023 08:50:08 -0500 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 1pNDUy-0001oJ-SI; Wed, 01 Feb 2023 08:50:04 -0500 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=OCCiHIoT1xGhDaF9K2DsUsmSudWGAt3890IbZmekI6Y=; b=Ok8Ch/XeAVw7 5DS3QMfEXjktuBqoRXQoyKEYxwoVX7d5To1OtMBaT18ZI8Qd6xDioaxcFKaKPgv0hamMOvTIMkPzK +Gxo6xMUr0+NPoiXWutyC4Ge0EUxJkepnG4xPUJ0GF0UkbOnsqKdE7TLvEcuVcyfC6r0xeaiKTdIi Y/faVZul5z3lGMKprASrz53XSBpJwAUbky6WyHMaPEGGDxfMjaPL7B0ErTtlClUtpbqLuIo4/gysV 2gaiGgExH0gAO7jAjGJTyuP0AEecAms5X30b9tY+1SUqAIrl4xl9rP6ZMzUXeJ6e8oy4GM9+5tqOW HyaEPT1ZZG0gqPCwYAU1KA==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pNDUx-0003qg-Lb; Wed, 01 Feb 2023 08:50:04 -0500 In-Reply-To: <137753af-777d-2da3-c111-7e2d414633f1@daniel-mendler.de> (message from Daniel Mendler on Wed, 1 Feb 2023 14:13:25 +0100) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:302861 Archived-At: > Date: Wed, 1 Feb 2023 14:13:25 +0100 > Cc: larsi@gnus.org, emacs-devel@gnu.org, monnier@iro.umontreal.ca > From: Daniel Mendler > > > Unless anyone else objects, please install this in a day or two. > > I object. With this change the non-interactive implementation is > polluted with an unnecessary INTERACTIVE argument It's an optional argument, so I fail to see how is that "pollution". > which would then > allow the non-interactive caller to still pass vector arguments. So? A malevolent enough programmer could replace keymap-global/local-set with an implementation that performs the conversion unconditionally, so the danger of someone hanging themselves with the rope Emacs gives them always exists. This function is supposed to help those who _want_ such problems to be caught, it isn't supposed to make Emacs a high-security prison, because that's simply impossible in Emacs. > Why can you not just move the whole conversion business into the > `interactive' form? This means we cannot use a string as interactive > form but we have to implement our own `keymap--read` function which is > then used like this: `(interactive (list (keymap--read ...) ...))`. It > is not as concise as the string form but would avoid any problems. Excuse me, but that's the tail wagging the dog. Please be reasonable, we want a change that is simple and safe enough to go into Emacs 29, because currently those functions are completely useless as interactive commands, and we want them to become the mainstay of binding keys interactively. > As better alternative we could also go with Stefan's proposal to allow > vectors as arguments in the first place. Over Lars's disagreement? I don't want to do that, with all due respect to Stefan, certainly not on emacs-29.