diff --git a/include/wx/valnum.h b/include/wx/valnum.h index 166206138d..540f9d6b82 100644 --- a/include/wx/valnum.h +++ b/include/wx/valnum.h @@ -18,6 +18,12 @@ #include "wx/textentry.h" #include "wx/validate.h" +// This header uses std::numeric_limits<>::min/max, but these symbols are, +// unfortunately, often defined as macros and the code here wouldn't compile in +// this case, so preventively undefine them to avoid this problem. +#undef min +#undef max + #include // Bit masks used for numeric validator styles.