Replace std::function with yang::Function.

C++ and Yang functions are now completely interchangeble. In particular,
the Context accepts yang::Function instead of std::function. This
required some massaging of the reference-counting and a way to express
yang::Function objects with dynamic type.