From 0414abe3f4cf3bb617b80f2e3fb655b0fd8c1ddb Mon Sep 17 00:00:00 2001 From: Edward Diener Date: Tue, 25 Aug 2020 12:30:10 -0400 Subject: [PATCH] Unbreak Embarcadero C++ clang-based compilers * Change __BORLANDC__ to BOOST_BORLANDC, which is defined in Boost config for the Embarcadero non-clang-based compilers. * Restored a Borland check. * Specify std:: for all standard identifiers and remove 'using namespace std:'. * Removed std:: from C header abort call. * Moved 'using namespace std;' after header file inclusions --- test/parsers_test.cpp | 2 +- test/winmain.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/test/parsers_test.cpp b/test/parsers_test.cpp index 4cf832e..8f01731 100644 --- a/test/parsers_test.cpp +++ b/test/parsers_test.cpp @@ -308,7 +308,7 @@ void test_environment() ("bar", new untyped_value, "") ; -#if (defined(_WIN32) && ! defined(__BORLANDC__)) || (defined(__CYGWIN__)) +#if (defined(_WIN32) && ! defined(BOOST_BORLANDC) && ! defined(BOOST_EMBTC)) || (defined(__CYGWIN__)) _putenv("PO_TEST_FOO=1"); #else putenv(const_cast("PO_TEST_FOO=1")); diff --git a/test/winmain.cpp b/test/winmain.cpp index 0c3512f..20dc9c5 100644 --- a/test/winmain.cpp +++ b/test/winmain.cpp @@ -9,10 +9,9 @@ #include #include #include +#include using namespace std; - -#include using namespace boost::program_options; void check_equal(const std::vector& actual, char **expected, int n)