unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
@ 2022-06-13 16:38 Sean Whitton
  2022-06-13 17:04 ` Eli Zaretskii
  0 siblings, 1 reply; 9+ messages in thread
From: Sean Whitton @ 2022-06-13 16:38 UTC (permalink / raw)
  To: 55946

Hello,

I'd like to define an abbrev for minibuffer-mode but it doesn't have an
abbrev table.  There's a comment in minibuffer.el saying that this is
because abbrev.el is not loaded early enough.  It would be useful to
have the abbrev table for this mode too.

-- 
Sean Whitton





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 16:38 bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table Sean Whitton
@ 2022-06-13 17:04 ` Eli Zaretskii
  2022-06-13 17:35   ` Sean Whitton
  0 siblings, 1 reply; 9+ messages in thread
From: Eli Zaretskii @ 2022-06-13 17:04 UTC (permalink / raw)
  To: Sean Whitton; +Cc: 55946

> From: Sean Whitton <spwhitton@spwhitton.name>
> Date: Mon, 13 Jun 2022 11:38:43 -0500
> 
> I'd like to define an abbrev for minibuffer-mode but it doesn't have an
> abbrev table.  There's a comment in minibuffer.el saying that this is
> because abbrev.el is not loaded early enough.

AFAICT, we only invoke this mode from C if it is fboundp.  So maybe
try changing that, and see if both a bootstrap and a simple build run
to completion OK.





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 17:04 ` Eli Zaretskii
@ 2022-06-13 17:35   ` Sean Whitton
  2022-06-13 17:50     ` Eli Zaretskii
  0 siblings, 1 reply; 9+ messages in thread
From: Sean Whitton @ 2022-06-13 17:35 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 55946

Hello,

On Mon 13 Jun 2022 at 08:04PM +03, Eli Zaretskii wrote:

>> From: Sean Whitton <spwhitton@spwhitton.name>
>> Date: Mon, 13 Jun 2022 11:38:43 -0500
>>
>> I'd like to define an abbrev for minibuffer-mode but it doesn't have an
>> abbrev table.  There's a comment in minibuffer.el saying that this is
>> because abbrev.el is not loaded early enough.
>
> AFAICT, we only invoke this mode from C if it is fboundp.  So maybe
> try changing that, and see if both a bootstrap and a simple build run
> to completion OK.

Thanks.  I see what you mean.  Tested both of those and it works.  Shall
I push to master so it can receive wider testing?

-- 
Sean Whitton





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 17:35   ` Sean Whitton
@ 2022-06-13 17:50     ` Eli Zaretskii
  2022-06-13 21:26       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 1 reply; 9+ messages in thread
From: Eli Zaretskii @ 2022-06-13 17:50 UTC (permalink / raw)
  To: Sean Whitton, Stefan Monnier; +Cc: 55946

> From: Sean Whitton <spwhitton@spwhitton.name>
> Cc: 55946@debbugs.gnu.org
> Date: Mon, 13 Jun 2022 12:35:43 -0500
> 
> >> I'd like to define an abbrev for minibuffer-mode but it doesn't have an
> >> abbrev table.  There's a comment in minibuffer.el saying that this is
> >> because abbrev.el is not loaded early enough.
> >
> > AFAICT, we only invoke this mode from C if it is fboundp.  So maybe
> > try changing that, and see if both a bootstrap and a simple build run
> > to completion OK.
> 
> Thanks.  I see what you mean.  Tested both of those and it works.  Shall
> I push to master so it can receive wider testing?

Let's see what Stefan thinks about this.

Stefan, any comments?





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 17:50     ` Eli Zaretskii
@ 2022-06-13 21:26       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-06-13 22:27         ` Sean Whitton
  0 siblings, 1 reply; 9+ messages in thread
From: Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-06-13 21:26 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 55946, Sean Whitton

>> >> I'd like to define an abbrev for minibuffer-mode but it doesn't have an
>> >> abbrev table.  There's a comment in minibuffer.el saying that this is
>> >> because abbrev.el is not loaded early enough.
>> >
>> > AFAICT, we only invoke this mode from C if it is fboundp.  So maybe
>> > try changing that, and see if both a bootstrap and a simple build run
>> > to completion OK.
>> 
>> Thanks.  I see what you mean.  Tested both of those and it works.  Shall
>> I push to master so it can receive wider testing?
>
> Let's see what Stefan thinks about this.
> Stefan, any comments?

I couldn't find the corresponding patch, so I don't know what to say.

The comment only refers to defining an abbrev table while loading
`minibuffer.el` because `minibuffer.el` was loaded by `abbrev.el`.
But AFAICT nowadays `abbrev.el` is loaded before `minibuffer.el`, so the
problem seems to have disappeared.


        Stefan






^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 21:26       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2022-06-13 22:27         ` Sean Whitton
  2022-06-14  1:40           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 1 reply; 9+ messages in thread
From: Sean Whitton @ 2022-06-13 22:27 UTC (permalink / raw)
  To: Stefan Monnier, Eli Zaretskii; +Cc: 55946

[-- Attachment #1: Type: text/plain, Size: 1045 bytes --]

Hello,

On Mon 13 Jun 2022 at 05:26PM -04, Stefan Monnier wrote:

>>> >> I'd like to define an abbrev for minibuffer-mode but it doesn't have an
>>> >> abbrev table.  There's a comment in minibuffer.el saying that this is
>>> >> because abbrev.el is not loaded early enough.
>>> >
>>> > AFAICT, we only invoke this mode from C if it is fboundp.  So maybe
>>> > try changing that, and see if both a bootstrap and a simple build run
>>> > to completion OK.
>>>
>>> Thanks.  I see what you mean.  Tested both of those and it works.  Shall
>>> I push to master so it can receive wider testing?
>>
>> Let's see what Stefan thinks about this.
>> Stefan, any comments?
>
> I couldn't find the corresponding patch, so I don't know what to say.

Just the attached simple change.

> The comment only refers to defining an abbrev table while loading
> `minibuffer.el` because `minibuffer.el` was loaded by `abbrev.el`.
> But AFAICT nowadays `abbrev.el` is loaded before `minibuffer.el`, so the
> problem seems to have disappeared.

Cool.

-- 
Sean Whitton

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Add-abbrev-tables-for-minibuffer-mode-and-minibuffer.patch --]
[-- Type: text/x-patch, Size: 1214 bytes --]

From 791f4991873d4eba25ae608bedb67190f347074f Mon Sep 17 00:00:00 2001
From: Sean Whitton <spwhitton@spwhitton.name>
Date: Mon, 13 Jun 2022 12:24:17 -0500
Subject: [PATCH] Add abbrev tables for minibuffer-mode and
 minibuffer-inactive-mode

* lisp/minibuffer.el (minibuffer-mode, minibuffer-inactive-mode): Add
an abbrev table for each of these modes (bug#55946).
---
 lisp/minibuffer.el | 2 --
 1 file changed, 2 deletions(-)

diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el
index bf89874ecc..2fd4902ef2 100644
--- a/lisp/minibuffer.el
+++ b/lisp/minibuffer.el
@@ -2837,7 +2837,6 @@ minibuffer-inactive-mode-map
   "<down-mouse-1>" #'ignore)
 
 (define-derived-mode minibuffer-inactive-mode nil "InactiveMinibuffer"
-  :abbrev-table nil          ;abbrev.el is not loaded yet during dump.
   ;; Note: this major mode is called from minibuf.c.
   "Major mode to use in the minibuffer when it is not active.
 This is only used when the minibuffer area has no active minibuffer.
@@ -2859,7 +2858,6 @@ minibuffer-mode
 `minibuffer-setup-hook' and `minibuffer-exit-hook' rather than
 the mode hook of this mode."
   :syntax-table nil
-  :abbrev-table nil
   :interactive nil)
 
 ;;; Completion tables.
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-13 22:27         ` Sean Whitton
@ 2022-06-14  1:40           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-06-14 19:38             ` Sean Whitton
  0 siblings, 1 reply; 9+ messages in thread
From: Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-06-14  1:40 UTC (permalink / raw)
  To: Sean Whitton; +Cc: Eli Zaretskii, 55946

>> I couldn't find the corresponding patch, so I don't know what to say.
> Just the attached simple change.

Looks fine to me, thanks,


        Stefan






^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-14  1:40           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2022-06-14 19:38             ` Sean Whitton
  2022-06-15  8:54               ` Robert Pluim
  0 siblings, 1 reply; 9+ messages in thread
From: Sean Whitton @ 2022-06-14 19:38 UTC (permalink / raw)
  To: Stefan Monnier, 55946-done; +Cc: Eli Zaretskii

Hello,

On Mon 13 Jun 2022 at 09:40PM -04, Stefan Monnier wrote:

>>> I couldn't find the corresponding patch, so I don't know what to say.
>> Just the attached simple change.
>
> Looks fine to me, thanks,

Thanks, pushed.  I don't believe this needs a NEWS entry, but happy to
write one if others thing otherwise.

-- 
Sean Whitton





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table
  2022-06-14 19:38             ` Sean Whitton
@ 2022-06-15  8:54               ` Robert Pluim
  0 siblings, 0 replies; 9+ messages in thread
From: Robert Pluim @ 2022-06-15  8:54 UTC (permalink / raw)
  To: 55946; +Cc: spwhitton

>>>>> On Tue, 14 Jun 2022 14:38:43 -0500, Sean Whitton <spwhitton@spwhitton.name> said:

    Sean> Hello,
    Sean> On Mon 13 Jun 2022 at 09:40PM -04, Stefan Monnier wrote:

    >>>> I couldn't find the corresponding patch, so I don't know what to say.
    >>> Just the attached simple change.
    >> 
    >> Looks fine to me, thanks,

    Sean> Thanks, pushed.  I don't believe this needs a NEWS entry, but happy to
    Sean> write one if others thing otherwise.

Itʼs a new feature (in a sense) so announcing it would be nice.

Robert
-- 





^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-06-15  8:54 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-13 16:38 bug#55946: 29.0.50; minibuffer-mode lacks an abbrev table Sean Whitton
2022-06-13 17:04 ` Eli Zaretskii
2022-06-13 17:35   ` Sean Whitton
2022-06-13 17:50     ` Eli Zaretskii
2022-06-13 21:26       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-13 22:27         ` Sean Whitton
2022-06-14  1:40           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-14 19:38             ` Sean Whitton
2022-06-15  8:54               ` Robert Pluim

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).