From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#48153: 28.0.50; minor mode keymaps should not override keymap given to read-from-minibuffer Date: Mon, 03 May 2021 15:15:25 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19653"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 48153@debbugs.gnu.org To: Jimmy Yuen Ho Wong Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon May 03 17:16:12 2021 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 1ldaIt-00050r-GP for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 03 May 2021 17:16:11 +0200 Original-Received: from localhost ([::1]:36778 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldaIs-0001HY-Iw for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 03 May 2021 11:16:10 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44994) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ldaIk-0001Gv-Tx for bug-gnu-emacs@gnu.org; Mon, 03 May 2021 11:16:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:35360) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ldaIk-000818-M6 for bug-gnu-emacs@gnu.org; Mon, 03 May 2021 11:16:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ldaIk-0005iY-GH for bug-gnu-emacs@gnu.org; Mon, 03 May 2021 11:16:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 03 May 2021 15:16:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48153 X-GNU-PR-Package: emacs Original-Received: via spool by 48153-submit@debbugs.gnu.org id=B48153.162005492821965 (code B ref 48153); Mon, 03 May 2021 15:16:02 +0000 Original-Received: (at 48153) by debbugs.gnu.org; 3 May 2021 15:15:28 +0000 Original-Received: from localhost ([127.0.0.1]:46905 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldaIC-0005iD-Gs for submit@debbugs.gnu.org; Mon, 03 May 2021 11:15:28 -0400 Original-Received: from heytings.org ([95.142.160.155]:35812) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldaIB-0005i7-6G for 48153@debbugs.gnu.org; Mon, 03 May 2021 11:15:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20210101; t=1620054926; bh=WooOhoqY/4V2m6qczaj6oHX5V/7P5ewwqBCqZys23XI=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=qN+EXaWyWBebBO4MemcOK+tOnyOMHr51qDEekKe8/1uFq7uO+Zh18Nj7n5y1jnNPC Lkqak+jcrBUe95GVNhzQL1AOC7ANWp6NCdyv+HM7pSDs4+eehywjfbYjUBYnmKeU4I hY2ytri6ymwaxuqA2t7HVtdcQegDwlSyFMSO4kwrs2qt79nXo1C7A5WzlH2P/gqZKI 7TJLN8SWamTEt484ceXHqvbDG+ipyyNNB5Fho/8+WHdHNuF8skoABiBTV+X08NIMy1 pl+WyNyVQz+F0ZLN/U/0o9esoXCwFSyYOZpgmxOsZaBf2inJbnWBtlrc0KdGYRmnyO NQtOWeK2HJvKw== In-Reply-To: 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" Xref: news.gmane.io gmane.emacs.bugs:205521 Archived-At: > > After typing C-x b or C-x C-f, the minor mode maps from the buffer that > launched the minibuffer will override the keymap given to > `read-from-minibuffer`, this seems to be a regression in emacs 28 > master. > > Reproduction: > > 1. Turn on `ido-mode` > 2. Turn on some minor mode that rebinds `C-k` with `(define-key > some-minor-mode-map (kbd "C-k") 'some-func)` > 3. C-x b > 4. Select a buffer and type C-k > > Expectation: > > C-k should be bound to `ido-kill-buffer-at-head` and calls it, but > instead `some-func` is called. > > Since C-k is bound in `ido-completion-map`, and it is given to > `read-from-minibuffer`, all the bindings in `ido-completion-map` should > take precedence. > Thanks for your bug report. I'm unable to reproduce your recipe on recent versions of the trunk (today, a week ago). I tried (define-minor-mode test-mode "" :keymap (let ((map (make-sparse-keymap))) (define-key map (kbd "C-k") '(lambda () (interactive) (message "BAD !"))) map)) and C-k is indeed bound to 'ido-kill-buffer-at-head'. I suspect this misbehavior is due to your configuration; if not, could you try to create a recipe starting with emacs -Q?