News for hackers. Stuff that matters.
Re:Javascript patterns by dpweb on Wednesday January 01, 2014 @09:56PM (#6997933)
Why call eval like this? (1, eval)('this');
Re:Javascript patterns by dcherman on Wednesday January 01, 2014 @11:11PM (#6998155)
I'm pretty sure it's due to http://es5.github.io/#x10.4.2 section 1A.

Calling eval like that causes it to be an indirect eval call which results in it being executed in the global context.

Re:Javascript patterns by nairteashop on Thursday January 02, 2014 @02:32AM (#6998603)
I was wondering too. There is a nice answer at SO that expands on what dcherman said: http://stackoverflow.com/a/9107367
Re:Javascript patterns by kangax on Thursday January 02, 2014 @05:34PM (#7002840)