1 
2 // Copyright Aleksey Gurtovoy 2000-2004
3 //
4 // Distributed under the Boost Software License, Version 1.0.
5 // (See accompanying file LICENSE_1_0.txt or copy at
6 // http://www.boost.org/LICENSE_1_0.txt)
7 //
8 // See http://www.boost.org/libs/mpl for documentation.
9 
10 // $Id$
11 // $Date$
12 // $Revision$
13 
14 #include <boost/mpl/logical.hpp>
15 #include <boost/mpl/bool.hpp>
16 #include <boost/mpl/aux_/test.hpp>
17 
18 struct unknown;
19 
20 using mpl::true_;
21 using mpl::false_;
22 
MPL_TEST_CASE()23 MPL_TEST_CASE()
24 {
25     MPL_ASSERT(( mpl::and_< true_,true_ > ));
26     MPL_ASSERT_NOT(( mpl::and_< false_,true_ > ));
27     MPL_ASSERT_NOT(( mpl::and_< true_,false_ > ));
28     MPL_ASSERT_NOT(( mpl::and_< false_,false_ > ));
29     MPL_ASSERT_NOT(( mpl::and_< false_,unknown > ));
30     MPL_ASSERT_NOT(( mpl::and_< false_,unknown,unknown > ));
31 
32     MPL_ASSERT(( mpl::or_< true_,true_ > ));
33     MPL_ASSERT(( mpl::or_< false_,true_ > ));
34     MPL_ASSERT(( mpl::or_< true_,false_ > ));
35     MPL_ASSERT_NOT(( mpl::or_< false_,false_ > ));
36     MPL_ASSERT(( mpl::or_< true_,unknown > ));
37     MPL_ASSERT(( mpl::or_< true_,unknown,unknown > ));
38 
39     MPL_ASSERT_NOT(( mpl::not_< true_ > ));
40     MPL_ASSERT(( mpl::not_< false_ > ));
41 }
42