[mlpack-git] master: Undef max first (thabks Joseph for pointing this out). (a120654)

gitdub at big.cc.gt.atl.ga.us gitdub at big.cc.gt.atl.ga.us
Fri Mar 20 06:41:57 EDT 2015


Repository : https://github.com/mlpack/mlpack

On branch  : master
Link       : https://github.com/mlpack/mlpack/compare/b9edf2beec5727efc4492f3f9ad6f8b0c01fb3be...a12065450b76493f4cef2a68d5a1abcf60745ecd

>---------------------------------------------------------------

commit a12065450b76493f4cef2a68d5a1abcf60745ecd
Author: Ryan Curtin <ryan at ratml.org>
Date:   Fri Mar 20 06:41:21 2015 -0400

    Undef max first (thabks Joseph for pointing this out).


>---------------------------------------------------------------

a12065450b76493f4cef2a68d5a1abcf60745ecd
 src/mlpack/core.hpp    | 12 ------------
 src/mlpack/prereqs.hpp | 13 +++++++++++++
 2 files changed, 13 insertions(+), 12 deletions(-)

diff --git a/src/mlpack/core.hpp b/src/mlpack/core.hpp
index 60fd8dc..f0d0532 100644
--- a/src/mlpack/core.hpp
+++ b/src/mlpack/core.hpp
@@ -186,15 +186,3 @@
 #endif
 
 #endif
-
-// Clean up unfortunate Windows preprocessor definitions, even if this file was
-// already included.  Use std::min and std::max!
-#ifdef _WIN32
-  #ifdef min
-    #undef min
-  #endif
-
-  #ifdef max
-    #undef max
-  #endif
-#endif
diff --git a/src/mlpack/prereqs.hpp b/src/mlpack/prereqs.hpp
index 66c8ec8..fb00259 100644
--- a/src/mlpack/prereqs.hpp
+++ b/src/mlpack/prereqs.hpp
@@ -3,6 +3,19 @@
  *
  * The core includes that mlpack expects; standard C++ includes and Armadillo.
  */
+
+// Clean up unfortunate Windows preprocessor definitions, even if this file was
+// already included.  Use std::min and std::max!
+#ifdef _WIN32
+  #ifdef min
+    #undef min
+  #endif
+
+  #ifdef max
+    #undef max
+  #endif
+#endif
+
 #ifndef __MLPACK_PREREQS_HPP
 #define __MLPACK_PREREQS_HPP
 



More information about the mlpack-git mailing list