3 ;;; cl-chs-init.lisp --
4 ;;; Init file for CLisp H.S.
6 ;;; This file is part of ILISP.
7 ;;; Please refer to the file COPYING for copyrights and licensing
9 ;;; Please refer to the file ACKNOWLEGDEMENTS for an (incomplete) list
10 ;;; of present and past contributors.
12 ;;; $Id: cl-chs-init.lisp,v 1.3 2002-05-30 13:59:20 wbd Exp $
16 ;;; 19990912 Marco Antoniotti
17 ;;; Cleaned up for inclusion in 5.9.1. See also file 'cl-ilisp.lisp'
18 ;;; for related changes (e.g. in ILISP-ERRORS).
20 ;;; 1999-09-03; M. Atzmueller
21 ;;; removed obsolete stuff
23 ;;; 1999-06-15: M. Atzmueller
24 ;;; removed command to load inspect1.fas
25 ;;; load any INSPECTOR yourself if there is no other inspect!
27 ;;; 1999-05-31: M. Atzmueller
28 ;;; ilisp-arglist => #+clisp arglist (...) modified definition
29 ;;; another option might be sys::arglist ...
30 ;;; added command to preload inspect1
35 (defun ilisp-inspect (sexp package)
36 "Inspect SEXP in PACKAGE."
37 (when (not (ignore-errors (functionp #'inspect)))
39 "~% Try loading it yourself, or proceed without inspecting ... :-( !"
40 "~% There seems to be no INSPECTOR present!"))
43 (let ((*package* (ilisp-find-package package)))
44 (if (functionp #'inspect)
45 (let ((item-to-be-described (read-from-string sexp)))
46 (if (atom item-to-be-described)
47 (inspect item-to-be-described)
48 (inspect (eval item-to-be-described))))
49 (format t "Sorry -- can't inspect ~S as Clisp has no inspector!"
54 (let* ((s (with-output-to-string (s) (describe (symbol-function sym) s)))
55 (p (search "Argument list: " s)))
57 (read-from-string (subseq s (+ 15 (search "Argument list: " s))))
62 (eval-when (:execute :load-toplevel)
63 (when (not (compiled-function-p #'ilisp-inspect))
64 (ilisp-message t "File is not compiled, use M-x ilisp-compile-inits"))
66 (when (boundp 'system::*source-file-types*)
67 (pushnew (pathname ".lisp") system::*source-file-types* :test #'equalp))
71 ;;; end of file -- cl-chs-init.lsp --