How can I find out what type the compiler deduced when using the auto keyword?
Example 1: Simpler
auto tickTime = 0.001;
W
A low tech solution is hover the mouse over nextTickTime which in some GUIs gives the type else set a . after nextTickTime in the cout and select a reasonable looking value or function.
In general if You know what type You get use auto if you don't know it don't use it. Which is a bit counter intuitive.
So if you know its a interator just use auto to reduce the incantations, if the result is some unknown type you have to find out what it is before using auto.
See also Herb, Andrei and Scott discussing auto