winterTTr / ace-jump-mode

a quick cursor jump mode for emacs
https://github.com/winterTTr/ace-jump-mode/wiki
609 stars 72 forks source link

Don't throw errors due to user incompetence #73

Open Malabarba opened 9 years ago

Malabarba commented 9 years ago

Hi there, thanks for this fantastic package. I have a minor style suggestion.

The ace-jump commands throw errors when the user hits an invalid key. For instance: (error "[AceJump] Non-printable character").

user-error is more appropriate in these situations, since these are just pilot mistakes, not actual code problems. The difference being that user-error won't pop-up a backtrace if the user has debug-on-error turned on.

If user-error is being avoided in order to support earlier Emacs versions, then I'd recommend just using a message, which also won't pop backtraces.