On Thu, Jan 13, 2011 at 5:50 PM, Amit Agarwal <[email protected]> wrote:
> Hi,
>
> I tried using new with number primitive wrapper constructor. It gave a
> strange result.
>
> var numObj = new Number(2);
>
> *numObj = 2 {}*
>
> Any guesses what is this?
>
The output doesn't really make sense (to me) in a js context.
Did you mean that numObj now contains an object rather than a number? What
did you expect would happen?
- peter
--
To view archived discussions from the original JSMentors Mailman list:
http://www.mail-archive.com/[email protected]/
To search via a non-Google archive, visit here:
http://www.mail-archive.com/[email protected]/
To unsubscribe from this group, send email to
[email protected]