3rdParty/boost/1.78.0/libs/mpl/doc/refmanual/and.html
| Prev Next | Back Along | Up Home | Full TOC | Front Page / Metafunctions / Logical Operations / and_ |
template<
typename F1
, typename F2_..._, typename F_n_=_unspecified_>
struct[and\_](./and.html){
typedef_unspecified_type;
};
Returns the result of short-circuit logical and (&&) operation on its arguments.
#include <[boost/mpl/and.hpp](../../../../boost/mpl/and.hpp)>
#include <[boost/mpl/logical.hpp](../../../../boost/mpl/logical.hpp)>
| Parameter | Requirement | Description |
|---|---|---|
| F1, F2,... Fn | Nullary Metafunction | Operation's arguments. |
For arbitrary nullary Metafunctions f1, f2,... fn:
typedef[and\_](./and.html)<f1,f2,_..._,f_n_>::type r;
| Return type: | Integral Constant. | | Semantics: | r is false_ if either of f1::type::value, f2::type::value,... fn::type::value expressions evaluates to false, and true_ otherwise; guarantees left-to-right evaluation; the operands subsequent to the first f_i_ metafunction that evaluates to false are not evaluated. |
typedef[and\_](./and.html)<f1,f2,_..._,f_n_> r;
| Return type: |
| | Semantics: |
Equivalent to
struct r :[and\_](./and.html)<f1,f2,_..._,f_n_>::type {};
|
struct unknown;[BOOST\_MPL\_ASSERT](./assert.html)(([and\_](./and.html)<[true\_](./bool.html),[true\_](./bool.html)> ));[BOOST\_MPL\_ASSERT\_NOT](./assert-not.html)(([and\_](./and.html)<[false\_](./bool.html),[true\_](./bool.html)> ));[BOOST\_MPL\_ASSERT\_NOT](./assert-not.html)(([and\_](./and.html)<[true\_](./bool.html),[false\_](./bool.html)> ));[BOOST\_MPL\_ASSERT\_NOT](./assert-not.html)(([and\_](./and.html)<[false\_](./bool.html),[false\_](./bool.html)> ));[BOOST\_MPL\_ASSERT\_NOT](./assert-not.html)(([and\_](./and.html)<[false\_](./bool.html),unknown > )); // OK[BOOST\_MPL\_ASSERT\_NOT](./assert-not.html)(([and\_](./and.html)<[false\_](./bool.html),unknown,unknown > )); // OK too
Metafunctions, Logical Operations, or_, not_
| Prev Next | Back Along | Up Home | Full TOC |
Copyright © 2001-2009 Aleksey Gurtovoy and David Abrahams Distributed under 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) |