Portability | portable |
---|---|
Stability | experimental |
Maintainer | joost.visser@di.uminho.pt |
Safe Haskell | None |
Data.ATerm.IO
Description
This module is part of the ATerm library for Haskell. This module provides wrapper functions that take care of IO.
- atermIOwrap :: (ATermConvertible t, ATermConvertible a) => ProgramName -> (t -> IO a) -> IO ()
- type ProgramName = String
- dehyphen :: String -> String
- dehyphenAST :: ATerm -> ATerm
- dehyphenUnquoted :: [Char] -> [Char]
- headToUpper :: String -> String
- afunCap :: ATerm -> ATerm
- data OptionsATermIO = OptionsATermIO {}
- defaultOptionsATermIO :: OptionsATermIO
- parseOptions :: String -> [String] -> OptionsATermIO
- usage :: String -> String
Transformation wrapper
atermIOwrap :: (ATermConvertible t, ATermConvertible a) => ProgramName -> (t -> IO a) -> IO ()Source
Wrapper function to create a main function in the IO monad, given a program name and a monadic transformation function.
Helpers
type ProgramName = StringSource
dehyphenAST :: ATerm -> ATermSource
Turn hyphens in AST into underscores except inside nodes that represent literals.
dehyphenUnquoted :: [Char] -> [Char]Source
Turn hyphens in unquoted literal into underscores.
headToUpper :: String -> StringSource
Turn the first character into upper case.
Option handling
data OptionsATermIO Source
parseOptions :: String -> [String] -> OptionsATermIOSource