Different fix for the dangling else problem in parser.