From c71e860a06b0163fe89d7850ed3e4a8c1fe94dcd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrzej=20Krzemie=C5=84ski?= Date: Mon, 12 Oct 2015 11:14:10 +0200 Subject: [PATCH] fake test for checking build versions --- ...xconfig_HACK_TO_LIST_PREDEFINED_MACROS.cpp | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 test/optional_xconfig_HACK_TO_LIST_PREDEFINED_MACROS.cpp diff --git a/test/optional_xconfig_HACK_TO_LIST_PREDEFINED_MACROS.cpp b/test/optional_xconfig_HACK_TO_LIST_PREDEFINED_MACROS.cpp new file mode 100644 index 0000000..561c843 --- /dev/null +++ b/test/optional_xconfig_HACK_TO_LIST_PREDEFINED_MACROS.cpp @@ -0,0 +1,25 @@ +// Copyright (C) 2015 Andrzej Krzemienski. +// +// Use, modification, and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org/lib/optional for documentation. +// +// You are welcome to contact the author at: +// akrzemi1@gmail.com + +#include "boost/core/lightweight_test.hpp" +#include "boost/optional/detail/optional_config.hpp" + +int main() +{ +#if defined(__GNUC__) + int empty = 0; + BOOST_TEST_EQ(empty, __GNUC__); + BOOST_TEST_EQ(empty, __GNUC_MINOR__); + BOOST_TEST_EQ(empty, __GNUC_PATCHLEVEL__); + BOOST_TEST_EQ(empty, __cplusplus); +#endif + return boost::report_errors(); +}