<div dir="ltr"><div><div>I think Scala has this optional laziness too.<br></div>The problem with default-strictness is that libraries that are built with no laziness in mind turn up to be too strict.<br></div>Going from lazy to strict is possible in the client side, but the other way is impossible.<br>

<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/8/22 Tom Ellis <span dir="ltr">&lt;<a href="mailto:tom-lists-haskell-cafe-2013@jaguarpaw.co.uk" target="_blank">tom-lists-haskell-cafe-2013@jaguarpaw.co.uk</a>&gt;</span><br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On Thu, Aug 22, 2013 at 12:51:24PM -0300, Thiago Negri wrote:<br>
&gt; How hard would it be to lift strictness annotations to type-level? E.g.<br>
&gt; instead of<br>
&gt; f :: Int -&gt; Int<br>
&gt; f !x = x + 1<br>
&gt; write<br>
&gt; f :: !Int -&gt; Int<br>
&gt; f x = x + 1<br>
&gt; which would have the same effect. At least it would be transparent to the<br>
&gt; developer using a particular function.<br>
<br>
</div>See also the recent Reddit thread<br>
<br>
    <a href="http://www.reddit.com/r/haskell/comments/1ksu0v/reasoning_about_space_leaks_with_space_invariants/cbsac5m" target="_blank">http://www.reddit.com/r/haskell/comments/1ksu0v/reasoning_about_space_leaks_with_space_invariants/cbsac5m</a><br>


<br>
where I and others considered the possibility of a strict language with<br>
explicit thunk datatype.  NB OCaml essentially already has this<br>
<br>
    <a href="http://caml.inria.fr/pub/docs/manual-ocaml/libref/Lazy.html" target="_blank">http://caml.inria.fr/pub/docs/manual-ocaml/libref/Lazy.html</a><br>
<br>
but I think Haskellers would do it better because we have a lot of<br>
experience with purity, laziness and monad and comonad transformers.<br>
<br>
Tom<br>
<br>
_______________________________________________<br>
Haskell-Cafe mailing list<br>
<a href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>
<a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br>
</blockquote></div><br></div>