Improve lua bindings parsing #14634
Describe the featureI suggest to treat more cases in the config as errors. It will simplify debugging config errors. In particular:
And another relevant improvement would be to compare and treat bind hotkeys as sets of keys rather than strings. Why would it be beneficialThe cases above are either unsupported already, or are supported but unlikely to be intended by users. However, when appearing by mistake, they are hard to debug, and error messages would help with that. |
Replies: 6 comments 9 replies
disagree
Fair
Fair, we should enforce signatures better
Yes Do you wanna take this one? |
|
+1: display a warning when an unrecognized extra argument is provided to any dispatcher, like |
|
+1: it turns out |
@kolayne I just wanted to mention that this is already sort of possible using lua, you can write a wrapper and then leverage lua tables like this: {
['SUPER + RETURN'] = app.terminal,
['SUPER + RETURN'] = app.browser, -- Emits LSP warning as "Duplicate index `SUPER + RETURN`"
}Caveat is it won't emit anything for a swapped key order because it's no longer identical, but it's still something. |
#15871