Added a load of namespace resolution fixes. Function resolution is now much more explicit when a function cannot be resolved ( Reason why, namespace info etcetera. )