Here is my code so far: http://hpaste.org/86353 . I'm building w/ GHC on Windows.
The code above produces the following output on my test file:
parse error at (line 3, column 5):
unexpected " "
expecting "{", "if" or identifier
Here is my test input:
{ if 9 < 3 then
{
a(); b() c()
d()
}else if 2 < 1{if 3 > 2 { }}}
I have not been able to find out why the space after the expression frustrates parsec so much. If I remove the semi-colon after either a() or b() then parsec will complain about the first letter of the next call (ie: b or c). If I add the semi-colon back in, parsec complains about the space. No spaces between any calls, semi-colons after a() and b() but no semi-colon after c() causes the program to parse correctly. Same test except with a semi-colon after c() causes "unexpected \n".
Any hints?