What does the double minus (--) convention in function names mean in Emacs Lisp

前端 未结 2 698
小鲜肉
小鲜肉 2021-01-07 16:22

I\'ve been reading through a number of Emacs Lisp packages and have come across the convention of some functions being declared with -- after the library prefix, e.g.:

相关标签:
2条回答
  • 2021-01-07 16:49

    There is really no such thing as "internal" for Emacs. But yes, some programmers have adopted this convention to indicate things that are more internal -- meaning essentially that there will be less (or no) hesitation by implementors to change them. It's a way of letting users of the code be aware of this possible volatility.

    0 讨论(0)
  • 2021-01-07 17:02

    Emacs doesn't have any support for namespaces, packages, libraries or modules. Emacs sources therefore use foo- as a prefix for a foo library, and in some cases foo-- is used for bindings that are supposed to be internal.

    0 讨论(0)
提交回复
热议问题