| 1 | // -*- C++ -*- |
| 2 | |
| 3 | #ifndef HL_ISTRUE_H |
| 4 | #define HL_ISTRUE_H |
| 5 | |
| 6 | /* |
| 7 | |
| 8 | Heap Layers: An Extensible Memory Allocation Infrastructure |
| 9 | |
| 10 | Copyright (C) 2000-2020 by Emery Berger |
| 11 | http://www.emeryberger.com |
| 12 | [email protected] |
| 13 | |
| 14 | Heap Layers is distributed under the terms of the Apache 2.0 license. |
| 15 | |
| 16 | You may obtain a copy of the License at |
| 17 | http://www.apache.org/licenses/LICENSE-2.0 |
| 18 | |
| 19 | */ |
| 20 | |
| 21 | namespace HL { |
| 22 | |
| 23 | template <bool isTrue> |
| 24 | class IsTrue; |
| 25 | |
| 26 | template<> |
| 27 | class IsTrue<true> { |
| 28 | public: |
| 29 | enum { value = true }; |
| 30 | }; |
| 31 | |
| 32 | template<> |
| 33 | class IsTrue<false> { |
| 34 | public: |
| 35 | enum { value = false }; |
| 36 | }; |
| 37 | |
| 38 | } |
| 39 | |
| 40 | #endif |