From f25c106ddaa1580ec0298297ba7c2730c01545d7 Mon Sep 17 00:00:00 2001 From: Aleksey Gurtovoy Date: Mon, 20 Nov 2006 18:02:17 +0000 Subject: [PATCH] Merge Borland 5.8.2 fixes from RC_1_34_0 [SVN r36117] --- test/integral_wrapper_test.hpp | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/test/integral_wrapper_test.hpp b/test/integral_wrapper_test.hpp index 4ef47c9..16fb31f 100644 --- a/test/integral_wrapper_test.hpp +++ b/test/integral_wrapper_test.hpp @@ -1,5 +1,5 @@ -// Copyright Aleksey Gurtovoy 2001-2004 +// Copyright Aleksey Gurtovoy 2001-2006 // // Distributed under the Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt or copy at @@ -28,6 +28,21 @@ /**/ #endif +#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x582)) +// agurt 20/nov/06: see http://article.gmane.org/gmane.comp.lib.boost.devel/151065 +#define INTEGRAL_WRAPPER_TEST(unused1, i, T) \ + { \ + typedef WRAPPER(T,i) borland_tested_type; \ + { typedef is_same< borland_tested_type::value_type, T > borland_test_type; \ + MPL_ASSERT(( borland_test_type )); } \ + { MPL_ASSERT(( is_same< borland_tested_type::type, WRAPPER(T,i) > )); } \ + { MPL_ASSERT(( is_same< next< borland_tested_type >::type, WRAPPER(T,i+1) > )); } \ + { MPL_ASSERT(( is_same< prior< borland_tested_type >::type, WRAPPER(T,i-1) > )); } \ + { MPL_ASSERT_RELATION( (borland_tested_type::value), ==, i ); } \ + INTEGRAL_WRAPPER_RUNTIME_TEST(i, T) \ + } \ +/**/ +#else #define INTEGRAL_WRAPPER_TEST(unused1, i, T) \ { MPL_ASSERT(( is_same< WRAPPER(T,i)::value_type, T > )); } \ { MPL_ASSERT(( is_same< WRAPPER(T,i)::type, WRAPPER(T,i) > )); } \ @@ -36,3 +51,5 @@ { MPL_ASSERT_RELATION( (WRAPPER(T,i)::value), ==, i ); } \ INTEGRAL_WRAPPER_RUNTIME_TEST(i, T) \ /**/ +#endif +