2011-11-30 00:45:27 +08:00
|
|
|
// -*- C++ -*-
|
2017-06-01 06:07:49 +08:00
|
|
|
//===------------------------ __undef_macros ------------------------------===//
|
2011-11-30 00:45:27 +08:00
|
|
|
//
|
2019-01-19 16:50:56 +08:00
|
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
2011-11-30 00:45:27 +08:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2017-06-01 06:07:49 +08:00
|
|
|
|
2011-11-30 00:45:27 +08:00
|
|
|
#ifdef min
|
2016-07-12 22:39:13 +08:00
|
|
|
#if !defined(_LIBCPP_DISABLE_MACRO_CONFLICT_WARNINGS)
|
2017-05-11 05:40:58 +08:00
|
|
|
#if defined(_LIBCPP_WARNING)
|
2013-11-16 07:41:01 +08:00
|
|
|
_LIBCPP_WARNING("macro min is incompatible with C++. Try #define NOMINMAX "
|
|
|
|
"before any Windows header. #undefing min")
|
2013-10-05 05:14:44 +08:00
|
|
|
#else
|
2012-09-04 02:13:11 +08:00
|
|
|
#warning: macro min is incompatible with C++. #undefing min
|
2013-10-05 05:14:44 +08:00
|
|
|
#endif
|
2016-07-12 22:39:13 +08:00
|
|
|
#endif
|
2011-11-30 00:45:27 +08:00
|
|
|
#undef min
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef max
|
2016-07-12 22:39:13 +08:00
|
|
|
#if !defined(_LIBCPP_DISABLE_MACRO_CONFLICT_WARNINGS)
|
2017-05-11 05:40:58 +08:00
|
|
|
#if defined(_LIBCPP_WARNING)
|
2013-11-16 07:41:01 +08:00
|
|
|
_LIBCPP_WARNING("macro max is incompatible with C++. Try #define NOMINMAX "
|
|
|
|
"before any Windows header. #undefing max")
|
2013-10-05 05:14:44 +08:00
|
|
|
#else
|
2012-09-04 02:13:11 +08:00
|
|
|
#warning: macro max is incompatible with C++. #undefing max
|
2013-10-05 05:14:44 +08:00
|
|
|
#endif
|
2016-07-12 22:39:13 +08:00
|
|
|
#endif
|
2011-11-30 00:45:27 +08:00
|
|
|
#undef max
|
|
|
|
#endif
|