[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-API] [PATCH] int64 operators
# HG changeset patch # User Jonathan Knowles <jonathan.knowles@xxxxxxxxxxxxx> # Date 1282568307 -3600 # Node ID d6b47ef01193698a7c17d2ef0ab6feaec5eeedf5 # Parent 630c51dcfc241050ce34303920291b837671cd42 Adds an int64ext module. This module includes a set of commonly-used operators that work with the int64 data type. Signed-off-by: Jonathan Knowles <jonathan.knowles@xxxxxxxxxxxxx> diff -r 630c51dcfc24 -r d6b47ef01193 stdext/Makefile --- a/stdext/Makefile Mon Aug 23 13:58:07 2010 +0100 +++ b/stdext/Makefile Mon Aug 23 13:58:27 2010 +0100 @@ -30,6 +30,7 @@ hashtblext \ pervasiveext \ threadext \ + int64ext \ ring \ qring \ fring \ diff -r 630c51dcfc24 -r d6b47ef01193 stdext/int64ext.ml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/stdext/int64ext.ml Mon Aug 23 13:58:27 2010 +0100 @@ -0,0 +1,17 @@ +module Int64 = struct + + module Operators = struct + + let ( +++ ) = Int64.add + let ( --- ) = Int64.sub + let ( *** ) = Int64.mul + let ( /// ) = Int64.div + let ( &&& ) = Int64.logand + let ( ||| ) = Int64.logor + let ( <<< ) = Int64.shift_left + let ( >>> ) = Int64.shift_right_logical + let ( !!! ) = Int64.lognot + + end + +end diff -r 630c51dcfc24 -r d6b47ef01193 stdext/int64ext.mli --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/stdext/int64ext.mli Mon Aug 23 13:58:27 2010 +0100 @@ -0,0 +1,17 @@ +module Int64 : sig + + module Operators : sig + + val ( +++ ) : int64 -> int64 -> int64 + val ( --- ) : int64 -> int64 -> int64 + val ( *** ) : int64 -> int64 -> int64 + val ( /// ) : int64 -> int64 -> int64 + val ( &&& ) : int64 -> int64 -> int64 + val ( ||| ) : int64 -> int64 -> int64 + val ( <<< ) : int64 -> int -> int64 + val ( >>> ) : int64 -> int -> int64 + val ( !!! ) : int64 -> int64 + + end + +end \ No newline at end of file diff -r 630c51dcfc24 -r d6b47ef01193 xapi-libs.spec --- a/xapi-libs.spec Mon Aug 23 13:58:07 2010 +0100 +++ b/xapi-libs.spec Mon Aug 23 13:58:27 2010 +0100 @@ -201,6 +201,8 @@ /usr/lib/ocaml/stdext/gzip.cmx /usr/lib/ocaml/stdext/hashtblext.cmi /usr/lib/ocaml/stdext/hashtblext.cmx + /usr/lib/ocaml/stdext/int64ext.cmi + /usr/lib/ocaml/stdext/int64ext.cmx /usr/lib/ocaml/stdext/libstdext_stubs.a /usr/lib/ocaml/stdext/lazyList.cmi /usr/lib/ocaml/stdext/lazyList.cmx stdext/Makefile | 1 + stdext/int64ext.ml | 17 +++++++++++++++++ stdext/int64ext.mli | 17 +++++++++++++++++ xapi-libs.spec | 2 ++ 4 files changed, 37 insertions(+), 0 deletions(-) Attachment:
xen-api-libs.hg.patch _______________________________________________ xen-api mailing list xen-api@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/mailman/listinfo/xen-api
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |