On 23/08/12, Brent Yorgey <byorgey@seas.upenn.edu> wrote:
fun1 returns 8 for all inputs. The fact that fun1's definition uses
the name 'constant' which happens to have the same name as something
in scope is irrelevant. For example, this is precisely the same as the above:
constant :: Int
constant = 1
fun1 :: Int -> Int
fun1 foo = 8
-Brent
Yes, I am aware the semantics of Haskell is this situation.
I also know for every model of a subclass there must exist a model of the super-class.
I am just not sure whether there is a model expansion from the super-class model to the subclass model.
I am also unsure of the morphism from type variables in the class definition to actual types in instances and to the operations in the instance.
In a intuitive way I think that I understand these things, but not in a model theoretic way.
Thanks,
Pat