changeset 294:ed0089b9fe4b octave-forge

max() is not part of the C++ standard, so roll our own
author pkienzle
date Sun, 14 Apr 2002 02:51:47 +0000
parents cc2526f5c33b
children 3b264c1692ea
files main/general/bitand.cc
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/main/general/bitand.cc	Sat Apr 13 13:55:28 2002 +0000
+++ b/main/general/bitand.cc	Sun Apr 14 02:51:47 2002 +0000
@@ -25,7 +25,6 @@
 #include <sys/types.h>
 #include <strstream>
 #include <climits>
-#include <algorithm>
 #include <octave/oct.h>
 #include <octave/lo-ieee.h>
 using namespace std;
@@ -36,6 +35,11 @@
 const unsigned int BIT_OR = 2;
 const unsigned int BIT_XOR = 3;
 
+inline unsigned int 
+max(unsigned int x, unsigned int y) { 
+	return x > y ? x : y; 
+} 
+
 double
 scalar_bitop(double x,double y,unsigned int op) {
 	double a=octave_NaN;