From 4b3118ed2bac5abc406d6cb7c8f6d3bbd2baccde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Br=C3=B6nnimann?= Date: Fri, 23 Jul 2004 17:17:37 +0000 Subject: [PATCH] Added BOOST_EXPLICIT_TEMPLATE_TYPE(Value) to fix MSVC (thanks to Joaquin Munoz) [SVN r23998] --- minmax/test/minmax_element_test.cpp | 8 +++++--- minmax/test/minmax_test.cpp | 4 ++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/minmax/test/minmax_element_test.cpp b/minmax/test/minmax_element_test.cpp index 9ea4e13..7d333f7 100644 --- a/minmax/test/minmax_element_test.cpp +++ b/minmax/test/minmax_element_test.cpp @@ -1,4 +1,3 @@ -#include /* prevents some nasty warns in MSVC */ #include #include #include @@ -8,6 +7,7 @@ #include #include +#include /* prevents some nasty warns in MSVC */ #include #include #include @@ -174,7 +174,9 @@ void test_minmax(CIterator first, CIterator last, int n) } template -void test_container(Iterator first, Iterator last, int n, Container* dummy = 0 ) +void test_container(Iterator first, Iterator last, int n, + Container* dummy = 0 + BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE(Value) ) { Container c(first, last); test_minmax(c.begin(), c.end(), n); @@ -191,7 +193,7 @@ void test_range(Iterator first, Iterator last, int n) } template -void test(int n) +void test(int n BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE(Value)) { // Populate test vector with identical values std::vector test_vector(n, Value(1)); diff --git a/minmax/test/minmax_test.cpp b/minmax/test/minmax_test.cpp index 0784950..aae7eda 100644 --- a/minmax/test/minmax_test.cpp +++ b/minmax/test/minmax_test.cpp @@ -1,7 +1,7 @@ #include #include -#include +#include #include #include @@ -40,7 +40,7 @@ private: }; template -void test() +void test(BOOST_EXPLICIT_TEMPLATE_TYPE(Value)) { using namespace boost; Value zero(0), one(1);