On Mon, Sep 5, 2011 at 10:19 PM, Thomas Schilling <span dir="ltr">&lt;<a href="mailto:nominolo@googlemail.com">nominolo@googlemail.com</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>a &gt;&gt;= \p -&gt; f &lt;$&gt; b -- &#39;free p&#39; and &#39;free b&#39; disjoint</div>
<div> --&gt;</div><div>((\p -&gt; f) &lt;$&gt; a) &lt;*&gt; b</div></div></blockquote>

<div><br></div></div><div>Will there also be an optimisation for some sort of simple patterns?  I.e., where we could rewrite this to: </div><div><br></div><div>  liftA2 (\pa pb -&gt; f ...) a b</div><div><br></div><div>I think I remember someone saying that the one-at-a-time application of &lt;*&gt; inhibits certain optimisations.</div>
</div></div></blockquote><div><br></div><div>liftA2 is defined via one-at-a-time application and cannot be redefined because it is no method of Applicative. Do you remember more details?</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div class="gmail_quote"><div>I find (a &lt;&lt; b) confusing.  The intended semantics seem to be &quot;effect a&quot;, then &quot;effect b&quot;, return result of &quot;a&quot;.  </div></div></div></blockquote><div>
<br></div><div>Sorry, I didn&#39;t know that &lt;&lt; doesn&#39;t exist. I meant an operator with the meaning of &lt;* .</div><div><br></div><div>Sebastian</div></div>