diff options
| -rw-r--r-- | Foo.hs | 9 | ||||
| -rw-r--r-- | HsBot.hs | 15 | ||||
| -rw-r--r-- | Makefile | 5 |
3 files changed, 14 insertions, 15 deletions
@@ -0,0 +1,9 @@ +-- Karmabot By Paul C. Buetow + +module Main (main) where + +import Control.Monad.State +import IO + +main = return $ "hello" + @@ -2,8 +2,7 @@ module Main (main) where -import Control.Monad (forM) ---import Control.Monad.State +import Control.Monad.State import IO import Monad import Random @@ -121,18 +120,6 @@ readline = do _ -> putStrLn "" -newtype Transformator a = Transformator { execTransformator :: (a, Conf) } - -runTransformator = execTransformator -record s = Transformator ([s], ()) - -instance Monad Transformator where - return c = Transformator ([], c) - c >>= f = let (s, c') = execTransformator c - s' = f s - in Transformator (s', c') - - main :: IO () main = putStrLn "Good bye" @@ -1,6 +1,9 @@ all: ghc HsBot.hs -o hsbot - test: all ./hsbot +foo: + ghc Foo.hs -o foo +test: foo + ./foo |
