The following code:
template <typename T>
Foo f = Bar;
Results in the following error message:
error C2440: 'initializing' : cannot convert from 'boost::optional<T> (__cdecl *)(void)' to 'Foo'
No constructor could take the source type, or constructor overload resolution was ambiguous
It compiles successfully under newer versions of gcc. VC++2010 doesn't seem to think a function pointer can be a parameter to a function accepting a templated rvalue reference parameter, but this is necessary to implement perfect forwarding.