[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#25189: Use `current-global-map' in `comint-insert-input'
From: |
Lars Ingebrigtsen |
Subject: |
bug#25189: Use `current-global-map' in `comint-insert-input' |
Date: |
Tue, 24 Dec 2019 17:25:26 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.60 (gnu/linux) |
Alexander Shukaev <emacs@Alexander.Shukaev.name> writes:
> On 7/27/19 1:29 PM, Lars Ingebrigtsen wrote:
>> Alexander Shukaev <emacs@Alexander.Shukaev.name> writes:
>>
>>> I think according to Emacs documentation it's more correct to change the
>>>
>>> (lookup-key global-map (vector last-key))
>>>
>>> form to the
>>>
>>> (lookup-key (current-global-map) (vector last-key))
>>>
>>> form.
>> (I'm going through older Emacs bug reports that have received no
>> response.)
>> Looking at the manual section in "Controlling Active Maps", there
>> doesn't seem to be anything to discourage using `global-map' directly
>> there. I've grepped through the sources, though, and `global-map' is
>> used all over the place (while `current-global-map' is used less).
>> So this doesn't seem like something to be fixed, and I'm closing
>> this
>> bug report.
>>
>
> I believe you want to read the docstring of `global-map' for that point.
It would help if you could point to where you think Emacs says this.
This is the doc string of global-map:
global-map is a variable defined in ‘subr.el’.
Its value is shown below.
This variable may be risky if used as a file-local variable.
Probably introduced at or before Emacs version 21.1.
Documentation:
Default global keymap mapping Emacs keyboard input into commands.
The value is a keymap that is usually (but not necessarily) Emacs’s
global map.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no