1 ;;; -*- Mode: Emacs-Lisp -*-
4 ;;; ILISP CMU Common Lisp dialect definition
7 ;;; This file is part of ILISP.
8 ;;; Please refer to the file COPYING for copyrights and licensing
10 ;;; Please refer to the file ACKNOWLEGDEMENTS for an (incomplete) list
11 ;;; of present and past contributors.
13 ;;; $Id: ilisp-cmu.el,v 1.4 2002-06-03 23:37:00 wbd Exp $
15 (defvar cmulisp-source-directory-regexp
16 "\\/afs\\/cs\\.cmu\\.edu\\/project\\/clisp\\/src\\/[0-9]*\\/"
17 "*Regexp to match cmulisp source code directory.")
19 (defvar cmulisp-local-source-directory
21 "*Where the cmulisp sources really are.")
23 (defvar ilisp-cmulisp-init-file "cmulisp")
25 (defun cmulisp-source-directory-fixup-function ()
26 (if cmulisp-local-source-directory
27 (replace-match cmulisp-local-source-directory)))
29 (defun cmulisp-check-prompt (old new)
30 "Compare the break level printed at the beginning of the prompt."
31 (let* ((was-in-break (and old (string-match "]+" old)))
32 (old-level (if was-in-break
33 (- (match-end 0) (match-beginning 0))
35 (is-in-break (string-match "]+" new))
36 (new-level (if is-in-break
37 (- (match-end 0) (match-beginning 0))
39 (<= new-level old-level)))
42 (defdialect cmulisp "CMU Common LISP"
44 (ilisp-load-init 'cmu ilisp-cmulisp-init-file)
45 (if cmulisp-local-source-directory
46 (setq ilisp-source-directory-fixup-alist
48 (cons cmulisp-source-directory-regexp
49 cmulisp-local-source-directory)))
50 (message "cmulisp-local-source-directory not set."))
51 (setq comint-prompt-regexp "^\\([0-9]+\\]+\\|\\*\\|[-a-zA-Z0-9]*\\[[0-9]+\\]:\\) "
52 ilisp-trace-command "(ILISP:cmulisp-trace \"%s\" \"%s\" \"%s\")"
54 (function (lambda (old line)
55 (comint-prompt-status old line 'cmulisp-check-prompt)))
57 ilisp-error-regexp "ILISP:[^\"]*\\|Error [^\n]*\n\n"
58 ;; The above regexp has been suggested by
59 ;; hunter@work.nlm.nih.gov (Larry Hunter)
62 ;; 19991219 Marco Antoniotti
63 ;; Changed the very low level call to ARGLIST to the more
64 ;; sophisticated ILISP-ARGLIST.
66 ;; ilisp-arglist-command "(ILISP:arglist \"%s\" \"%s\")"
67 ilisp-arglist-command "(ILISP:ilisp-arglist \"%s\" \"%s\")"
69 ilisp-directory-command "(namestring (ext:default-directory))"
70 ilisp-set-directory-command "(setf (ext:default-directory) \"%s\")"
72 ilisp-find-source-command "(ILISP:source-file \"%s\" \"%s\" \"%s\")"
74 comint-fix-error ":pop"
80 comint-interrupt-regexp "Interrupted at"
84 ;; The global definition should now take care to find out the
85 ;; proper extension. See file 'ilisp-cl.el'.
87 ;; 19990806 Marco Antoniotti
88 ;; As Martin Atzmueller has pointed out, these hardcoded
89 ;; constraints are very nasty.
90 ;; However, before hacking the code right here, I'd like to
91 ;; see an all-out solution to the binary file extension problem.
93 ;; ilisp-binary-extension "sparcf"
94 ;; ilisp-init-binary-extension "sparcf"
95 ;; ilisp-binary-command "\"sparcf\""
100 (setq ild-abort-string ":abort"
101 ild-continue-string ":go"
102 ild-step-string ":step"
103 ild-step-string-arg nil
104 ild-next-string ":down"
105 ild-next-string-arg nil ; needs work
106 ild-previous-string ":up"
107 ild-previous-string-arg nil ; needs work
108 ild-top-string ":bottom"
109 ild-bottom-string ":top"
110 ild-backtrace-string ":backtrace"
111 ild-locals-string ":l"
112 ild-local-string-arg "(debug:arg %s)"
113 ild-return-string nil ; needs work (debug:debug-return x)
114 ild-retry-string nil ; needs work
115 ild-trap-on-exit-string nil ; needs work
119 ;;; end of file -- ilisp-cmu.el --