From 2c9df6a693a1c36c24123e21caa4f8be28dc2d40 Mon Sep 17 00:00:00 2001 From: Aleksey Gurtovoy Date: Mon, 14 Oct 2002 21:13:54 +0000 Subject: [PATCH] logical_and fix [SVN r15926] --- include/boost/mpl/contains.hpp | 2 +- test/contains.cpp | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 test/contains.cpp diff --git a/include/boost/mpl/contains.hpp b/include/boost/mpl/contains.hpp index 828076c..0a75697 100644 --- a/include/boost/mpl/contains.hpp +++ b/include/boost/mpl/contains.hpp @@ -19,7 +19,7 @@ #include "boost/mpl/begin_end.hpp" #include "boost/mpl/find.hpp" -#include "boost/mpl/logical_not.hpp" +#include "boost/mpl/logical/not.hpp" #include "boost/mpl/aux_/void_spec.hpp" #include "boost/mpl/aux_/lambda_support.hpp" #include "boost/type_traits/is_same.hpp" diff --git a/test/contains.cpp b/test/contains.cpp new file mode 100644 index 0000000..e8bc169 --- /dev/null +++ b/test/contains.cpp @@ -0,0 +1,31 @@ +//----------------------------------------------------------------------------- +// boost mpl/test/contains.cpp source file +// See http://www.boost.org for updates, documentation, and revision history. +//----------------------------------------------------------------------------- +// +// Copyright (c) 2000-02 +// Aleksey Gurtovoy +// +// Permission to use, copy, modify, distribute and sell this software +// and its documentation for any purpose is hereby granted without fee, +// provided that the above copyright notice appears in all copies and +// that both the copyright notice and this permission notice appear in +// supporting documentation. No representations are made about the +// suitability of this software for any purpose. It is provided "as is" +// without express or implied warranty. + +#include "boost/mpl/contains.hpp" +#include "boost/mpl/list.hpp" +#include "boost/static_assert.hpp" + +namespace mpl = boost::mpl; + +int main() +{ + typedef mpl::list::type types; + + BOOST_STATIC_ASSERT((mpl::contains< types,short >::type::value)); + BOOST_STATIC_ASSERT((!mpl::contains< types,unsigned >::type::value)); + + return 0; +}