ES4 draft: Map

P T Withington ptw at pobox.com
Mon Mar 3 09:31:58 PST 2008


You and Lars missed my sarcasm marks.  I hope there is _not_ a  
shorthand.

On 2008-03-03, at 12:14 EST, Brendan Eich wrote:

> We've talked about V~ for (V|undefined). It would have a few uses in  
> the RI, but not enough to close the deal.
>
> /be
>
> On Mar 3, 2008, at 5:48 AM, Lars Hansen wrote:
>
>>> -----Original Message-----
>>> From: P T Withington [mailto:ptwithy at gmail.com] On Behalf Of
>>> P T Withington
>>> Sent: 3. mars 2008 13:47
>>> To: Lars Hansen
>>> Cc: Waldemar Horwat; es4-discuss at mozilla.org
>>> Subject: Re: ES4 draft: Map
>>>
>>> On 2008-03-03, at 02:26 EST, Lars Hansen wrote:
>>>
>>>> function get(key:K, default:(V|undefined)=undefined):(V|
>>>> undefined) ...
>>>
>>> If V? is shorthand for (V|null), what is the shorthand for
>>> (V|null| undefined)?  Perhaps V?@%#$!  Well, at least that
>>> expresses how I feel about a language with 'two nulls'.  :P
>>
>> There is no shorthand for (V|null|undefined), though if V is
>> a nullable type then (V|undefined) works just as well.
>>
>> --lars
>> _______________________________________________
>> Es4-discuss mailing list
>> Es4-discuss at mozilla.org
>> https://mail.mozilla.org/listinfo/es4-discuss
>




More information about the Es4-discuss mailing list