<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 12 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Verdana","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-GB" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Fair point.&nbsp; So you are saying it&#8217;d be ok to say<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp; data T (.-&gt;)&nbsp; = MkT (Int .-&gt; Int)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">where (.&#43;) is a type variable?&nbsp;&nbsp; Leaving ordinary (&#43;) available for type constructors.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">If we are inverting the convention I wonder whether we might invert it completely and use &#8220;:&#8221; as the &#8220;I&#8217;m different&#8221; herald as we do for *<b>constructor</b>*
 operators in terms.&nbsp; Thus<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp; data T (:-&gt;)&nbsp; = MkT (Int :-&gt; Int)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">That seems symmetrical, and perhaps nicer than having a new notation.&nbsp;
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;In terms &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; In types&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">-----------------------------------------------------------------------<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">a &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Term variable &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Type variable<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">A &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Data constructor&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Type constructor<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">&#43;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Term variable operator&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Type constructor operator<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">:&#43;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Data constructor operator&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Type variable operator<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Any other opinions?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Simon<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt">
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;"> conal.elliott@gmail.com [mailto:conal.elliott@gmail.com]
<b>On Behalf Of </b>Conal Elliott<br>
<b>Sent:</b> 06 September 2012 23:59<br>
<b>To:</b> Simon Peyton-Jones<br>
<b>Cc:</b> GHC users<br>
<b>Subject:</b> Re: Type operators in GHC<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal" style="margin-bottom:12.0pt">Oh dear. I'm very sorry to have missed this discussion back in January. I'd be awfully sad to lose pretty infix notation for type variables of kind * -&gt; * -&gt; *. I use them extensively in my libraries and projects,
 and pretty notation matters.<br>
<br>
I'd be okay switching to some convention other than lack of leading ':' for signaling that a symbol is a type variable rather than constructor, e.g., the *presence* of a leading character such as '.'.<br>
<br>
Given the increasing use of arrow-ish techniques and of type-level programming, I would not classify the up-to-7.4 behavior as a &quot;foolish consistency&quot;, especially going forward.<br>
<br>
-- Conal<br>
<br>
<o:p></o:p></p>
<div>
<p class="MsoNormal">On Wed, Jan 18, 2012 at 6:27 AM, Simon Peyton-Jones &lt;<a href="mailto:simonpj@microsoft.com" target="_blank">simonpj@microsoft.com</a>&gt; wrote:<o:p></o:p></p>
<p class="MsoNormal">Dear GHC users<br>
<br>
As part of beefing up the kind system, we plan to implement the &quot;Type operators&quot; proposal for Haskell Prime<br>
<a href="http://hackage.haskell.org/trac/haskell-prime/wiki/InfixTypeConstructors" target="_blank">http://hackage.haskell.org/trac/haskell-prime/wiki/InfixTypeConstructors</a><br>
<br>
GHC has had type operators for some kind, so you can say<br>
&nbsp; &nbsp; &nbsp; &nbsp; data a :&#43;: b = Left a | Right b<br>
but you can only do that for operators which start with &quot;:&quot;.<br>
<br>
As part of the above wiki page you can see the proposal to broaden this to ALL operators, allowing<br>
&nbsp; &nbsp; &nbsp; &nbsp; data a &#43; b = Left a | Right b<br>
<br>
Although this technically inconsistent the value page (as the wiki page discussed), I think the payoff is huge. (And &quot;A foolish consistency is the hobgoblin of little minds&quot;, Emerson)<br>
<br>
<br>
This email is (a) to highlight the plan, and (b) to ask about flags. &nbsp;Our preferred approach is to *change* what -XTypeOperators does, to allow type operators that do not start with :. &nbsp;But that will mean that *some* (strange) programs will stop working. The
 only example I have seen in tc192 of GHC's test suite<br>
&nbsp; &nbsp; &nbsp; &nbsp; {-# LANGUAGE TypeOperators #-}<br>
&nbsp; &nbsp; &nbsp; &nbsp; comp :: Arrow (~&gt;) =&gt; (b~&gt;c, c~&gt;d)~&gt;(b~&gt;d)<br>
&nbsp; &nbsp; &nbsp; comp = arr (uncurry (&gt;&gt;&gt;))<br>
<br>
Written more conventionally, the signature would look like<br>
&nbsp; &nbsp; &nbsp; &nbsp; comp :: Arrow arr =&gt; arr (arr b c, arr c d) (arr b d)<br>
&nbsp; &nbsp; &nbsp; comp = arr (uncurry (&gt;&gt;&gt;))<br>
or, in infix notation<br>
&nbsp; &nbsp; &nbsp; &nbsp; {-# LANGUAGE TypeOperators #-}<br>
&nbsp; &nbsp; &nbsp; &nbsp; comp :: Arrow arr =&gt; (b `arr` c, c `arr` d) `arr` (b `arr` d)<br>
&nbsp; &nbsp; &nbsp; comp = arr (uncurry (&gt;&gt;&gt;))<br>
<br>
But tc192 as it stands would become ILLEGAL, because (~&gt;) would be a type *constructor* rather than (as now) a type *variable*. &nbsp;Of course it's easily fixed, as above, but still a breakage is a breakage.<br>
<br>
It would be possible to have two flags, so as to get<br>
&nbsp; - Haskell 98 behaviour<br>
&nbsp; - Current TypeOperator behaviuor<br>
&nbsp; - New TypeOperator behaviour<br>
but it turns out to be Quite Tiresome to do so, and I would much rather not. &nbsp;Can you live with that?<br>
<br>
<br>
<a href="http://chrisdone.com/posts/2010-10-07-haskelldb-and-typeoperator-madness.html" target="_blank">http://chrisdone.com/posts/2010-10-07-haskelldb-and-typeoperator-madness.html</a><br>
<br>
<br>
_______________________________________________<br>
Glasgow-haskell-users mailing list<br>
<a href="mailto:Glasgow-haskell-users@haskell.org">Glasgow-haskell-users@haskell.org</a><br>
<a href="http://www.haskell.org/mailman/listinfo/glasgow-haskell-users" target="_blank">http://www.haskell.org/mailman/listinfo/glasgow-haskell-users</a><o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
</div>
</body>
</html>