Fix a bug in the parser on 'begin' lines