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

Issue 2741493002: Improve singleton example by assuming implementation is outside base/ (Closed)

Created:
3 years, 9 months ago by Patrick Monette
Modified:
3 years, 9 months ago
Reviewers:
danakj
CC:
chromium-reviews, gavinp+memory_chromium.org, vmpstr+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Improve singleton example by assuming implementation is outside base/ The error messages returned by the compiler are hard to understand and most singleton implementations live outside base/. Also adds an example for leaky singletons because it's not clear that DefaultSingletonTraits must still be friended. Review-Url: https://codereview.chromium.org/2741493002 Cr-Commit-Position: refs/heads/master@{#455931} Committed: https://chromium.googlesource.com/chromium/src/+/961c9d662de83d9d27547c48576e9df6ccfb5146

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -3 lines) Patch
M base/memory/singleton.h View 2 chunks +13 lines, -3 lines 3 comments Download

Messages

Total messages: 12 (5 generated)
Patrick Monette
PTAL.
3 years, 9 months ago (2017-03-08 19:39:08 UTC) #2
danakj
LGTM https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h File base/memory/singleton.h (right): https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h#newcode157 base/memory/singleton.h:157: // template <typename T> nit: keep this as ...
3 years, 9 months ago (2017-03-09 21:18:22 UTC) #4
Patrick Monette
https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h File base/memory/singleton.h (right): https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h#newcode157 base/memory/singleton.h:157: // template <typename T> On 2017/03/09 21:18:22, danakj wrote: ...
3 years, 9 months ago (2017-03-09 23:02:13 UTC) #5
danakj
https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h File base/memory/singleton.h (right): https://codereview.chromium.org/2741493002/diff/1/base/memory/singleton.h#newcode157 base/memory/singleton.h:157: // template <typename T> On 2017/03/09 23:02:13, Patrick Monette ...
3 years, 9 months ago (2017-03-09 23:04:18 UTC) #6
Patrick Monette
Thanks!
3 years, 9 months ago (2017-03-09 23:40:53 UTC) #7
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/2741493002/1
3 years, 9 months ago (2017-03-09 23:41:42 UTC) #9
commit-bot: I haz the power
3 years, 9 months ago (2017-03-10 00:52:27 UTC) #12
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://chromium.googlesource.com/chromium/src/+/961c9d662de83d9d27547c48576e...

Powered by Google App Engine
This is Rietveld 408576698