[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#50470: 27.1; 'company-mode' 'eshell'
From: |
Stefan Monnier |
Subject: |
bug#50470: 27.1; 'company-mode' 'eshell' |
Date: |
Sun, 19 Mar 2023 21:34:52 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
>> Ok, here we are.
>>> - (when (memq (char-after) eshell-glob-chars-list)
>>> + (when (and (not (bound-and-true-p eshell-parse-for-completion-p))
>>
>> Can we (cheaply) arrange so that the var is always defined at this
>> point (same for the other uses further down in the patch)?
>> Maybe by moving the `defvar` elsewhere (e.g. next to
>> `eshell-parse-argument-hook`)?
>
> It's a bit ugly, but I'm trying to follow the conventions in Eshell: since
> completion is an optional extension module for Eshell, other modules jump
> through hoops like this to allow the module to be not-loaded.
I definitely don't want to force preloading that module.
But maybe that var could have a meaning that's independent
from completion, thus justifying to move it out of the completion
extension module?
E.g. something like "keep parsing free of side effects"? This would also
have the benefit of clarifying the actual meaning of this var: defining
a var based on who uses it or how it's used is always a source of
trouble.
> Another way to do this (arguably more Eshell-y) would be:
>
> (when (and (eshell-using-module 'eshell-cmpl)
> eshell-parsing-for-completion)
`boundp` is definitely much better.
Stefan
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/17
- bug#50470: 27.1; 'company-mode' 'eshell', Dmitry Gutov, 2023/03/17
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/18
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/19
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/19
- bug#50470: 27.1; 'company-mode' 'eshell',
Stefan Monnier <=
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/20
- bug#50470: 27.1; 'company-mode' 'eshell', Dmitry Gutov, 2023/03/27
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/28
- bug#50470: 27.1; 'company-mode' 'eshell', Stefan Monnier, 2023/03/28
- bug#50470: 27.1; 'company-mode' 'eshell', Drew Adams, 2023/03/28
- bug#50470: 27.1; 'company-mode' 'eshell', Jim Porter, 2023/03/28
- bug#50470: 27.1; 'company-mode' 'eshell', Dmitry Gutov, 2023/03/28