tools/pas2c/PascalParser.hs
changeset 11403 c3a535886806
parent 11361 210f12d36822
child 14240 3a9e4f35aa68
equal deleted inserted replaced
11402:a7efecf4f49f 11403:c3a535886806
   237     try $ rangeft
   237     try $ rangeft
   238     , iD >>= return . Range
   238     , iD >>= return . Range
   239     ] <?> "range declaration"
   239     ] <?> "range declaration"
   240     where
   240     where
   241     rangeft = do
   241     rangeft = do
   242     e1 <- initExpression
   242         e1 <- initExpression
   243     string' ".."
   243         string' ".."
   244     e2 <- initExpression
   244         e2 <- initExpression
   245     return $ RangeFromTo e1 e2
   245         return $ RangeFromTo e1 e2
   246 
   246 
   247 typeVarDeclaration :: Bool -> Parsec String u [TypeVarDeclaration]
   247 typeVarDeclaration :: Bool -> Parsec String u [TypeVarDeclaration]
   248 typeVarDeclaration isImpl = (liftM concat . many . choice) [
   248 typeVarDeclaration isImpl = (liftM concat . many . choice) [
   249     varSection,
   249     varSection,
   250     constSection,
   250     constSection,