Bug 27309 - Local variable in instantiateV8Object shadows function parameter
Summary: Local variable in instantiateV8Object shadows function parameter
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC All
: P2 Normal
Assignee: Adam Barth
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-15 12:00 PDT by James Hawkins
Modified: 2009-07-15 22:04 PDT (History)
1 user (show)

See Also:


Attachments
Patch which removes the local variable (1.26 KB, patch)
2009-07-15 12:02 PDT, James Hawkins
abarth: review+
Details | Formatted Diff | Diff
Patch2: modified the changelog (1.28 KB, patch)
2009-07-15 12:11 PDT, James Hawkins
abarth: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description James Hawkins 2009-07-15 12:00:43 PDT
v8::Local<v8::Object> V8DOMWrapper::instantiateV8Object(V8Proxy* proxy, ...
...
if (!proxy)
  V8Proxy* proxy = V8Proxy::retrieve();

proxy is declared as a local variable in the if clause, which shadows the function parameter of the same name.  This is a typo.  I will attach a patch which fixes this issue.
Comment 1 James Hawkins 2009-07-15 12:02:53 PDT
Created attachment 32797 [details]
Patch which removes the local variable
Comment 2 Adam Barth 2009-07-15 12:07:00 PDT
Comment on attachment 32797 [details]
Patch which removes the local variable

+	No test required as this change does not affect layout.

You should say that no test is required because this change does not change our behavior.  The LayoutTests test much more than just layout.  :)
Comment 3 James Hawkins 2009-07-15 12:11:41 PDT
Created attachment 32800 [details]
Patch2: modified the changelog
Comment 4 Adam Barth 2009-07-15 12:14:14 PDT
Comment on attachment 32800 [details]
Patch2: modified the changelog

Thanks!
Comment 5 Adam Barth 2009-07-15 21:53:25 PDT
Will land.
Comment 6 Adam Barth 2009-07-15 22:04:10 PDT
Sending        WebCore/ChangeLog
Sending        WebCore/bindings/v8/V8DOMWrapper.cpp
Transmitting file data ..
Committed revision 45965.