The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Newsgroups: comp.lang.javascript
From: Joost Diepenmaat <jo...@zeekat.nl>
Date: Mon, 28 Jan 2008 22:58:40 +0100
Local: Mon, Jan 28 2008 4:58 pm
Subject: Re: "x.constructor == Foo" vs "x instanceof Foo"
Thomas 'PointedEars' Lahn <PointedE...@web.de> writes:
> Joost Diepenmaat wrote: If you're defining closures like that, every function that calls another >> Thomas 'PointedEars' Lahn <PointedE...@web.de> writes: >>> Thanks, I was looking for that. However, you should consider that the >>> increased runtime efficiency gained by declaring the Dummy() constructor >>> only once is mitigated by the reduced memory efficiency caused by the >>> continued allocation of memory due to the closure. And since there are >>> more issues with closures than without them, I would avoid them here. >> function Dummy(){} >> No closure. [...] > I think there is one. `Dummy' was declared in the definition function, or accesses any other global property would be a closure: function a() { alert() } My informal definition is that a closure is a function that keeps Joost. You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||