Am 29.06.2011 um 23:50 schrieb Philipp Schneider:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
i use the monad in two different ways. The type variable a can be a
pair as in
interp :: Term - Environment - M (Value,Environment)
An environment contains local variable bindings, so no subcomputation will
ever need to return its environment.
- That is not true. A subcomputation can possible modify an environment
except the language forbids such a case.
On 06/30/2011 02:36 PM, Holger Siegel wrote:
Am 29.06.2011 um
On 06/30/2011 02:36 PM, Holger Siegel wrote:
Am 29.06.2011 um 23:50 schrieb Philipp Schneider:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
i use the monad in two different ways. The type variable a can be a
pair as in
interp :: Term -
On 06/30/2011 08:25 PM, Philipp Schneider wrote:
On 06/30/2011 02:36 PM, Holger Siegel wrote:
Am 29.06.2011 um 23:50 schrieb Philipp Schneider:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
i use the monad in two different ways. The type
Am 30.06.2011 um 20:23 schrieb Philipp Schneider:
On 06/30/2011 02:36 PM, Holger Siegel wrote:
Am 29.06.2011 um 23:50 schrieb Philipp Schneider:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
i use the monad in two different ways.
On 06/30/2011 09:49 PM, Holger Siegel wrote:
Am 30.06.2011 um 20:23 schrieb Philipp Schneider:
On 06/30/2011 02:36 PM, Holger Siegel wrote:
Am 29.06.2011 um 23:50 schrieb Philipp Schneider:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
Am 30.06.2011 um 22:57 schrieb Philipp Schneider:
On 06/30/2011 09:49 PM, Holger Siegel wrote:
(...) But that won't work: After you have evaluated an entry of the
environment, you store the resulting value but you throw away its updated
environment. That means, you lose the results of all
On 06/30/2011 11:46 PM, Holger Siegel wrote:
Am 30.06.2011 um 22:57 schrieb Philipp Schneider:
On 06/30/2011 09:49 PM, Holger Siegel wrote:
(...) But that won't work: After you have evaluated an entry of the
environment, you store the resulting value but you throw away its updated
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
i use the monad in two different ways. The type variable a can be a
pair as in
interp :: Term - Environment - M (Value,Environment)
and it can be just a value as in
type Environment = [(Name,
Try enabling OverlappingInstances extension by adding this to the top
of the file:
{-# LANGUAGE OverlappingInstances #-}
-deech
On Wed, Jun 29, 2011 at 4:50 PM, Philipp Schneider
philipp.schneid...@gmx.net wrote:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M
Hi Philipp,
On 06/29/2011 11:50 PM, Philipp Schneider wrote:
Hi cafe,
in my program i use a monad of the following type
newtype M a = M (State - (a, State))
btw., it looks like you just rebuilt the State monad.
...
instance (Show a,Show b) = Show (M (a,b)) where
show (M f) = let
Thank you very much, this worked.
On 06/30/2011 12:03 AM, aditya siram wrote:
Try enabling OverlappingInstances extension by adding this to the top
of the file:
{-# LANGUAGE OverlappingInstances #-}
-deech
On Wed, Jun 29, 2011 at 4:50 PM, Philipp Schneider
philipp.schneid...@gmx.net
12 matches
Mail list logo