[PATCH] histedit: do not check experimental.histediting in extsetup
Pierre-Yves David
pierre-yves.david at ens-lyon.org
Thu Mar 10 11:43:53 EST 2016
On 03/10/2016 04:23 PM, Jun Wu wrote:
> On 03/10/2016 03:56 PM, Pierre-Yves David wrote:
>> But it is still in a global variable. If this is recomputed on the fly,
>> can't we keep it in the scope of the function?
>
> It requires "ui" to compute. We don't pass "ui" down to the functions which
> actually need it. I don't think passing down the "ui" object (the source of
> truth) is a good idea.
could we stick this in the histedit state?
1) the state is already passed around
2) If you start as ng, you need to keep being ng anyway.
> If you add parameters to pass the *actions, you probably want to pass
> primaryactions, secondaryactions, tertiaryactions, internalactions,
> hiddenactions as well and it will be a huge change because a lot of
> functions
We could gathers them into an "actions" variable
> will get involved. It will also prevent other extensions from adding new
> histedit actions. In general, I don't think the result will be better
> than the current code.
Given that the current code is using global variable to communication
data between functions in the stacks I've an hard time to believe we
can't do better :-/
Cheers
--
Pierre-Yves David
More information about the Mercurial-devel
mailing list