[<<][compsci][>>][..]
Fri Oct 28 15:04:35 EDT 2011

Type Scoping

Why are these 2 not equivalent?

# as type variables are not the same

  _lambda = lambda where
    lambda :: Args Value as ras =>
              (ras -> Identity (Value t)) -> Value (as -> Identity t)
    lambda f = Value rf where
      rf as = do
        Value t <- f  $ unpack $ Value (as :: as)
        return t

# as types are the same

  _lambda = lambda where
    lambda :: forall as ras t. Args Value as ras =>
              (ras -> Identity (Value t)) -> Value (as -> Identity t)
    lambda f = Value rf where
      rf as = do
        Value t <- f  $ unpack $ Value (as :: as)
        return t




[Reply][About]
[<<][compsci][>>][..]