![]() |
C++ Library Extensions 2022.12.09
To help learn modern C++ programming
|
#include <tpf_output.hpp>
Go to the source code of this file.
Classes | |
struct | integral_constant< Type, v > |
struct | is_same< Type_1, Type_2 > |
struct | is_same< Type, Type > |
Typedefs | |
using | true_type = integral_constant< bool, true > |
using | false_type = integral_constant< bool, false > |
Functions | |
double | remainder (double n, double d, double) |
void | test_remainder () |
constexpr bool | is_same_type (true_type) |
constexpr bool | is_same_type (false_type) |
void | test_is_same () |
template<typename RealType > | |
RealType | remainder_impl (RealType n, RealType d, true_type) |
template<typename IntType > | |
IntType | remainder_impl (IntType n, IntType d, false_type) |
template<typename Type > | |
Type | remainder (Type n, Type d) |
void | test_type_dispatch () |
void | test_is_same_v () |
int | main () |
Variables | |
tpf::sstream | stream |
auto | endl = tpf::endl |
template<typename Type_1 , typename Type_2 > | |
constexpr auto | is_same_v = is_same<Type_1, Type_2>::value() |
using false_type = integral_constant<bool, false> |
Definition at line 62 of file 11-type_dispatch.cpp.
using true_type = integral_constant<bool, true> |
Definition at line 61 of file 11-type_dispatch.cpp.
|
constexpr |
Definition at line 89 of file 11-type_dispatch.cpp.
|
constexpr |
int main | ( | ) |
double remainder | ( | double | n, |
double | d, | ||
double | |||
) |
Type remainder | ( | Type | n, |
Type | d | ||
) |
IntType remainder_impl | ( | IntType | n, |
IntType | d, | ||
false_type | |||
) |
Definition at line 112 of file 11-type_dispatch.cpp.
RealType remainder_impl | ( | RealType | n, |
RealType | d, | ||
true_type | |||
) |
void test_is_same | ( | ) |
void test_is_same_v | ( | ) |
void test_remainder | ( | ) |
void test_type_dispatch | ( | ) |
auto endl = tpf::endl |
Definition at line 24 of file 11-type_dispatch.cpp.
|
constexpr |
Definition at line 82 of file 11-type_dispatch.cpp.
tpf::sstream stream |
Definition at line 23 of file 11-type_dispatch.cpp.