74 stream <<
"The Address of function: " << get_a_value<&gGlobalInt> <<
endl;
76 stream <<
"The returned value of the function: " << get_a_value<&gGlobalInt>() <<
endl;
94 stream <<
"The value of d = " << get_a_value_using_auto<&d>() <<
endl;
105 stream <<
"The value of d = "
115 using tuple_t = std::tuple<int, double, const char*>;
116 enum:
size_t{age, weight, name};
118 tuple_t person{ 20, 60.0,
"Thomas Kim"};
120 stream <<
"I am " << std::get<name>(person)
121 <<
". I am " << std::get<age>(person)
123 <<
"I weigh " << std::get<weight>(person) <<
" kg." <<
endl;
136 using variant_t = std::variant<int, double, const char*>;
142 stream << std::get<0>(item) <<
endl;
149 auto index = item.index();
void important_concept_for_compile_time_expression()
void test_get_a_value_auto()
void test_const_expression()
auto get_a_value_using_auto()
constexpr size_t get_size()
void test_non_type_template_parameters()
void why_constant_expression_is_misnomer()
Stream output operators << are implemented.