<?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/01/8ee94a5b5e46b261b7599c6003b3a18b"
  from="Nicolas Cannasse &lt;warplayer@f...&gt;"
  author="Nicolas Cannasse"
  date="2003-01-25T12:46:27"
  subject="Re: [Caml-list] Need unsigned int"
  prev="2003/01/2a90151cd7b925c19cbd206907343e50"
  next="2003/01/15cd7ca215908267fbf01507e08c168c"
  prev-in-thread="2003/01/be461c4ff942cdbf26f01b18b78f15db"
  prev-thread="2003/01/a4cffb254f58984e709674a57450d264"
  next-thread="2003/01/18adbbf91ec34b35351de3a8ecc5092f"
  root="../../"
  period="month"
  listname="caml-list"
  title="Archives of the Caml mailing list">

<thread subject="[Caml-list] Need unsigned int">
<msg 
  url="2003/01/72c455ab961d117e66091b9e50b158a7"
  from="Christoph Bauer &lt;c_bauer@i...&gt;"
  author="Christoph Bauer"
  date="2003-01-20T19:06:30"
  subject="[Caml-list] Need unsigned int">
<msg 
  url="2003/01/a7f0ca55dfc7972117511c4551434184"
  from="Sven Luther &lt;luther@d...&gt;"
  author="Sven Luther"
  date="2003-01-20T20:58:38"
  subject="Re: [Caml-list] Need unsigned int">
</msg>
<msg 
  url="2003/01/2f8b8c3e56cbc57ad0828a8c4c361f8a"
  from="Nicolas Cannasse &lt;warplayer@f...&gt;"
  author="Nicolas Cannasse"
  date="2003-01-22T13:51:49"
  subject="Re: [Caml-list] Need unsigned int">
<msg 
  url="2003/01/4d220c5232a3b748cd9592002eec3313"
  from="Damien Doligez &lt;damien.doligez@i...&gt;"
  author="Damien Doligez"
  date="2003-01-23T15:01:17"
  subject="Re: [Caml-list] Need unsigned int">
<msg 
  url="2003/01/be461c4ff942cdbf26f01b18b78f15db"
  from="David Chase &lt;chase@w...&gt;"
  author="David Chase"
  date="2003-01-24T00:39:59"
  subject="Re: [Caml-list] Need unsigned int">
</msg>
<msg 
  url="2003/01/8ee94a5b5e46b261b7599c6003b3a18b"
  from="Nicolas Cannasse &lt;warplayer@f...&gt;"
  author="Nicolas Cannasse"
  date="2003-01-25T12:46:27"
  subject="Re: [Caml-list] Need unsigned int">
</msg>
</msg>
</msg>
</msg>
</thread>

<contents>
&gt; &gt; let ui_compare x y =
&gt; &gt;     x lsr 16 &lt; y lsr 16 || x land 0xFFFF &lt; y land 0xFFFF
&gt; 
&gt; Watch out !  This definition is wrong.
&gt; 

My fault !
Sometimes my keyboard is writing faster than my brain is thinking :)

Someting like :

let ui_compare x y =
    match x lsr 16 - y lsr 16 with
    | 0 -&gt; x land 0xFFFF &lt; y land 0xFFFF
    | n when n &gt; 0 -&gt; false
    | _ -&gt;  true

Should be okay

Nicolas Cannasse

-------------------
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>

