Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #29516 > unrolled thread

Re: "ToNumber"

Started byAleksandro <aleksandro@gmx.com>
First post2016-02-01 11:08 -0300
Last post2016-02-01 11:08 -0300
Articles 1 — 1 participant

Back to article view | Back to comp.lang.javascript

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: "ToNumber" Aleksandro <aleksandro@gmx.com> - 2016-02-01 11:08 -0300

#29516 — Re: "ToNumber"

FromAleksandro <aleksandro@gmx.com>
Date2016-02-01 11:08 -0300
SubjectRe: "ToNumber"
Message-ID<n8non0$o62$1@dont-email.me>
On 01/02/16 07:44, Stefan Ram wrote:
> ram@zedat.fu-berlin.de (Stefan Ram) writes:
>> < Math.floor()
>>> NaN
>> Is this specified by ECMAScript?
> 
>   In the meantime, I found this:
> 
>       »17 ECMAScript Standard Built-in Objects
> 
>       ...
> 
>       Unless otherwise specified in the description of a
>       particular function, if a built-in function or
>       constructor is given fewer arguments than the function
>       is specified to require, the function or constructor
>       shall behave exactly as if it had been given sufficient
>       additional arguments, each such argument being the
>       undefined value.«
> 
>   So, I hope that now I have found why »Math.floor()« behaves
>   like »Math.floor( undefined )«. Please let me know if you
>   think that the above quotation does /not/ apply here.

I don't see why this would not be the case, you give non-numbers to a
function that needs numbers, that's why you won't get a number either.

[toc] | [standalone]


Back to top | Article view | comp.lang.javascript


csiph-web