>
> type Maybe a = Nothing | Maybe a
>

To me this makes no sense. Maybe implies uncertainty: it's either there or
it's not. But in the case that it's there, there's no uncertainty. Maybe 3
isn't uncertain, we know that the value is there. The uncertainty is in the
type, before you pattern match, when there's two possibilities. The name
should reflect which possibility it is.

Also, new people already have enough problems confusing the Type and
Constructor namespaces, this would make that worse.



On Fri, Nov 25, 2016 at 2:44 PM, Zinggi <[email protected]> wrote:

> I love this!
> I've read through the whole thread, but for every suggestion so far I
> thought: "meh, 'Just a' sounds better".
> But this looks even better!
>
> On Friday, 25 November 2016 10:03:54 UTC+1, Witold Szczerba wrote:
>>
>> I have it, I have it, look at this:
>>
>> type Maybe a = Nothing | Maybe a
>>
>> It's very popular to name constructor after type in many languages.
>>
>> case msg of
>> Maybe This -> ...
>> Maybe That -> ...
>> Nothing -> ...
>>
>> Also, "Just" is just fine as well.
>>
>> 24.11.2016 10:21 PM "Michael B" <[email protected]> napisaƂ(a):
>>
>>> Maybe a = Nothing | Such a
>>>
>>> elm = Such wow
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Elm Discuss" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to [email protected].
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Elm Discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "Elm 
Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to