Bug 29742

Summary: [Chromium] Change window.toString() callback to match JSC
Product: WebKit Reporter: Nate Chapin <japhet>
Component: WebCore Misc.Assignee: Nate Chapin <japhet>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth, ager, dglazkov, eric
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
patch abarth: review+, japhet: commit-queue-

Nate Chapin
Reported 2009-09-25 10:50:18 PDT
The V8 bindings currently access the global object wrapper instead of the DOMWindow wrapper in the toString() callback. We should be accessing the DOMWindow wrapper, since we currently output [object global] instead of the expected [object DOMWindow].
Attachments
patch (1.58 KB, patch)
2009-09-25 10:51 PDT, Nate Chapin
abarth: review+
japhet: commit-queue-
Nate Chapin
Comment 1 2009-09-25 10:51:26 PDT
Eric Seidel (no email)
Comment 2 2009-09-25 14:18:55 PDT
You should list what test this affects. Assuming that it affects a test? If it doesn't then we need to add a test. Adam and Dimitri are probably your two best WebKit reviewers here.
Adam Barth
Comment 3 2009-09-25 14:25:38 PDT
Comment on attachment 40124 [details] patch This looks great, but please list which LayoutTests this fixes.
Nate Chapin
Comment 4 2009-09-25 14:27:35 PDT
I initially started looking at it for LayoutTests/fast/events/event-trace.html, and from a run of all layout tests, it appears it will fix 2 and allow us to use default expectations on about a dozen others. There are some others that we're also failing for other reasons that will still fail, but will be closer to expectations. I'll see if I can assemble a full list. I can try and compile a full list if that would be helpful.(In reply to comment #3) > (From update of attachment 40124 [details]) > This looks great, but please list which LayoutTests this fixes.
Nate Chapin
Comment 5 2009-09-25 14:36:44 PDT
The complete list, to the best of my knowledge, is: LayoutTests/fast/dom/Window/atob-btoa.html LayoutTests/fast/dom/Window/window-lookup-precedence.html LayoutTests/fast/dom/Window/window-postmessage-args.html LayoutTests/fast/dom/Window/window-properties.html LayoutTests/fast/events/event-trace.html LayoutTests/fast/events/event-view-toString.html LayoutTests/fast/js/eval-cross-window.html LayoutTests/fast/js/eval-keyword-vs-function.html LayoutTests/fast/js/toString-and-valueOf-override.html LayoutTests/http/tests/security/cross-frame-access-custom.html LayoutTests/http/tests/security/cross-frame-access-put.html
Adam Barth
Comment 6 2009-09-25 14:52:23 PDT
Comment on attachment 40124 [details] patch Awesome!
Nate Chapin
Comment 7 2009-09-25 15:05:37 PDT
Comment on attachment 40124 [details] patch cq- The Chromium WebKit canary is compile-broken at the moment, and I would like to verify precisely how the downstream expectations need to be changed before this gets integrated, so I want to wait on committing.
Nate Chapin
Comment 8 2009-09-28 15:30:30 PDT
Committed as r48841.
Note You need to log in before you can comment on or make changes to this bug.