Bug 145112 - Purge PassRefPtr in WebCore/Modules
Summary: Purge PassRefPtr in WebCore/Modules
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Gyuyoung Kim
URL:
Keywords:
Depends on:
Blocks: 144092
  Show dependency treegraph
 
Reported: 2015-05-17 17:42 PDT by Gyuyoung Kim
Modified: 2015-05-21 00:27 PDT (History)
1 user (show)

See Also:


Attachments
Patch (84.82 KB, patch)
2015-05-17 17:44 PDT, Gyuyoung Kim
no flags Details | Formatted Diff | Diff
Patch (53.27 KB, patch)
2015-05-17 22:24 PDT, Gyuyoung Kim
no flags Details | Formatted Diff | Diff
Patch for landing (53.20 KB, patch)
2015-05-20 20:02 PDT, Gyuyoung Kim
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gyuyoung Kim 2015-05-17 17:42:53 PDT
SSIA
Comment 1 Gyuyoung Kim 2015-05-17 17:44:11 PDT
Created attachment 253300 [details]
Patch
Comment 2 Gyuyoung Kim 2015-05-17 22:24:48 PDT
Created attachment 253302 [details]
Patch
Comment 3 Darin Adler 2015-05-20 08:51:55 PDT
Comment on attachment 253302 [details]
Patch

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

> Source/WebCore/Modules/geolocation/PositionOptions.h:36
> +    static Ref<PositionOptions> create() { return adoptRef(*new PositionOptions()); }

I like to omit the unneeded parentheses in cases like this.

> Source/WebCore/Modules/mediastream/RTCDataChannel.h:51
> +    static RefPtr<RTCDataChannel> create(ScriptExecutionContext*, RTCPeerConnectionHandler*, const String& , const Dictionary&, ExceptionCode&);

Stray space after "const String&". Also, it makes no sense to omit the argument name for the string and dictionary; the types alone do not make it clear what these are!

> Source/WebCore/Modules/websockets/WebSocket.cpp:159
> +RefPtr<WebSocket> WebSocket::create(ScriptExecutionContext& context)

Should be Ref, not RefPtr.

> Source/WebCore/Modules/websockets/WebSocket.h:57
> +    static RefPtr<WebSocket> create(ScriptExecutionContext&);

Should be Ref, not RefPtr.
Comment 4 Gyuyoung Kim 2015-05-20 20:02:04 PDT
Created attachment 253498 [details]
Patch for landing
Comment 5 Gyuyoung Kim 2015-05-20 23:37:38 PDT
(In reply to comment #3)
> Comment on attachment 253302 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=253302&action=review
> 
> > Source/WebCore/Modules/geolocation/PositionOptions.h:36
> > +    static Ref<PositionOptions> create() { return adoptRef(*new PositionOptions()); }
> 
> I like to omit the unneeded parentheses in cases like this.
> 
> > Source/WebCore/Modules/mediastream/RTCDataChannel.h:51
> > +    static RefPtr<RTCDataChannel> create(ScriptExecutionContext*, RTCPeerConnectionHandler*, const String& , const Dictionary&, ExceptionCode&);
> 
> Stray space after "const String&". Also, it makes no sense to omit the
> argument name for the string and dictionary; the types alone do not make it
> clear what these are!
> 
> > Source/WebCore/Modules/websockets/WebSocket.cpp:159
> > +RefPtr<WebSocket> WebSocket::create(ScriptExecutionContext& context)
> 
> Should be Ref, not RefPtr.
> 
> > Source/WebCore/Modules/websockets/WebSocket.h:57
> > +    static RefPtr<WebSocket> create(ScriptExecutionContext&);
> 
> Should be Ref, not RefPtr.

All fixed.
Comment 6 WebKit Commit Bot 2015-05-21 00:27:18 PDT
Comment on attachment 253498 [details]
Patch for landing

Clearing flags on attachment: 253498

Committed r184709: <http://trac.webkit.org/changeset/184709>
Comment 7 WebKit Commit Bot 2015-05-21 00:27:22 PDT
All reviewed patches have been landed.  Closing bug.