> I don't see the point in universally quantifying over types which are<br>
already present in the environment<br><br>I think it reduces the indeterminacy you come across when you read your program ("where does this type variable come from, btw?")<br><br>> So is there anyway to "force" the scoping of variables, so that<br>
> f :: a -> a<br>
> f x = x :: a<br>> becomes valid?<br>
<br>You mean either than compiling with ScopedTypeVariables and adding the explicit forall a. on f? I don't think.<br><br>2012/1/4 Brandon Allbery <span dir="ltr"><<a href="mailto:allbery.b@gmail.com">allbery.b@gmail.com</a>></span><br>
<div class="im">On Wed, Jan 4, 2012 at 08:41, Yves Parès <span dir="ltr"><<a href="mailto:limestrael@gmail.com" target="_blank">limestrael@gmail.com</a>></span> wrote:<br></div><div class="im"><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div>Would you try:</div><br>f :: a -> a<br>f x = undefined :: a<br>
<br>And tell me if it works? IMO it doesn't.</blockquote><div>> It won't<br></div><div><br>Apparently, Yucheng says it does.<br></div></div>