Sacado Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Sacado_mpl_disable_if.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Sacado Package
4 //
5 // Copyright 2006 NTESS and the Sacado contributors.
6 // SPDX-License-Identifier: LGPL-2.1-or-later
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef SACADO_MPL_DISABLE_IF_HPP
11 #define SACADO_MPL_DISABLE_IF_HPP
12 
13 namespace Sacado {
14 
15  namespace mpl {
16 
17  template <bool, typename T = void>
18  struct disable_if_c {};
19 
20  template <typename T>
21  struct disable_if_c<false, T> {
22  typedef T type;
23  };
24 
25  template <class Cond, typename T = void>
26  struct disable_if
27  : disable_if_c<Cond::value, T> {};
28 
29  template <bool, typename T = void>
30  struct lazy_disable_if_c {};
31 
32  template <typename T>
34  typedef typename T::type type;
35  };
36 
37  template <class Cond, typename T = void>
39  : lazy_disable_if_c<Cond::value, T> {};
40 
41  }
42 
43 }
44 
45 #endif // SACADO_MPL_DISABLE_IF_HPP
#define T
Definition: Sacado_rad.hpp:553
expr expr expr bar false