<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE message PUBLIC
  "-//MLarc//DTD MLarc output files//EN"
  "../../mlarc.dtd"[
  <!ATTLIST message
    listname CDATA #REQUIRED
    title CDATA #REQUIRED
  >
]>

  <?xml-stylesheet href="../../mlarc.xsl" type="text/xsl"?>


<message 
  url="2003/12/92046be84e93b5a2a47e897222bfded0"
  from="Eric C. Cooper &lt;ecc@c...&gt;"
  author="Eric C. Cooper"
  date="2003-12-04T18:51:18"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception"
  prev="2003/12/28552e05a36f09840e6f5cd232399029"
  next="2003/12/47b8738b1718fa8a52906babb45145b3"
  prev-in-thread="2003/12/28552e05a36f09840e6f5cd232399029"
  next-in-thread="2003/12/47b8738b1718fa8a52906babb45145b3"
  prev-thread="2003/12/a44b6979f8c7ec6786ef716ab40f43de"
  next-thread="2003/12/e4ffe98ad674659fd303b53d209bccd5"
  root="../../"
  period="month"
  listname="caml-list"
  title="Archives of the Caml mailing list">

<thread subject="[Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/de1b3ad250df2edf7b41c396f72930ee"
  from="Artem Prisyznuk &lt;tema@s...&gt;"
  author="Artem Prisyznuk"
  date="2003-12-04T15:46:26"
  subject="[Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/28552e05a36f09840e6f5cd232399029"
  from="Alex Baretta &lt;alex@b...&gt;"
  author="Alex Baretta"
  date="2003-12-04T18:12:31"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/92046be84e93b5a2a47e897222bfded0"
  from="Eric C. Cooper &lt;ecc@c...&gt;"
  author="Eric C. Cooper"
  date="2003-12-04T18:51:18"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/47b8738b1718fa8a52906babb45145b3"
  from="Alex Baretta &lt;alex@b...&gt;"
  author="Alex Baretta"
  date="2003-12-04T19:05:53"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/5254d2036a06aae11b77de14da9203fa"
  from="Eric C. Cooper &lt;ecc@c...&gt;"
  author="Eric C. Cooper"
  date="2003-12-04T19:50:42"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
</msg>
</msg>
</msg>
<msg 
  url="2003/12/40b7b8cc4d914e46aa8f243bcc25e3a6"
  from="Artem Prisyznuk &lt;tema@s...&gt;"
  author="Artem Prisyznuk"
  date="2003-12-04T19:14:23"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
</msg>
</msg>
<msg 
  url="2003/12/bee38859b007b41ffefe31e5b16980d4"
  from="Jason Hickey &lt;jyh@c...&gt;"
  author="Jason Hickey"
  date="2003-12-05T00:14:46"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
<msg 
  url="2003/12/8a58951f46d789bf2b5c03ab17428fcf"
  from="Artem Prisyznuk &lt;tema@s...&gt;"
  author="Artem Prisyznuk"
  date="2003-12-05T07:31:44"
  subject="Re: [Caml-list] Troubles with marshaled/unmarshaled exception">
</msg>
</msg>
</msg>
</thread>

<contents>
On Thu, Dec 04, 2003 at 07:11:51PM +0100, Alex Baretta wrote:
&gt; Artem Prisyznuk wrote:
&gt; &gt;Hello,
&gt; &gt;
&gt; &gt;I found strange behavior of pattern matching of
&gt; &gt;marshaled/unmarshaled exception.
&gt; &gt;
&gt; &gt;Next code describe problem:
&gt; &gt;
&gt; &gt;    let e = Failure "test";;
&gt; &gt;    let e' = Marshal.from_string (Marshal.to_string e []) 0;;
&gt; &gt;    let print_fun exc =
&gt; 
&gt; 
&gt; It seems to work alright on 3.07+2.
&gt; 
&gt; Here's my session:
&gt; 
&gt; 
&gt;         Objective Caml version 3.07+2
&gt; 
&gt; 
&gt; # let e = Failure "test";;
&gt; val e : exn = Failure "test"
&gt; # let e' : exn = Marshal.from_string (Marshal.to_string e []) 0;;
&gt; val e' : exn = Failure "test"
&gt; # e = e';;
&gt; - : 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 = &lt;poly&gt;
# 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

</contents>

</message>

