lisp语言自带函数的用法作用如何查询
lisp吧
全部回复
仅看楼主
level 1
紫雨蝶眸 楼主
2014年10月07日 14点10分 1
level 7
2014年10月08日 00点10分 2
那如果要查dotimes这个函数的作用就执行(documentation('dotimes 'function)),是这样吧?
2014年10月08日 07点10分
回复 紫雨蝶眸 :你要查的函数里有文档字符串属性,才能用documentation方法。最好的办法是Alt+. 然后按提示做就行了
2014年10月08日 08点10分
回复 狙击手考拉 :在非emacs编辑器里面怎么办?
2014年10月08日 11点10分
回复 紫雨蝶眸 :你不可能每款编辑器或IDE都用吧?非emacs是指哪款? 最通行的办法是查在线文档,比如: http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/FrontMatter/Master-Index.htmlhttp://clhs.lisp.se/Front/X_Symbol.htm 网上有将其配置到IDE或编辑器的例子,你自己找吧
2014年10月08日 13点10分
level 4
clisp 下:用 (describ ) 不过是英文的.
[2]> (describe 'format)
FORMAT is the symbol FORMAT, lies in #<PACKAGE COMMON-LISP>, is accessible in 11
packages CLOS, COMMON-LISP, COMMON-LISP-USER, EXPORTING, EXT, FFI, POSIX, READLINE,
REGEXP, SCREEN, SYSTEM, names a function, has 1 property SYSTEM::DOC.
ANSI-CL Documentation is at
"http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_format.html"
CLISP Documentation is at
"http://clisp.cons.org/impnotes/print-formatted.html"
For more information, evaluate (SYMBOL-PLIST 'FORMAT).
# is the package named COMMON-LISP. It has 2 nicknames LISP,
CL.
It imports the external symbols of 1 package CLOS and exports 978 symbols to 10
packages READLINE, REGEXP, POSIX, EXPORTING, FFI, SCREEN, CLOS, COMMON-LISP-USER,
EXT, SYSTEM.
# is a compiled function.
Argument list: (
#:ARG0 #
:ARG1 &REST SYSTEM::OTHER-ARGS)
For more information, evaluate (DISASSEMBLE #'FORMAT).
Documentation:
SYSTEM::IMPNOTES:
"print-formatted.html"
CLHS:
"Body/fun_format.html"
SYSTEM::FILE:
((SYSTEM::DEFUN/DEFMACRO
#P"/home/kbrown/src/cygclisp/clisp-2.49-1.i686/build/format.fas" 342 368))
[3]> (describe 'car)
CAR is the symbol CAR, lies in #, is accessible in 11 packages
CLOS, COMMON-LISP, COMMON-LISP-USER, EXPORTING, EXT, FFI, POSIX, READLINE, REGEXP,
SCREEN, SYSTEM, names a function, has 3 properties SYSTEM::INSTRUCTION,
SYSTEM::SETF-EXPANDER, SYSTEM::DOC.
ANSI-CL Documentation is at
"http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/acc_carcm_cdr_darcm_cddddr.html"
For more information, evaluate (SYMBOL-PLIST 'CAR).
#<PACKAGE COMMON-LISP> is the package named COMMON-LISP. It has 2 nicknames LISP,
CL.
It imports the external symbols of 1 package CLOS and exports 978 symbols to 10
packages READLINE, REGEXP, POSIX, EXPORTING, FFI, SCREEN, CLOS, COMMON-LISP-USER,
EXT, SYSTEM.
#<SYSTEM-FUNCTION CAR> is a built-in system function.
Argument list: (#:ARG0)
For more information, evaluate (DISASSEMBLE #'CAR).
Documentation:
CLHS:
"Body/acc_carcm_cdr_darcm_cddddr.html"
SYSTEM::FILE:
((DEFSETF #P"/home/kbrown/src/cygclisp/clisp-2.49-1.i686/build/places.fas" 523 523))
[4]>
2015年03月14日 17点03分 3
1