changeset 8191:9cb73236e552

fix uint64 mixed operations
author Jaroslav Hajek <highegg@gmail.com>
date Tue, 07 Oct 2008 15:28:45 +0200
parents 73d6b71788c0
children 9a0a66f650b1
files liboctave/ChangeLog liboctave/oct-inttypes.h
diffstat 2 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/ChangeLog	Mon Oct 06 21:06:05 2008 -0400
+++ b/liboctave/ChangeLog	Tue Oct 07 15:28:45 2008 +0200
@@ -1,3 +1,8 @@
+2008-10-07  Jaroslav Hajek <highegg@gmail.com>
+
+	* oct-inttypes.h (OCTAVE_INT_DOUBLE_BIN_OP): Change octave_int64 to 
+	octave_uint64 where appropriate.
+
 2008-10-06  David Bateman  <dbateman@free.fr>
 	
 	* Sparse-op-defs.h (SPARSE_SMSM_CMP_OPS): Duplicate code for scalar
--- a/liboctave/oct-inttypes.h	Mon Oct 06 21:06:05 2008 -0400
+++ b/liboctave/oct-inttypes.h	Tue Oct 07 15:28:45 2008 +0200
@@ -987,7 +987,7 @@
   template <> \
   inline octave_uint64 \
   operator OP (const double& x, const octave_uint64& y) \
-  { return octave_int64 (x OP static_cast<long double> (y.value ())); } \
+  { return octave_uint64 (x OP static_cast<long double> (y.value ())); } \
   template <> \
   inline octave_int64 \
   operator OP (const octave_int64& x, const double& y) \
@@ -995,7 +995,7 @@
   template <> \
   inline octave_uint64 \
   operator OP (const octave_uint64& x, const double& y) \
-  { return octave_int64 (static_cast<long double> (x.value ()) OP y); }
+  { return octave_uint64 (static_cast<long double> (x.value ()) OP y); }
 
 #else
 // external handlers