Fix permanent change of environment when parser fails

I noticed some strange floating point errors that occured due to the failure of the parser. The original precision I was depending on was 14 and with 16 my unit test failed. After some digging this was the best solution I could think of when we don't have try/catch/finally

(btw, to reproduce I had used a variable that was undefined)