On Wednesday, June 20, 2012 at 10:15 PM, Dominic Tarr wrote:
> prototype chains and closure scopes actually work in a precisely similar way. > > This is egregiously incorrect. Before you give out advice, I beg you to read the spec and actually understand the material. > > this gist gives some examples of identical structures created with > scopes and prototypes. > > The only thing they share in common is that they result in some property being assigned with some value on some object (in one case explicitly, the other implicitly) - their semantics are like night and day. A prototype definition is an object that exists exactly once in memory and is shared by bound referrence and resolved via upward lookup. A scope is an execution context representable by an object (eg |this|) Rick > > https://gist.github.com/2904285 > > > On Thu, Jun 21, 2012 at 7:34 AM, P. Douglas Reeder <[email protected]> > wrote: > > Use the style that your team find most natural for the problem you're > > solving. That will make it easier to fix bugs and add enhancements. > > > > If profiling shows one part of your app is the bottleneck, consider > > rewriting it. > > > > Other problems may make other styles more appropriate. > > > > -- > > Job Board: http://jobs.nodejs.org/ > > Posting guidelines: > > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > > You received this message because you are subscribed to the Google > > Groups "nodejs" group. > > To post to this group, send email to [email protected] > > To unsubscribe from this group, send email to > > [email protected] > > For more options, visit this group at > > http://groups.google.com/group/nodejs?hl=en?hl=en > > > > > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > > -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en
