Skip to content

Program_With_Side_Effects: cannot parse task instance

apparently, the pretty printer sometimes eats a space after semi-colon, and the resulting ++;++ cannot be parsed

ghci> fmap toDoc $ parse (reader @(Program Statement, Environment V.Value)) "<>" "(a++; ++a; , int a = 4;)" 
Right ( a ++;++ a;, int a = 4 ; )

ghci> fmap toDoc $ parse (reader @(Program Statement, Environment V.Value)) "<>" "(a++;++a; , int a = 4;)" 
Left "<>" (line 1, column 7):
unexpected '+'