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 TAA04204; Thu, 4 Dec 2003 19:51:18 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id TAA04539 for ; Thu, 4 Dec 2003 19:51:16 +0100 (MET) Received: from rwcrmhc11.comcast.net (rwcrmhc11.comcast.net [204.127.198.35]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id hB4IpF112457 for ; Thu, 4 Dec 2003 19:51:16 +0100 (MET) Received: from stratocaster.home (c-24-3-150-197.client.comcast.net[24.3.150.197]) by comcast.net (rwcrmhc11) with ESMTP id <2003120418511401300q9s30e>; Thu, 4 Dec 2003 18:51:14 +0000 Received: from ecc by stratocaster.home with local (Exim 3.36 #1 (Debian)) id 1ARyZF-0002qn-00 for ; Thu, 04 Dec 2003 13:51:13 -0500 Date: Thu, 4 Dec 2003 13:51:13 -0500 To: ocaml Subject: Re: [Caml-list] Troubles with marshaled/unmarshaled exception Message-ID: <20031204185113.GB10706@localhost> Mail-Followup-To: ocaml References: <3FCF78E7.4080907@baretta.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3FCF78E7.4080907@baretta.com> User-Agent: Mutt/1.5.4i From: "Eric C. Cooper" X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 marshaled:01 unmarshaled:01 baretta:01 artem:01 marshaled:01 unmarshaled:01 3.07:01 3.07:01 val:01 val:01 bool:01 caml:01 caml:01 alex:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Thu, Dec 04, 2003 at 07:11:51PM +0100, Alex Baretta wrote: > Artem Prisyznuk wrote: > >Hello, > > > >I found strange behavior of pattern matching of > >marshaled/unmarshaled exception. > > > >Next code describe problem: > > > > let e = Failure "test";; > > let e' = Marshal.from_string (Marshal.to_string e []) 0;; > > let print_fun exc = > > > It seems to work alright on 3.07+2. > > Here's my session: > > > Objective Caml version 3.07+2 > > > # let e = Failure "test";; > val e : exn = Failure "test" > # let e' : exn = Marshal.from_string (Marshal.to_string e []) 0;; > val e' : exn = Failure "test" > # e = e';; > - : bool = true But something is indeed broken. Here's a slight variant of the above: Objective Caml version 3.07+2 # let e = Failure "test";; val e : exn = Failure "test" # let e' = Failure "test";; val e' : exn = Failure "test" # let e'' = Marshal.from_string (Marshal.to_string e []) 0;; val e'' : 'a = # e'' ^ "good-bye";; Segmentation fault -- Eric C. Cooper e c c @ c m u . e d u ------------------- 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