Lisp通用封装中的外部和内部符号 [英] External vs Internal Symbols in Common Lisp Package
本文介绍了Lisp通用封装中的外部和内部符号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在Common Lisp软件包的上下文中,它们之间有什么区别?我正在阅读SLIME文档,并且一些命令对此进行了广泛提及。
What is the difference between them in the context of a Common Lisp package? I am reading through SLIME documentation and some commands mention that extensively.
推荐答案
Common Lisp软件包的作者可以为以下文件导出符号:包的用户。然后,该符号是一个外部符号,您可以使用 package-name:external-symbol-name
访问它。
The author of a Common Lisp package can export a symbol for the user of the package. Then the symbol is an external symbol and you can access it with package-name:external-symbol-name
.
内部符号并不供用户使用,而是可以使用 package-name :: symbol-name
Internal symbols are not meant for the user but can be accessed with package-name::symbol-name
更多说明在彼得·塞贝尔(Peter Seibel)的书和常用Lisp语言
这篇关于Lisp通用封装中的外部和内部符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文