2
在Clozure Common Lisp 1.6上成功加載CFFI與(ql:quickload "cffi")
,我在*features*
中有CFFI-FEATURES:X86 CFFI-FEATURES:UNIX :CFFI
。我很好奇,但是爲什麼一些CFFI的功能與cffi-sys:
前綴可見:在Clozure Common Lisp中使用CFFI的包前綴混淆
? (documentation 'cffi:null-pointer 'function)
"Construct and return a null pointer."
? (documentation 'cffi-sys:%foreign-funcall 'function)
"Perform a foreign function call, document it more later."
而另一些人用cffi:
也行:
? (documentation 'cffi:null-pointer 'function)
"Construct and return a null pointer."
? (documentation 'cffi:%foreign-funcall 'function)
> Error: Reader error: No external symbol named "%FOREIGN-FUNCALL" in package #<Package "CFFI">.
> While executing: CCL::%PARSE-TOKEN, in process listener(1).
> Type :GO to continue, :POP to abort, :R for a list of available restarts.
> If continued: Use the internal symbol CFFI-SYS:%FOREIGN-FUNCALL
> Type :? for other options.
展望cffi_0.10.6/src/cffi-openmcl.lisp
我可以看到(defpackage #:cffi-sys ...
,所以怎麼來的那cffi:null-pointer
的作品?
好的,這是有道理的。總之,我應該堅持用'cffi:'來代替我的代碼。 – FilipK