module Language.Futhark.Parser
( parseFuthark
, parseExp
, parseModExp
, parseType
, parseValue
, parseValues
, parseDecOrExpIncrM
, ParseError (..)
, scanTokensText
, L(..)
, Token(..)
)
where
import qualified Data.Text as T
import Language.Futhark.Syntax
import Language.Futhark.Attributes
import Language.Futhark.Parser.Parser
import Language.Futhark.Parser.Lexer
parseFuthark :: FilePath -> T.Text
-> Either ParseError UncheckedProg
parseFuthark = parse prog
parseExp :: FilePath -> T.Text
-> Either ParseError UncheckedExp
parseExp = parse expression
parseModExp :: FilePath -> T.Text
-> Either ParseError (ModExpBase NoInfo Name)
parseModExp = parse modExpression
parseType :: FilePath -> T.Text
-> Either ParseError UncheckedTypeExp
parseType = parse futharkType
parseValue :: FilePath -> T.Text
-> Either ParseError Value
parseValue = parse anyValue
parseValues :: FilePath -> T.Text
-> Either ParseError [Value]
parseValues = parse anyValues