<div dir="ltr">Why guess when we could test this? This is a bit of syntax and it has equivalents in other programming languages, so there's no reason in principle why we couldn't just make a multiple choice quiz. Have programmers that haven't ever used Haskell before declare what languages they know, take the quiz, then we see what does and doesn't confuse them.</div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Jun 6, 2015 at 8:29 PM, Anthony Cowley <span dir="ltr"><<a href="mailto:acowley@seas.upenn.edu" target="_blank">acowley@seas.upenn.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Sat, Jun 6, 2015 at 8:25 PM, Alexander Kjeldaas<br>
<<a href="mailto:alexander.kjeldaas@gmail.com">alexander.kjeldaas@gmail.com</a>> wrote:<br>
> On Sat, Jun 6, 2015 at 10:26 AM, Vlatko Basic <<a href="mailto:vlatko.basic@gmail.com">vlatko.basic@gmail.com</a>><br>
> wrote:<br>
>><br>
>> Maybe a slightly changed syntax like this could be less confusing<br>
>><br>
>><br>
>> import Data.Map (Map) andAs M (...)<br>
>><br>
>> or<br>
>><br>
>> import Data.Map (Map) and as M (...)<br>
>><br>
>><br>
>> It is clear (IMHO) what is coming from where, and both lists are at the<br>
>> end of their part, so can be written nicely in several rows, if needed.<br>
>><br>
>><br>
>> import Data.Map (Map)<br>
>>  andAs M (lengthy,<br>
>>           list)<br>
>><br>
>> Parser can also easily distinguish between the current and the new syntax<br>
>> so they can coexist, so no backward compatibility problem.<br>
>><br>
><br>
><br>
> I much prefer a syntax with a bit more words, like this one.  The original<br>
> proposal is simply impossible to understand without reading a manual.  It<br>
> has at least two equally valid interpretations.<br>
><br>
> Adding one or two words like in this examples makes it possible, without<br>
> reading a manual, to distinguish between possible interpretations.  I think<br>
> that must be a minimal requirement for such a syntax extension.  Nobody<br>
> needs to hire a language lawyer to understand a python import statement.<br>
> That shouldn't be needed for Haskell either.<br>
><br>
> Alexander<br>
<br>
</div></div>Thanks for the feedback, Vlatko, Alexander, and Kosyrev! I would like<br>
the syntax to avoid being overly hostile to newcomers, so some tweaks<br>
are certainly possible.<br>
<br>
So that I understand, you believe that a newcomer could read<br>
<br>
import Data.Map (Map) andAs M (lengthy)<br>
<br>
and infer which names are qualified and which aren't without<br>
consulting a manual, whereas without the "and" it would be "impossible<br>
to understand"? I confess I find that hard to believe, but I'll bear<br>
it in mind in case this option picks up wider support. There are<br>
already three of you on board, so it's off to a good start.<br>
<span class="HOEnZb"><font color="#888888"><br>
Anthony<br>
</font></span><div class="HOEnZb"><div class="h5">_______________________________________________<br>
Haskell-Cafe mailing list<br>
<a href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div dir="ltr">Chris Allen<br><div><span style="font-size:12.8000001907349px">Currently working on </span><a href="http://haskellbook.com" target="_blank">http://haskellbook.com</a></div></div></div></div></div></div>
</div>