Merged the internal structures which hold functions and identifiers in scope into a single structure. This has the side effect of not allowing functions and variables with the same names. Also improved error messages which get logged.