changeset 9941:1369f13ae6b2

several fixes by M. Goffioul
author Jaroslav Hajek <highegg@gmail.com>
date Tue, 08 Dec 2009 12:45:58 +0100
parents 1707df259536
children 314d2234b660
files liboctave/Array-d.cc liboctave/Array-f.cc liboctave/ChangeLog liboctave/lo-sysdep.cc src/ChangeLog src/gl-render.h src/oct-stream.cc src/ov-ch-mat.cc
diffstat 8 files changed, 27 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/Array-d.cc	Mon Dec 07 21:46:12 2009 +0100
+++ b/liboctave/Array-d.cc	Tue Dec 08 12:45:58 2009 +0100
@@ -87,6 +87,7 @@
 // The default solution using NaN-safe comparator is OK, but almost twice as
 // slow than this code.
 template <>
+OCTAVE_API
 sortmode
 Array<double>::is_sorted (sortmode mode) const
 {
--- a/liboctave/Array-f.cc	Mon Dec 07 21:46:12 2009 +0100
+++ b/liboctave/Array-f.cc	Tue Dec 08 12:45:58 2009 +0100
@@ -87,6 +87,7 @@
 // The default solution using NaN-safe comparator is OK, but almost twice as
 // slow than this code.
 template <>
+OCTAVE_API
 sortmode
 Array<float>::is_sorted (sortmode mode) const
 {
--- a/liboctave/ChangeLog	Mon Dec 07 21:46:12 2009 +0100
+++ b/liboctave/ChangeLog	Tue Dec 08 12:45:58 2009 +0100
@@ -1,3 +1,9 @@
+2009-12-08  Michael Goffioul  <michael.goffioul@gmail.com>
+
+	* Array-d.cc (Array<double>::is_sorted): Declare as OCTAVE_API.
+	* Array-f.cc (Array<float>::is_sorted): Ditto.
+	* lo-sysdep.cc: Undef min and max after including windows.h
+
 2009-12-05  Jaroslav Hajek  <highegg@gmail.com>
 
 	* Array-d.cc (Array<double>::is_sorted): Optimized specialization.
--- a/liboctave/lo-sysdep.cc	Mon Dec 07 21:46:12 2009 +0100
+++ b/liboctave/lo-sysdep.cc	Tue Dec 08 12:45:58 2009 +0100
@@ -41,6 +41,10 @@
 
 #if defined (__WIN32__) && ! defined (__CYGWIN__)
 #include <windows.h>
+#ifdef max
+# undef min
+# undef max
+#endif
 #endif
 
 #include "file-ops.h"
--- a/src/ChangeLog	Mon Dec 07 21:46:12 2009 +0100
+++ b/src/ChangeLog	Tue Dec 08 12:45:58 2009 +0100
@@ -1,3 +1,9 @@
+2009-12-08  Michael Goffioul  <michael.goffioul@gmail.com>
+
+	* ov-ch-mat.cc: Add missing #include.
+	* oct-stream.cc (do_read): Simplify.
+	* gl-render.h: Undef min and max after #including windows.h.
+
 2009-12-08  John W. Eaton  <jwe@octave.org>
 
 	* Makefile.am (gendoc.cc): Don't pass $(srcdidr) to mkgendoc.
--- a/src/gl-render.h	Mon Dec 07 21:46:12 2009 +0100
+++ b/src/gl-render.h	Tue Dec 08 12:45:58 2009 +0100
@@ -25,6 +25,10 @@
 
 #ifdef HAVE_WINDOWS_H
 #include <windows.h>
+#ifdef max
+# undef min
+# undef max
+#endif
 #endif
 
 #ifdef HAVE_GL_GL_H
--- a/src/oct-stream.cc	Mon Dec 07 21:46:12 2009 +0100
+++ b/src/oct-stream.cc	Tue Dec 08 12:45:58 2009 +0100
@@ -3175,10 +3175,10 @@
 
   count = 0;
 
-  typename RET_T::element_type elt_zero
-    = typename RET_T::element_type ();
-
-  typename RET_T::element_type *dat = 0;
+  typedef typename RET_T::element_type ELMT;
+  ELMT elt_zero = ELMT ();
+
+  ELMT *dat = 0;
 
   octave_idx_type max_size = 0;
 
--- a/src/ov-ch-mat.cc	Mon Dec 07 21:46:12 2009 +0100
+++ b/src/ov-ch-mat.cc	Tue Dec 08 12:45:58 2009 +0100
@@ -25,6 +25,7 @@
 #include <config.h>
 #endif
 
+#include <cctype>
 #include <iostream>
 
 #include "lo-ieee.h"