Quantcast
Channel: Cpp11 – On C++ and other OOPscenities
Viewing all articles
Browse latest Browse all 23

C++11: ‘decltype’

0
0
decltype is a new keyword that infers the type of a given expression. Though it can be used instead of auto; it is used mainly on return types. For example; this function: could be written using decltype: The compiler evaluates ‘a+b’ and infers the type of such expression is ‘int’ and defines ‘ret’ as an… Continue reading C++11: ‘decltype’

Viewing all articles
Browse latest Browse all 23

Latest Images

Trending Articles





Latest Images