John Meacham wrote:
actually, the rules are pretty straightforward. It doesn't matter where
something is bound, just _how_ it is bound. Let-bound names (which
includes 'where' and top-level definitions) can be polymorphic.
lambda-bound or case-bound names (names bound as an argument to a
function or that appear in a pattern) can only be monomorphic. And
that's all there is to it. (the monomorphism restriction complicates it
a little, but we don't need to worry about that for now)

That seems simple enough (although problematic to implement). However, the Report seems to say that it matters whether or not the bindings are muturally recursive [but I'm not sure precisely *how* it matters...]

_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to