-
Notifications
You must be signed in to change notification settings - Fork 45
Description
The goal would be to provide a macro that acts mostly as a drop-in replacement for general-define-key
but that does as much work as possible at expansion time and does not include any general functions in the expansion (so general could be loaded only during compile time like use-package). Probably this would also be a good candidate for use in other libraries.
Some things could not still be supported. I have to make sure this is actually possible. For example, :definer
could not take a variable argument because the macro would need to know the definer to dispatch to at expansion time in order to avoid requiring general after compilation. Builtin definers would of course also need to be rewritten as macros.
A rework is needed anyway. In the process, I could improve a lot of things in the rewrite to remove a lot of the special handling (e.g. :states
remains builtin but using the extension facilities, parsing for :non-normal-prefix
/ :gloal-prefix
happens in the evil definer and not in the core definer, etc.).
I still think that it's useful to have general-define-key
as a function, so maybe I would move all shared helpers into another file as discussed in #144.