Elisp get function arity?
问题 I'd like to be able to do: (function-arity (intern "expt")) I googled up this solution https://github.com/emacsmirror/parser/blob/master/parser-fn.el But it's using help-function-arglist , so it's not exactly straightforward. I'd like something more solid, preferably rock-solid. 回答1: There's no such thing as a rock-solid function-arity . In most cases where people want it, what they really want is to call a function in different ways depending on how many arguments it accepts (because its