Consider javascript already support for default parameters, so maybe we can use the default parameter to specify the strong type.
Gary Guo
nbdd0121 at hotmail.com
Wed May 20 09:02:27 UTC 2015
If strong type is needed, why not use TypeScript?
> From: luoyonggang at gmail.com
> Date: Mon, 18 May 2015 01:50:34 +0800
> Subject: Consider javascript already support for default parameters, so maybe we can use the default parameter to specify the strong type.
> To: es-discuss at mozilla.org
>
> For example:
>
> function addWithType(a = int64(0), b = int64(0)) {
> return a + b;
> }
>
> This function is input add two int64 and return a int64
>
> --
> 此致
> 礼
> 罗勇刚
> Yours
> sincerely,
> Yonggang Luo
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20150520/5e528c74/attachment.html>
More information about the es-discuss
mailing list