#ifndef KGR_KANGARU_INCLUDE_KANGARU_PREDICATE_HPP #define KGR_KANGARU_INCLUDE_KANGARU_PREDICATE_HPP #include "type_id.hpp" namespace kgr { struct All { constexpr inline bool operator()(type_id_t) const { return true; } }; template struct NoneOf { constexpr bool operator()(type_id_t id) const { return !compare, type_id...>(id); } private: template constexpr bool compare(type_id_t id) const { return id == comp && compare(id); } template constexpr bool compare(type_id_t id) const { return id == comp; } }; template struct AnyOf { constexpr bool operator()(type_id_t id) const { return compare, type_id...>(id); } private: template constexpr bool compare(type_id_t id) const { return id == comp && compare(id); } template constexpr bool compare(type_id_t id) const { return id == comp; } }; } // namespace kgr #endif // KGR_KANGARU_INCLUDE_KANGARU_PREDICATE_HPP