<div dir="ltr"><div>I'm still in favour of Option (X), reject the proposal, for the same reasons as before (copied below).<br></div><div><br></div><div>I think it was Cale who first proposed rejection: <a href="https://github.com/ghc-proposals/ghc-proposals/pull/302#issuecomment-666075014">https://github.com/ghc-proposals/ghc-proposals/pull/302#issuecomment-666075014</a></div><div><br></div><div>My previous email on this, although it talks about \of, applies equally to \case and \cases: </div><div><br></div><div>> Cale's rationale chimes with me. A lot - I feel like I might have even made the same point in previous threads on this. I think of the tradeoff like this:<br><br>> * The lack of \of doesn't really hurt very much. In fact, arguably by forcing the author to type some more characters and give something a name, we get code that's clearer for the reader. (yes this is very subjective, but syntax is).<br>> * The addition of \of *would* hurt new users of the language. Only a bit, but every bit makes things worse, and things are already quite bad.<br></div><div><br></div><div>And I also came across this from Richard during the last thread:<br></div><div><br></div><div>> Even so, I agree with <span class="gmail-il">Cale</span>'s recommendation to reject. We just have too much syntax! If someone were to come along and draft a concrete proposal <span class="gmail-il">of</span>
how we could, for example, use this syntax to replace both \case and
if|, with a migration strategy, etc., then I might be in favor. Until
then, I think we've spent our budget for cute, obscure bits <span class="gmail-il">of</span> syntax.</div><div><br></div><div><br></div><div>Cheers</div><div>Simon</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, 15 Jun 2021 at 13:52, Simon Peyton Jones via ghc-steering-committee <<a href="mailto:ghc-steering-committee@haskell.org" target="_blank">ghc-steering-committee@haskell.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div lang="EN-GB">
<div>
<p>| I’d like to reassing shepherding of this one.<u></u><u></u></p>
<p>| <u></u><u></u></p>
<p>| It seems to be clear that we want “something like this”, there are many ways<u></u><u></u></p>
<p>| to skin the cat, so it comes down to opinion and what we need is a decision<u></u><u></u></p>
<p>| (or a call to votes). As with anything that’s possibly quite opinionated,<u></u><u></u></p>
<p>| it’s good to have an authorative voice, so in this case, Simon PJ.<u></u><u></u></p>
<p>| <u></u><u></u></p>
<p>| Simon, can you either come up with a “all things considered, I think this<u></u><u></u></p>
<p>| variant is the (narrowly) the best” recommendation or, alternative, a<u></u><u></u></p>
<p>| “please vote on the following options” verdict?<u></u><u></u></p>
<p><u></u> <u></u></p>
<p><span style="font-family:"Calibri",sans-serif">OK, to remind everyone<u></u><u></u></span></p>
<ul style="margin-top:0cm" type="disc">
<li><span style="font-family:"Calibri",sans-serif">Here is the proposal:
<a href="https://github.com/JakobBruenker/ghc-proposals/blob/patch-1/proposals/0000-lambda-layout.md" target="_blank">
https://github.com/JakobBruenker/ghc-proposals/blob/patch-1/proposals/0000-lambda-layout.md</a><u></u><u></u></span></li><li><span style="font-family:"Calibri",sans-serif">Here is the discussion:
<a href="https://github.com/ghc-proposals/ghc-proposals/pull/302" target="_blank">https://github.com/ghc-proposals/ghc-proposals/pull/302</a><u></u><u></u></span></li></ul>
<p><span style="font-family:"Calibri",sans-serif"><u></u> <u></u></span></p>
<p><span style="font-family:"Calibri",sans-serif">The basic idea is to extend to lambda all the facilities that you get with function definitions, especially multiple patterns and guards. This seems clearly a good idea, whose only obstacle
is syntactic. There are no conceptual or specification challenges. The only point at issue is that of concrete syntax.<u></u><u></u></span></p>
<p><span style="font-family:"Calibri",sans-serif"><u></u> <u></u></span></p>
<p><span style="font-family:"Calibri",sans-serif">The proposal offers four possible syntactic options. After reviewing, I propose to discard (2) and (3) leaving these alternatives<u></u><u></u></span></p>
<p><span style="font-family:"Calibri",sans-serif"><u></u> <u></u></span></p>
<ul style="margin-top:0cm" type="disc">
<li style="margin-left:0cm"><b>Option (1)
</b>\cases { p1 p2 -> rhs1; q1 q2 -> rhs2 }<u></u><u></u></li><ul style="margin-top:0cm" type="circle">
<li style="margin-left:0cm">Lives alongside \case, but allows multiple patterns<u></u><u></u></li><li style="margin-left:0cm">Other keywords are possible, but I think it must be a variant on \case<u></u><u></u></li></ul>
<li style="margin-left:0cm"><b>Option (4)</b> Same, but use \case as the keyword<u></u><u></u></li><ul style="margin-top:0cm" type="circle">
<li style="margin-left:0cm">Incompatible with existing \case => extended transition period, unhappy users<u></u><u></u></li><li style="margin-left:0cm">\case { (Just x) -> rhs1; Nothing -> rhs2 } will require parens forever, which in the common case of a one argument lambda see clunky.<u></u><u></u></li></ul>
<li style="margin-left:0cm"><b>Option (X).</b> Reject the proposal.<u></u><u></u></li></ul>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Personally I favour (1). I’m relaxed about having multiple ways of saying the thing (think of let vs where), and I see no harm provided the two constructs look and behave the same. I’ve decided I like \cases precisely because it’s the
plural of \case, which is exactly what is going on.<u></u><u></u></p>
<p class="MsoNormal">I think we’ll end up having to vote on this, which is fine when it’s a judgement call about syntax. But first:<u></u><u></u></p>
<ul style="margin-top:0cm" type="circle">
<li style="margin-left:0cm"><b>Are there any other alternatives you
<i>strongly</i> want on the ballot?<u></u><u></u></b></li></ul>
<p class="MsoNormal">I say “strongly” because I don’t want to open up a big new debate… we at the stage of trying to narrow options.<u></u><u></u></p>
<p class="MsoNormal">Thanks<u></u><u></u></p>
<p class="MsoNormal">Simon<u></u><u></u></p>
</div>
</div>
_______________________________________________<br>
ghc-steering-committee mailing list<br>
<a href="mailto:ghc-steering-committee@haskell.org" target="_blank">ghc-steering-committee@haskell.org</a><br>
<a href="https://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-steering-committee" rel="noreferrer" target="_blank">https://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-steering-committee</a><br>
</blockquote></div>