January 23, 2014  Getting the most from Template Argument
Deduction in C++  Let me preface this post by saying that the
rules regarding template argument deduction in C++ are varied
and somewhat complex. I will not attempt to describe them in
their entirety in the confines of this short post. I leave that
cumbersome task to more eloquent and knowledgeable programmers.
That being said, template argument deduction, which has an
unfortunate tendency to be underutilized, is a very useful
feature of the language. For the unfamiliar, C++ function
templates have the ability to determine the types upon which
they are specialized from the types of the arguments passed to
the function. For example:  template<typename T> T
transmogrify(T t){...}  If the above function is called with
transmogrify<char>('a'), everything will work as expected. The
specialization transmogrify<char> accepts an argument of type
char because T = char. However, C++ makes this easier for you.
The compiler can deduce the type. So merely calling