Fixed parsing of while loops

Corrected hard to find typo.