From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id OAA23167; Tue, 16 Dec 2003 14:13:20 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id OAA22609 for ; Tue, 16 Dec 2003 14:13:19 +0100 (MET) Received: from smtp3.pp.htv.fi (smtp3.pp.htv.fi [213.243.153.173]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id hBGDDIH24989 for ; Tue, 16 Dec 2003 14:13:18 +0100 (MET) Received: from posti.pp.htv.fi (posti.pp.htv.fi [212.90.64.50]) by smtp3.pp.htv.fi (Postfix) with ESMTP id 36B2A27B3F1 for ; Tue, 16 Dec 2003 15:13:18 +0200 (EET) Received: from oro (aka.pp.htv.fi [213.243.183.115]) by posti.pp.htv.fi (8.11.1 (Revision 1.5+JAGae91741+JAGae92668) /8.11.1) with ESMTP id hBGDDHT26326 for ; Tue, 16 Dec 2003 15:13:17 +0200 (EET) Received: from naked by oro with local (Exim 3.36 #1 (Debian)) id 1AWF0m-0001g5-00 for ; Tue, 16 Dec 2003 15:13:16 +0200 To: caml-list@inria.fr Subject: [Caml-list] Python's yield, Lisp's call-cc or C's setjmp/longjmp in OCaml From: Nuutti Kotivuori Date: Tue, 16 Dec 2003 15:13:14 +0200 Message-ID: <87n09sucr9.fsf@naked.iki.fi> User-Agent: Gnus/5.1002 (Gnus v5.10.2) XEmacs/21.4 (Portable Code, linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Loop: caml-list@inria.fr X-Spam: no; 0.00; python's:01 lisp's:01 c's:01 generic:01 python's:01 lisp's:01 c's:01 ocaml:01 ocaml:01 caml:01 continuation:02 variant:02 wondering:04 bypass:05 curiosity:05 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk I am wondering, does OCaml provide any variant of being able to bypass the normal function call and return discipline? More or less generic implementations of this can be seen in for example Python's yield instruction, Lisp's call-cc or call with current continuation, or C's setjmp/longjmp. And if not, what are the chances of something like that seeing the light of day in the future? Are there any fundamental problems in OCaml that would make the implementation of such a thing exceedingly difficult? Just curiosity at this point. -- Naked ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners