X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=lib%2Fint63_on_32.ml;h=2312aa9104ad7cbbdb3179f1016075d026a7c9c4;hb=HEAD;hp=37349ad50bc2d2066784a94e5ec7c706aaeeb8af;hpb=8c2be1f021e65637f24b0ecd1907f7a069e347a2;p=virt-df.git diff --git a/lib/int63_on_32.ml b/lib/int63_on_32.ml index 37349ad..2312aa9 100644 --- a/lib/int63_on_32.ml +++ b/lib/int63_on_32.ml @@ -1,19 +1,20 @@ (* 63 bit signed integer type. (C) Copyright 2008 Richard W.M. Jones, Red Hat Inc. - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version, + with the OCaml linking exception described in ../COPYING.LIB. - This program is distributed in the hope that it will be useful, + This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *) (* This is the 32 bit implementation so we have to use the boxed @@ -32,8 +33,12 @@ module Operators = struct external ( -^ ) : int64 -> int64 -> int64 = "%int64_sub" external ( *^ ) : int64 -> int64 -> int64 = "%int64_mul" external ( /^ ) : int64 -> int64 -> int64 = "%int64_div" - external ( <<^ ) : int64 -> int -> int64 = "%int64_lsl" - external ( >>^ ) : int64 -> int -> int64 = "%int64_lsr" + external ( %^ ) : int64 -> int64 -> int64 = "%int64_mod" + external ( <^< ) : int64 -> int -> int64 = "%int64_lsl" + external ( >^> ) : int64 -> int -> int64 = "%int64_lsr" + external ( &^ ) : int64 -> int64 -> int64 = "%int64_and" + external ( |^ ) : int64 -> int64 -> int64 = "%int64_or" + external ( ^^ ) : int64 -> int64 -> int64 = "%int64_xor" external ( ~^ ) : int -> int64 = "%int64_of_int" let ( ~^~ ) i = Int64.neg (Int64.of_int i) end