WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
157832
Make binding DOM constructor use toJSNewlyCreated instead of toJS
https://bugs.webkit.org/show_bug.cgi?id=157832
Summary
Make binding DOM constructor use toJSNewlyCreated instead of toJS
youenn fablet
Reported
2016-05-18 01:07:48 PDT
It would be more efficient to use toJSNewlyCreated for objects created in DOM constructors.
Attachments
Patch
(17.93 KB, patch)
2016-05-18 01:15 PDT
,
youenn fablet
no flags
Details
Formatted Diff
Diff
Patch for landing
(17.93 KB, patch)
2016-05-18 23:43 PDT
,
youenn fablet
no flags
Details
Formatted Diff
Diff
Patch for landing
(17.93 KB, patch)
2016-05-18 23:45 PDT
,
youenn fablet
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
youenn fablet
Comment 1
2016-05-18 01:15:09 PDT
Created
attachment 279229
[details]
Patch
Chris Dumez
Comment 2
2016-05-18 08:41:43 PDT
Comment on
attachment 279229
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=279229&action=review
r=me, nice!
> Source/WebCore/bindings/js/JSImageDataCustom.cpp:55 > + return toJSNewlyCreated(state, globalObject, Ref<ImageData>(imageData));
Do we really need the explicit Ref<>()?
> Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp:82 > + return toJSNewlyCreated(state, globalObject, Ref<TextTrackCue>(cue));
Do we really need the explicit Ref<>()?
> Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:477 > + return 1 if $interface->extendedAttributes->{"Constructor"} or $interface->extendedAttributes->{"NamedConstructor"};
nit: extra space in there.
youenn fablet
Comment 3
2016-05-18 23:42:09 PDT
> > Source/WebCore/bindings/js/JSImageDataCustom.cpp:55 > > + return toJSNewlyCreated(state, globalObject, Ref<ImageData>(imageData)); > > Do we really need the explicit Ref<>()?
Yes, which is a bit unfortunate. Otherwise the compiler is not sure which toJSNewlyCreated to pick.
> > Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp:82 > > + return toJSNewlyCreated(state, globalObject, Ref<TextTrackCue>(cue)); > > Do we really need the explicit Ref<>()?
Ditto.
> > Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:477 > > + return 1 if $interface->extendedAttributes->{"Constructor"} or $interface->extendedAttributes->{"NamedConstructor"}; > > nit: extra space in there.
OK.
youenn fablet
Comment 4
2016-05-18 23:43:22 PDT
Created
attachment 279361
[details]
Patch for landing
youenn fablet
Comment 5
2016-05-18 23:45:10 PDT
Created
attachment 279363
[details]
Patch for landing
WebKit Commit Bot
Comment 6
2016-05-19 00:13:45 PDT
Comment on
attachment 279363
[details]
Patch for landing Clearing flags on attachment: 279363 Committed
r201128
: <
http://trac.webkit.org/changeset/201128
>
WebKit Commit Bot
Comment 7
2016-05-19 00:13:50 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug