1[#predicate] 2[section Predicate] 3 4A ['predicate] (or unary predicate) is a 5[link metafunction_class template metafunction class] taking one argument and 6returning a [link boxed_value boxed value] of type `bool`. 7 8For example the following predicate checks if its argument is the boxed `char` 9value `x`: 10 11 struct is_x 12 { 13 template <class C> 14 struct apply 15 { 16 static constexpr bool value = (C::value == 'x'); 17 using type = apply; 18 }; 19 20 using type = is_x; 21 }; 22 23[endsect] 24 25