System

The plain source file for module System is not available.
module System where
import Prelude

foreign import system :: String -> IO ExitCode
foreign import progLine :: [String]
foreign import getEnv :: String -> IO String


data ExitCode = ExitSuccess | ExitFailure Int deriving (Eq,Ord,Show,Read)
--instance Show ExitCode

getArgs :: IO [String]
getProgName :: IO String

getArgs = return progArgs
getProgName = return progName

exitWith :: ExitCode -> IO a
exitWith e = error ("exithWith "++show e)

exitFailure :: IO a
exitFailure = exitWith (ExitFailure 1) -- system dependent...

progName:progArgs=progLine

Index

(HTML for this module was generated on 2005-02-11. About the conversion tool.)