[Bese-devel] unwinding

Aleksandar Bakic a_bakic at yahoo.com
Mon Sep 26 19:11:37 UTC 2005


Hi,

First, here is a solution I like better:

(defaction logout ((c login-mixin))
  (setf (get-session-value 'user) nil) ; remove login info
  (setf (ucw::frame.window-component (ucw::context.current-frame *context*))
	(make-instance 'main))) ; simply throw away all the components

It works as I wanted. I just need to try it 1000 times and see if it leaks
memory... What do you think? (I do not count data that I may be stuffing
somewhere, but just UCW.)

I looked at arnesi again. What if the following code from handlers.lisp:

----
(defk catch-tag-k (catch env k)
    (tag)
  (evaluate-progn/cc (body catch) (register env :catch tag k) k))

(defmethod evaluate/cc ((catch catch-form) env k)
  (evaluate/cc (tag catch) env `(catch-tag-k ,catch ,env ,k)))

(defk throw-tag-k (throw env k)
    (tag)
  (evaluate/cc (value throw) env (lookup env :catch tag :error-p t)))

(defmethod evaluate/cc ((throw throw-form) env k)
  (evaluate/cc (tag throw) env
                `(throw-tag-k ,throw ,env ,k)))
----

were modified to call register and lookup at run-time and use a dynamic
environment instead of env? Am I missing something, i.e., is this more complex
than what it looks?

Thanks,
Alex


	
		
______________________________________________________ 
Yahoo! for Good 
Donate to the Hurricane Katrina relief effort. 
http://store.yahoo.com/redcross-donate3/ 




More information about the bese-devel mailing list