[prev in list] [next in list] [prev in thread] [next in thread]
List: haskell
Subject: A case in point.
From: Alex Ferguson <abf () cs ! ucc ! ie>
Date: 1999-12-07 20:28:33
Message-ID: 199912030116.BAA17988 () joyce ! ucc ! ie
[Download RAW message or body]
John Atwood:
> You have it right, except you need to
> 1) explicitly type test,
> test:: Reader [Char] Char
José Romildo Malaquias:
> > ---------------
> > test = do env <- ask
> > if env == "choose a"
> > then return 'a'
> > else return 'b'
> >
> > do_test = runReader test "choose a"
The very sort of thing I had in mind when I suggested some explicit
typings would be more concisely expressed by a type-ap.
Slán,
Alex.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic