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 NAA12953; Wed, 4 Sep 2002 13:20:18 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id NAA13065 for caml-list@pauillac.inria.fr; Wed, 4 Sep 2002 13:20:18 +0200 (MET DST) 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 PAA25417 for ; Tue, 3 Sep 2002 15:48:54 +0200 (MET DST) Received: from kruuna.Helsinki.FI (kruuna.helsinki.fi [128.214.205.14]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id g83DmrL25495 for ; Tue, 3 Sep 2002 15:48:54 +0200 (MET DST) Received: (from lealanko@localhost) by kruuna.Helsinki.FI (8.11.6/8.10.1) id g83DmqC19894; Tue, 3 Sep 2002 16:48:52 +0300 (EEST) Date: Tue, 3 Sep 2002 16:48:51 +0300 From: Lauri Alanko To: caml-list@inria.fr Subject: [Caml-list] Inter-thread exceptions Message-ID: <20020903164851.A26567@kruuna.Helsinki.FI> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Hello. How big a task would it be to implement asynchronous inter-thread exceptions? In practice the feature would amount to a function: val raise_to : exn -> Thread.t -> unit This would be most handy for implementing eg. timeouts: just make a thread that sleeps and raises an exception in the other thread when the time is spent. The GHC folks and John Reppy have done some work on spelling out the semantics of asynchronous exceptions in Haskell. Could this be used as a base for a similar system in a strict and impure setting like ocaml? What would be the main difficulties, both theoretically and implementation-wise? Lauri Alanko la@iki.fi ------------------- 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