bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#23486: 25.0.93; Modules: features missing from make_function


From: npostavs
Subject: bug#23486: 25.0.93; Modules: features missing from make_function
Date: Sun, 26 Mar 2017 23:57:20 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Philipp Stephani <address@hidden> writes:

> As an alternative, if people feel this would require too many
> parameters, I'd propose reverting the change that adds the documentation
> string.  A docstring without arglist is not very useful.  We could also
> remove the arity parameters and have the C function check the arity
> itself.

Looking at this a bit closer, I do think this adds too many parameters,
and in particular, requiring to pass in names for positional parameters
just makes no sense.  The names are never used (except for displaying
documentation).

But removing the docstring is not great.  IMO, the right solution here
is to use a subr-like object instead of a lambda, as suggested in a
FIXME in emacs-module.c:

  /* FIXME: Use a bytecompiled object, or even better a subr.  */

Then the arity could be checked with `subr-arity' or similar.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]