WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
133375
Replace uses of CrossThreadTask in DefaultSharedWorkerRepository, WorkerMessagingProxy with C++11 lambdas
https://bugs.webkit.org/show_bug.cgi?id=133375
Summary
Replace uses of CrossThreadTask in DefaultSharedWorkerRepository, WorkerMessa...
Zan Dobersek
Reported
2014-05-29 04:21:10 PDT
Replaces uses of CrossThreadTask with C++11 lambdas
Attachments
Patch
(10.22 KB, patch)
2014-05-29 04:25 PDT
,
Zan Dobersek
no flags
Details
Formatted Diff
Diff
Patch
(12.90 KB, patch)
2014-06-05 02:13 PDT
,
Zan Dobersek
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Zan Dobersek
Comment 1
2014-05-29 04:25:21 PDT
Created
attachment 232241
[details]
Patch
WebKit Commit Bot
Comment 2
2014-05-29 04:28:34 PDT
Attachment 232241
[details]
did not pass style-queue: ERROR: Source/WebCore/workers/DefaultSharedWorkerRepository.cpp:186: Multi line control clauses should use braces. [whitespace/braces] [4] Total errors found: 1 in 3 files If any of these errors are false positives, please file a bug against check-webkit-style.
Darin Adler
Comment 3
2014-05-31 15:35:11 PDT
Comment on
attachment 232241
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=232241&action=review
Looks good. I’d like to eliminate the context argument to the function at some point. I don’t think it adds much over a function with no arguments.
> Source/WebCore/workers/DefaultSharedWorkerRepository.cpp:188 > + context->reportException(errorMessageCopy, lineNumber, columnNumber, sourceURLCopy);
Need to add a nullptr to this line, after sourceURLCopy.
> Source/WebCore/workers/WorkerMessagingProxy.cpp:170 > + if (this->askedToTerminate())
No need for "this->" here.
> Source/WebCore/workers/WorkerMessagingProxy.cpp:238 > + toWorkerGlobalScope(context)->workerInspectorController().disconnectFrontend(Inspector::InspectorDisconnectReason::InspectorDestroyed);
Could we just capture a worker global scope here instead of casting the context?
Zan Dobersek
Comment 4
2014-06-05 02:12:32 PDT
Comment on
attachment 232241
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=232241&action=review
>> Source/WebCore/workers/WorkerMessagingProxy.cpp:170 >> + if (this->askedToTerminate()) > > No need for "this->" here.
Right, and it can be removed in some other places as well.
>> Source/WebCore/workers/WorkerMessagingProxy.cpp:238 >> + toWorkerGlobalScope(context)->workerInspectorController().disconnectFrontend(Inspector::InspectorDisconnectReason::InspectorDestroyed); > > Could we just capture a worker global scope here instead of casting the context?
Where from? This task is posted in WorkerMessagingProxy::disconnectFromInspector(), and there's no WorkerGlobalScope available there for capturing.
Zan Dobersek
Comment 5
2014-06-05 02:13:28 PDT
Created
attachment 232531
[details]
Patch
WebKit Commit Bot
Comment 6
2014-06-05 02:14:19 PDT
Attachment 232531
[details]
did not pass style-queue: ERROR: Source/WebCore/workers/DefaultSharedWorkerRepository.cpp:187: Multi line control clauses should use braces. [whitespace/braces] [4] Total errors found: 1 in 3 files If any of these errors are false positives, please file a bug against check-webkit-style.
Zan Dobersek
Comment 7
2014-06-07 06:07:26 PDT
Committed
r169673
: <
http://trac.webkit.org/changeset/169673
>
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