Bug 69677 - De-virtualize JSCell::toString
Summary: De-virtualize JSCell::toString
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Mark Hahnenberg
URL:
Keywords:
Depends on: 69156
Blocks: 67690
  Show dependency treegraph
 
Reported: 2011-10-07 16:50 PDT by Mark Hahnenberg
Modified: 2011-10-12 13:22 PDT (History)
1 user (show)

See Also:


Attachments
Patch (14.95 KB, patch)
2011-10-10 13:48 PDT, Mark Hahnenberg
no flags Details | Formatted Diff | Diff
Fix windows (16.52 KB, patch)
2011-10-10 18:14 PDT, Mark Hahnenberg
no flags Details | Formatted Diff | Diff
Fix windows (16.64 KB, patch)
2011-10-11 11:06 PDT, Mark Hahnenberg
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Hahnenberg 2011-10-07 16:50:32 PDT
Now that the JSC C API does something more sensible for toString (see bug 69156), we can eliminate JSCallbackObject::toString in favor of simply using JSObject::toString to cover the case for JSCallbackObject.
Comment 1 Mark Hahnenberg 2011-10-10 13:48:07 PDT
Created attachment 110398 [details]
Patch
Comment 2 Darin Adler 2011-10-10 14:10:28 PDT
Comment on attachment 110398 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=110398&action=review

> Source/JavaScriptCore/ChangeLog:9
> +        Removed toString from JSCallbackObject, since it is no 
> +        longer necessary.

Why is it no longer necessary? Because conversion to string is handled in defaultValue? Some other reason?

> Source/JavaScriptCore/runtime/ExceptionHelpers.cpp:50
> +    return JSValue(std::numeric_limits<double>::quiet_NaN());

Should not need "std::" here since it’s in a cpp file and we normally use “using namespace std” in those.

> Source/JavaScriptCore/runtime/ExceptionHelpers.cpp:75
> +    return JSValue(std::numeric_limits<double>::quiet_NaN());

Ditto.

> Source/JavaScriptGlue/ChangeLog:8
> +        Removed UserObjectImp::toString since it's no longer necessary.

Again, why is it no longer necessary?
Comment 3 Mark Hahnenberg 2011-10-10 18:14:18 PDT
Created attachment 110453 [details]
Fix windows
Comment 4 Mark Hahnenberg 2011-10-11 11:06:32 PDT
Created attachment 110541 [details]
Fix windows
Comment 5 WebKit Review Bot 2011-10-12 13:22:17 PDT
Comment on attachment 110541 [details]
Fix windows

Clearing flags on attachment: 110541

Committed r97292: <http://trac.webkit.org/changeset/97292>
Comment 6 WebKit Review Bot 2011-10-12 13:22:21 PDT
All reviewed patches have been landed.  Closing bug.