Freehand Io Grammar Analysis [[ non-canonical... ioModule = >>= >>= >>= -- ioASTModule = liftM4 (,,,,) imnports exports defs expr imports: ("import" ".")* -- imports = many (reserv'd "import" >> moduleName >>= impList >>= period >> return (mName, idList) impList: optionMaybe (fColon >> idList) exports: ("export" * ".")? -- exports = optional (between (reserv'd "export") period idList) ]] defs: ( ": " ".")* atom: numbers "'strings'" ('action') ident: * lastAction: "; " lambAction: -> * appAction: * parList: -> * -- action (input) abstraction -- action application ? pAtom: expr: -> * -- action (input) abstraction " -- action application import: ("import" *.)* export: ("export" *.)* reserved:: chan par write terminate