3-phase PV router
Loading...
Searching...
No Matches
integral_constant.hpp
Go to the documentation of this file.
1// ArduinoJson - https://arduinojson.org
2// Copyright © 2014-2023, Benoit BLANCHON
3// MIT License
4
5#pragma once
6
7template< typename T, T v >
9{
10 static constexpr T value = v;
11 using value_type = T;
12 using type = integral_constant; // using injected-class-name
13 constexpr operator value_type() const noexcept
14 {
15 return value;
16 }
17 constexpr value_type operator()() const noexcept
18 {
19 return value;
20 } // since c++14
21};
22
integral_constant< bool, true > true_type
integral_constant< bool, false > false_type
constexpr value_type operator()() const noexcept
static constexpr T value