Commit d8928de7 authored by unknown's avatar unknown

Make mysql compilable on gcc-4.2.1.

c++config.h now has the following code:
// For example, <windows.h> is known to #define min and max as macros...
#undef min
#undef max

So, our defines in my_global.h are undefined when <new> header
is included.

Move definitions of min()/max() to the end of my_global.h.
parent 50a80f1d
...@@ -562,12 +562,6 @@ int __void__; ...@@ -562,12 +562,6 @@ int __void__;
#define PURIFY_OR_LINT_INIT(var) #define PURIFY_OR_LINT_INIT(var)
#endif #endif
/* Define some useful general macros */
#if !defined(max)
#define max(a, b) ((a) > (b) ? (a) : (b))
#define min(a, b) ((a) < (b) ? (a) : (b))
#endif
#if !defined(HAVE_UINT) #if !defined(HAVE_UINT)
#undef HAVE_UINT #undef HAVE_UINT
#define HAVE_UINT #define HAVE_UINT
...@@ -1508,4 +1502,10 @@ inline void operator delete[](void*, void*) { /* Do nothing */ } ...@@ -1508,4 +1502,10 @@ inline void operator delete[](void*, void*) { /* Do nothing */ }
/* Length of decimal number represented by INT64. */ /* Length of decimal number represented by INT64. */
#define MY_INT64_NUM_DECIMAL_DIGITS 21 #define MY_INT64_NUM_DECIMAL_DIGITS 21
/* Define some useful general macros (should be done after all headers). */
#if !defined(max)
#define max(a, b) ((a) > (b) ? (a) : (b))
#define min(a, b) ((a) < (b) ? (a) : (b))
#endif
#endif /* my_global_h */ #endif /* my_global_h */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment