annotate DEPENDENCIES/generic/include/boost/graph/overloading.hpp @ 133:4acb5d8d80b6 tip

Don't fail environmental check if README.md exists (but .txt and no-suffix don't)
author Chris Cannam
date Tue, 30 Jul 2019 12:25:44 +0100
parents 2665513ce2d3
children
rev   line source
Chris@16 1 // Copyright 2004 The Trustees of Indiana University.
Chris@16 2
Chris@16 3 // Use, modification and distribution is subject to the Boost Software
Chris@16 4 // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
Chris@16 5 // http://www.boost.org/LICENSE_1_0.txt)
Chris@16 6
Chris@16 7 // Authors: Douglas Gregor
Chris@16 8 // Andrew Lumsdaine
Chris@16 9
Chris@16 10 //
Chris@16 11 // This file contains helps that enable concept-based overloading
Chris@16 12 // within the Boost Graph Library.
Chris@16 13 //
Chris@16 14 #ifndef BOOST_GRAPH_OVERLOADING_HPP
Chris@16 15 #define BOOST_GRAPH_OVERLOADING_HPP
Chris@16 16
Chris@16 17 #include <boost/type_traits/is_base_and_derived.hpp>
Chris@16 18 #include <boost/utility/enable_if.hpp>
Chris@16 19
Chris@16 20 namespace boost { namespace graph { namespace detail {
Chris@16 21
Chris@16 22 struct no_parameter {};
Chris@16 23
Chris@16 24 } } } // end namespace boost::graph::detail
Chris@16 25
Chris@16 26 #ifndef BOOST_NO_SFINAE
Chris@16 27
Chris@16 28 #define BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, Type) \
Chris@16 29 typename enable_if_c<(is_base_and_derived< \
Chris@16 30 Tag, \
Chris@16 31 typename graph_traits<Graph>::traversal_category>::value), \
Chris@16 32 Type>::type
Chris@16 33
Chris@16 34 #define BOOST_GRAPH_ENABLE_IF_MODELS_PARM(Graph, Tag) \
Chris@16 35 , BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, \
Chris@16 36 ::boost::graph::detail::no_parameter) \
Chris@16 37 = ::boost::graph::detail::no_parameter()
Chris@16 38
Chris@16 39 #else
Chris@16 40
Chris@16 41 #define BOOST_GRAPH_ENABLE_IF_MODELS(Graph, Tag, Type) Type
Chris@16 42 #define BOOST_GRAPH_ENABLE_IF_MODELS_PARM(Graph, Tag)
Chris@16 43
Chris@16 44 #endif // no SFINAE support
Chris@16 45
Chris@16 46 #endif // BOOST_GRAPH_OVERLOADING_HPP