[slime-devel] Re: What is the difference between different ways to evaluate lisp forms?
Anders Conradi
beque at telia.com
Mon Jun 21 08:45:33 UTC 2004
On måndag, jun 21, 2004, at 08:33 Europe/Stockholm, Luke Gorrie wrote:
> Anders Conradi <beque at telia.com> writes:
>
>> If I start slime using openmcl 0.14.2-p1 on jaguar (mac os 10.2) I get
>> different behaviours that I can't explain when I evaluate lisp forms
>> fin different ways.
>>
>> I get one behaviour when I type C-x C-e after the form in the
>> *slime-repl* buffer or when I type the form at the prompt and press
>> enter and another behaviour when I type C-x C-e after the form in the
>> *inferior-lisp* buffer.
>
> Here are the cases:
>
> `C-x C-e' should be the same in every buffer, except that some
> buffers have different Lisp packages associated with them than
> others. In a default OpenMCL configuration it will evaluate each
> `C-x C-e' in a new thread.
>
> Entering the expression at the REPL is the same except that it
> always uses the same thread, i.e. one thread is dedicated to
> evaluating REPL expressions.
>
> If you enter it at the *inferior-lisp* prompt then you are bypassing
> SLIME entirely. It will evaluate in the same way as OpenMCL does
> when running without SLIME.
>
>> The form in question opens a cocoa-window using a window-controller
>> that is supposed to release the window when the window is closed. The
>> problem is that the window is only released and deallocated when I
>> evaluate the form to open the window from the inferior-lisp buffer by
>> typing C-x C-e, not in the other cases.
>
> I can't account for this. You're definitely pressing `C-x C-e' and not
> return in *inferior-lisp*? Can you give any more details?
Sure.
If I perform the steps
1) Open emacs
2) Type M-x slime
3) Open rpn-debug.lisp
4) Type C-c C-k in the rpn-debug.lisp buffer
5) C-x b to the *slime-repl*
6) type (open-calc) *but not enter*
7) Type C-x C-e
8) Split the window into two frames, one containing *slime-repl* and
one *inferior-lisp*
9) close the that opened by performing (open-calc)
Then I get the following in the *inferior-lisp* buffer:
(load "/Users/acon/emacs/slime/swank-loader.lisp")
(swank:start-server "/tmp/slime.11203")
Welcome to OpenMCL Version (Beta: Darwin) 0.14.2-p1!
? ; Warning: These Swank interfaces are unimplemented:
; (ADD-FD-HANDLER ADD-SIGIO-HANDLER LIST-CALLEES
MACROEXPAND-ALL PROFILE PROFILE-PACKAGE PROFILE-REPORT PROFILE-RESET
PROFILED-FUNCTIONS REMOVE-FD-HANDLERS REMOVE-SIGIO-HANDLERS SLDB-STEP
UNPROFILE WHO-BINDS WHO-CALLS WHO-MACROEXPANDS WHO-REFERENCES WHO-SETS
WHO-SPECIALIZES)
; While executing: SWANK-BACKEND::WARN-UNIMPLEMENTED-INTERFACES
#P"/Users/acon/Developer/Lisp/systems/slime/swank-loader.lisp"
? ;; Swank started at port: 59878.
59878
? 2004-06-21 10:26:58.175 [11205] *** Illegal NSTableView data source
(<RpnCalculator: 0x82339350>). Must implement numberOfRowsInTableView:
and tableView:objectValueForTableColumn:row:
2004-06-21 10:26:58.176 [11205] Window awaken
2004-06-21 10:27:11.210 [11205] Closing calculator
2004-06-21 10:27:11.231 [11205] calculator dealloc
And this in *slime-repl*:
; SLIME: The Superior Lisp Interaction Mode for Emacs
;;;; Compile file /Users/acon/Developer/Lisp/systems/rpn/rpn-debu ...
;;;; (open-calc) ...
CL-USER> (open-calc)
If I close emacs and perform the same steps up to step 4 and then do
5) switch to the *inferior-lisp* buffer
6) type (open-calc) *but not enter*
7) type C-x C-e
And then the same steps 8 & 9 I get in *inferior-lisp*:
(load "/Users/acon/emacs/slime/swank-loader.lisp")
(swank:start-server "/tmp/slime.11207")
Welcome to OpenMCL Version (Beta: Darwin) 0.14.2-p1!
? ; Warning: These Swank interfaces are unimplemented:
; (ADD-FD-HANDLER ADD-SIGIO-HANDLER LIST-CALLEES
MACROEXPAND-ALL PROFILE PROFILE-PACKAGE PROFILE-REPORT PROFILE-RESET
PROFILED-FUNCTIONS REMOVE-FD-HANDLERS REMOVE-SIGIO-HANDLERS SLDB-STEP
UNPROFILE WHO-BINDS WHO-CALLS WHO-MACROEXPANDS WHO-REFERENCES WHO-SETS
WHO-SPECIALIZES)
; While executing: SWANK-BACKEND::WARN-UNIMPLEMENTED-INTERFACES
#P"/Users/acon/Developer/Lisp/systems/slime/swank-loader.lisp"
? ;; Swank started at port: 59884.
59884
? 2004-06-21 10:28:51.063 [11209] *** Illegal NSTableView data source
(<RpnCalculator: 0x1b47610>). Must implement numberOfRowsInTableView:
and tableView:objectValueForTableColumn:row:
2004-06-21 10:28:51.064 [11209] Window awaken
2004-06-21 10:29:02.021 [11209] Closing calculator
2004-06-21 10:29:02.053 [11209] calculator dealloc
2004-06-21 10:29:02.053 [11209] Window dealloc
(open-calc)
And in *slime-repl*:
; SLIME: The Superior Lisp Interaction Mode for Emacs
;;;; Compile file /Users/acon/Developer/Lisp/systems/rpn/rpn-debu ...
;;;; (open-calc) ...
CL-USER>
This is the part of my .emacs file that configures slime:
;; Slime - The Superior Lisp Interaction Mode for Emacs
(add-to-list 'load-path "/Users/acon/emacs/slime/")
(require 'slime)
(add-hook 'lisp-mode-hook (lambda () (slime-mode t)))
(setq inferior-lisp-program "/Users/acon/Applications/bin/openmcl")
(add-hook 'inferior-lisp-mode-hook (lambda () (inferior-slime-mode t)))
(setq common-lisp-hyperspec-root
"file:///Users/acon/Documents/Bibliotek/HyperSpec-6-0/HyperSpec/")
I have attached a tarball containing rpn-debug.lisp and
RpnCalculator.nib.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: code.tar.gz
Type: application/x-gzip
Size: 8137 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/slime-devel/attachments/20040621/2ad51ce0/attachment.bin>
-------------- next part --------------
>
> -Luke
>
>
> _______________________________________________
> slime-devel site list
> slime-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/slime-devel
>
More information about the slime-devel
mailing list