tools/pas2c/PascalParser.hs
branchsdl2transition
changeset 11370 210f12d36822
parent 11366 f1b5f1dc61a3
child 11398 c3a535886806
equal deleted inserted replaced
11369:ea5edb4e5245 11370:210f12d36822
   196         comments
   196         comments
   197         u <- parens pas $ varsDecl True
   197         u <- parens pas $ varsDecl True
   198         char' ';'
   198         char' ';'
   199         comments
   199         comments
   200         return u
   200         return u
   201     sequenceDecl = (parens pas) $ (commaSep pas) (iD >>= \i -> optional (spaces >> string' ":=" >> spaces >> integer pas) >> return i)
   201     sequenceDecl = (parens pas) $ (commaSep pas) (iD >>= \i -> optional (spaces >> char' '=' >> spaces >> integer pas) >> return i)
   202     functionType = do
   202     functionType = do
   203         fp <- try (string "function") <|> try (string "procedure")
   203         fp <- try (string "function") <|> try (string "procedure")
   204         comments
   204         comments
   205         vs <- option [] $ parens pas $ varsDecl False
   205         vs <- option [] $ parens pas $ varsDecl False
   206         comments
   206         comments