Message from discussion
Questions...
Received: by 10.210.46.14 with SMTP id t14mr250804ebt.12.1239661039019;
Mon, 13 Apr 2009 15:17:19 -0700 (PDT)
Return-Path: <p...@p-cos.net>
Received: from mxin.vub.ac.be (mxin.vub.ac.be [134.184.129.112])
by gmr-mx.google.com with ESMTP id 16si652106ewy.3.2009.04.13.15.17.18;
Mon, 13 Apr 2009 15:17:18 -0700 (PDT)
Received-SPF: neutral (google.com: 134.184.129.112 is neither permitted nor denied by best guess record for domain of p...@p-cos.net) client-ip=134.184.129.112;
Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 134.184.129.112 is neither permitted nor denied by best guess record for domain of p...@p-cos.net) smtp.mail...@p-cos.net
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: ApoEAONM40mGuCsK/2dsb2JhbADNPIN8Bg
Received: from prog2.vub.ac.be ([134.184.43.10])
by smtp.vub.ac.be with ESMTP; 14 Apr 2009 00:17:19 +0200
Received: from [192.168.2.4] (99.226-243-81.adsl-dyn.isp.belgacom.be [81.243.226.99])
by prog2.vub.ac.be (Postfix) with ESMTP id CCE80EA0297
for <weblocks@googlegroups.com>; Tue, 14 Apr 2009 00:17:10 +0200 (CEST)
Message-Id: <20A82632-BD9A-45C1-9436-72E869DA4D4F@p-cos.net>
From: Pascal Costanza <p...@p-cos.net>
To: weblocks@googlegroups.com
In-Reply-To: <b381ea40904130911j3da8899nd8d36e3a96a58316@mail.gmail.com>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Content-Transfer-Encoding: 7bit
Mime-Version: 1.0 (Apple Message framework v930.3)
Subject: Re: [weblocks] Re: Questions...
Date: Tue, 14 Apr 2009 00:14:44 +0200
References: <20278D1C-BEE9-46A9-BF3E-A011A8923EF8@p-cos.net> <b381ea40904130911j3da8899nd8d36e3a96a58316@mail.gmail.com>
X-Mailer: Apple Mail (2.930.3)
On 13 Apr 2009, at 18:11, Vyacheslav Akhmechet wrote:
> On Mon, Apr 13, 2009 at 10:21 AM, Pascal Costanza <p...@p-cos.net>
> wrote:
>> The cl-cont webpage says that defgeneric and defmethod are currently
>> not supported.
> Yes, what I meant is that there is no defgeneric/cc and defmethod/cc.
> I had no need for them, and for reasons that I can't remember now
> writing a transformer for defmethod/cc was a little bit tricky (I
> don't think it was too tricky, I just didn't have a reason to spend
> the time writing it).
ok
>> However, if I understand correctly, it should be
>> possible to say this:
>>
>> (defmethod foo (...)
>> (with-call/cc ...))
> Sure, that will work. But strictly speaking, it's not a "full"
> continuation, because, for example, (foo :after) will be lost. I think
> to get this working so that people don't encounter surprises most of
> the time is tricky.
ok, I can imagine.
>> If this is indeed supported, it can happen that an invocation of
>> call-next-method is implicitly captured in a continuation.
> I've never done anything like this, defun/cc is usually more than
> enough for me. I don't think it happens in Weblocks codebase. But of
> course this would also need to be worked out. I think there are some
> subtle issues here.
ok
>> P.S.: The cl-cont webpage also says that catch, throw, progv and
>> unwind-protect are not supported. It should be possible to make that
>> work with the first-class dynamic environments support in ContextL
>> (only in the repository version at the moment)...
> Cool! I'm not sure what the semantics would be for some of these
> constructs, I'd have to look into it in more detail. Hopefully someone
> else does it before I get the chance to :)
Essentially, ContextL now provides a dynamic-wind construct, so that
you can say something like this:
(dynamic-wind
(unwind-protect
(proceed some protected code)
(some cleanup code)))
...and then later do a (capture-dynamic-environment) such that you can
reinstall such 'behavioral' dynamic bindings.
It's still in a somewhat experimental stage, I'm not 100% sure that
everything works as it should. That's why I agree: Someone should do
it, so that we all get feedback... ;)
Pascal
--
ELS'09: http://www.european-lisp-symposium.org/
Pascal Costanza, mailto:p...@p-cos.net, http://p-cos.net
Vrije Universiteit Brussel
Programming Technology Lab
Artificial Intelligence Lab
Pleinlaan 2, B-1050 Brussel, Belgium