Modified the semantic analyzer to provide better information to the tree