Main.hs revision a79fe3aad8743ea57e473ea5f66a723244cb9c0e
2de19644821c7d76aa76403754f21046f5519db0Eugen Kuksa{- **********************************************************************
$Source$
$Date$
$Revision$
Author: Daniel Pratsch (Last modification by $Author$)
**************************************************************************
-}
{-------------------------------------------------------
testing file for CSP-CASL semantics
--------------------------------------------------------}
module Main where
import CspCASL.Parse_hugo
import CspCASL.SignCSP
import CspCASL.StatAnaCSP
import Common.Lib.Parsec
import System.IO
import System.Environment
import Common.AnnoState
import Common.Result
--run :: Show a => AParser a -> String -> IO ()
run p input
= case (runParser p emptyAnnos "" input) of
Left err -> do { putStr "parse error at "
; print err
}
Right x -> do let Result diags sig = statAna x
sequence $ map (putStrLn . show) diags
print x
print sig
fi :: [String] -> IO()
fi (l:es) = do { c <- readFile l
; run interim c
; fi es
}
fi [] = do putStr ""
main :: IO ()
main = do { les <- getArgs
; fi les
-- ; c <- readFile (head les)
-- ; run cspCaslCSpec c
}