C++ features by examples
Collaboration diagram for Other:

Functions

void location_20 ()
 source_location More...
 
void functional_20 ()
 

Detailed Description

cor20

TODO:

range-for common_reference

Function Documentation

◆ functional_20()

void functional_20 ( )

functional bind_front

Definition at line 375 of file 20.cpp.

376{
377 auto constexpr plus_one = std::bind_front(std::plus<int>(), 1);
378 static_assert(plus_one(2) == 3);
379}
Here is the caller graph for this function:

◆ location_20()

void location_20 ( )

source_location

Definition at line 362 of file 20.cpp.

363{
364 auto l = experimental::source_location::current();
365 basic_stringstream<char> buff;
366 buff << l.file_name() << ":" << l.line() << ":" << l.column() << l.function_name();
367 assert(buff.str().length());
368}
Here is the caller graph for this function: