Get type of
Returns type of identifier. Checks current scope and recursively traverses up the tree till the global scope.