Removed recursive function calls in parser