Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(247)

Issue 2944313004: Correct threading documentation example. (Closed)

Created:
3 years, 6 months ago by karandeepb
Modified:
3 years, 6 months ago
Reviewers:
lazyboy
CC:
chromium-reviews
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Correct threading documentation example. Calling a callback with a raw pointer argument while binding a scoped_refptr to it requires using base::RetainedRef. Correct the same in threading documentation. Also, introduce std::move in the example to demonstrate preventing an extra AddRef/Release pair. BUG=None Review-Url: https://codereview.chromium.org/2944313004 Cr-Commit-Position: refs/heads/master@{#482065} Committed: https://chromium.googlesource.com/chromium/src/+/09f8883243cb82866287f401457d10523d0f2d05

Patch Set 1 #

Total comments: 4

Patch Set 2 : Address review. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+20 lines, -5 lines) Patch
M docs/design/threading.md View 1 2 chunks +20 lines, -5 lines 0 comments Download

Messages

Total messages: 13 (7 generated)
karandeepb
Istiaque: Can you do a sanity check?
3 years, 6 months ago (2017-06-22 01:04:39 UTC) #3
lazyboy
https://codereview.chromium.org/2944313004/diff/1/docs/design/threading.md File docs/design/threading.md (right): https://codereview.chromium.org/2944313004/diff/1/docs/design/threading.md#newcode246 docs/design/threading.md:246: // Moving |param| prevents an extra AddRef()/Release() pair. Nice, ...
3 years, 6 months ago (2017-06-23 20:43:27 UTC) #4
karandeepb
https://codereview.chromium.org/2944313004/diff/1/docs/design/threading.md File docs/design/threading.md (right): https://codereview.chromium.org/2944313004/diff/1/docs/design/threading.md#newcode246 docs/design/threading.md:246: // Moving |param| prevents an extra AddRef()/Release() pair. On ...
3 years, 6 months ago (2017-06-23 22:48:46 UTC) #7
lazyboy
lgtm
3 years, 6 months ago (2017-06-23 22:58:51 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2944313004/60001
3 years, 6 months ago (2017-06-23 23:01:08 UTC) #10
commit-bot: I haz the power
3 years, 6 months ago (2017-06-23 23:15:45 UTC) #13
Message was sent while issue was closed.
Committed patchset #2 (id:60001) as
https://chromium.googlesource.com/chromium/src/+/09f8883243cb82866287f401457d...

Powered by Google App Engine
This is Rietveld 408576698