On Fri, Sep 3, 2010 at 5:26 PM, Ian Lynagh <span dir="ltr">&lt;<a href="mailto:igloo@earth.li">igloo@earth.li</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

<div class="im">On Tue, Aug 31, 2010 at 03:07:41PM +0200, Johan Tibell wrote:<br>
&gt; Ticket: <a href="http://hackage.haskell.org/trac/ghc/ticket/4280" target="_blank">http://hackage.haskell.org/trac/ghc/ticket/4280</a><br>
<br>
</div>&gt; -size t<br>
&gt; -  = case t of<br>
&gt; -      Tip          -&gt; 0<br>
&gt; -      Bin sz _ _ _ -&gt; sz<br>
&gt; +size = go<br>
&gt; +  where<br>
&gt; +    go Tip            = 0<br>
&gt; +    go (Bin sz _ _ _) = sz<br>
&gt; +{-# INLINE size #-}<br>
<br>
Perhaps just<br>
<br>
    size Tip            = 0<br>
    size (Bin sz _ _ _) = sz<br>
<br>
would suffice  :-)<br></blockquote><div><br>Yes, you&#39;re right. This function doesn&#39;t actually benefit from W/W as it doesn&#39;t have any higher-order arguments, dictionaries or polymorphic arguments.<br><br>I will take a second pass over all the code after the proposal period is over. With fresh eyes I might be able to spot more things that could be fixed/improved.<br>

<br></div></div>