From: Marcin 'Qrczak' Kowalczyk <[EMAIL PROTECTED]>

   John Hughes <[EMAIL PROTECTED]> writes:

By the way, you leave out a lot of type signatures too. Your Djinn
module contains 29 declarations with type signatures--and 17
without. The 17 are local, but local declarations are precisely
those where, without the M-R, a lack of sharing would be most likely
to bite.

Local definitions are rarely used polymorphically.

Perhaps without a type signature the definition should be polymorphic
and recomputed if it's global, and monomorphic and shared if it's local.

Probably this is normally what you want--but oh, how confusing it would be!
I'd like to be able to give a simple answer to the question "Is this binding shared
or not?", not an answer that begins with "Is there a type signature?", "What
does the type signature look like?", and "Is it local or global?"!

This would open for very confusing behaviour when refactoring code, to move
bindings between top-level and a local scope.

John


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

Reply via email to