Brian Hulley wrote:
Dan Piponi wrote:
On 9/25/07, Brian Hulley [EMAIL PROTECTED] wrote:
..
I don't understand what you mean. For example, with the prefix
definition of a function with multiple clauses, the function name at the
start of each clause is already lined up since it must appear
John Wicket wrote:
On 9/24/07, Sam Hughes [EMAIL PROTECTED] wrote:
John Wicket wrote:
I am still in an imperative way of thinking. In this example here; how
would I call putStrLn and then set the function with a value. Eg:
aa :: String - IO ()
aa instr = do
putStrLn abc
putStrLn abc
John Wicket wrote:
I am still in an imperative way of thinking. In this example here; how
would I call putStrLn and then set the function with a value. Eg:
aa :: String - IO ()
aa instr = do
putStrLn abc
putStrLn abc
return 123
--- The error I am getting.
Couldn't match expected
Ryan Ingram wrote:
Prelude let inf = repeat 1
Prelude inf
[1,1,(lots of output until I press ctrl-c),Interrupted.
(I expect this to happen)
Prelude let x = inf
(no output here!)
Prelude :t x
x :: [Integer]
Prelude return inf
[1,1,(lots of output until I press ctrl-c),Interrupted.
(I also expect
Malte Milatz wrote:
Sam Hughes [EMAIL PROTECTED], Sun, 12 Aug 2007 20:12:55 -0400:
[A parser like Parsec, with monad transformers:]
$ darcs get http://samuelhughes.com/darcs/partran/
Is this related in any way to the following GSoC project?
http://code.google.com/soc/2007/haskell
Malte Milatz wrote:
If not using unsafePerformIO, which is usually not what we want, the
monad m in question must incorporate IO. That is, it could be defined
something like (say we want a parser with state):
newtype IOParser tok s a
= IOParser (s - [tok] - IO (s,a))
You