
@zenspider Ah that’s interesting. Maybe that newer auto-un-quoting is what defeated my effort to use #'
in the defcustom
default values. Maybe it unquoted that, but skipped the is-this-actually-a-function check — ironic given that defcustom
has this whole little contract-like DSL for describing valid values.

To be clear it was my own dang mistake. I’m talking about how to help Emacs help me avoid this kind of mistake. Like, for forms where most people probably write '("C-a" name-of-function)
I often go out of my way to write `("C-a" ,#'name-of-function)
just to get the byte compiler check.

I was just disappointed I couldn’t figure out how to do that in a (defcustom _ (choice (const __)))
.

The problem with the #'
approach is sometimes (like in add-hook
) where it breaks the diagnostic information

So say you do #’show-paren-mode, you get the function value - whereas the symbol is more useful at a glance.

A compromise I tend to do is to have an assert
function which makes sure there’s something in the function cell