New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 644601 link

Starred by 2 users

Issue metadata

Status: Duplicate
Merged: issue 552753
Owner:
Last visit > 30 days ago
Closed: Sep 2016
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

Wrong 'this' value in the local scope

Reported by l446240525@gmail.com, Sep 7 2016

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2846.4 Safari/537.36

Steps to reproduce the problem:
http://a1.alicdn.com/oss/uploads/2016/09/07/e22cc920-74b4-11e6-b042-097f3593e5a6.html

What is the expected behavior?

What went wrong?
'this' should be that <a>

Did this work before? N/A 

Chrome version: 55.0.2846.4  Channel: n/a
OS Version: OS X 10.10.4
Flash Version: Shockwave Flash 22.0 r0
 
this.png
248 KB View Download
222.png
212 KB View Download
Components: Platform>DevTools>JavaScript
Owner: kozyatinskiy@chromium.org
Status: Assigned (was: Unconfirmed)
Hah. nice bug.

Same behavior in stable, too. Both with the onclick example and the more generic one:

(function() { 
  return ()=> {
    console.log(this);
    debugger;
  }
}
).bind({foo:1})()();

Meanwhile `this` in the watch pane functions correctly.
Mergedinto: 552753
Status: Duplicate (was: Assigned)

Sign in to add a comment