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

Issue 1699773002: Extend base::Callback to have a move-only variant (Closed)

Created:
4 years, 10 months ago by tzik
Modified:
4 years, 9 months ago
Reviewers:
Nico, dcheng
CC:
chromium-reviews, danakj, vmpstr+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Extend base::Callback to have a move-only variant Add CopyMode flag to base::Callback to split it to the copyable variant and the move-only variant. BUG=554299 Committed: https://crrev.com/77d41139d261342a429d2775c59d8e8a386d4c81 Cr-Commit-Position: refs/heads/master@{#380108}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : +msvc work around #

Patch Set 4 : msvc work around #

Total comments: 5

Patch Set 5 : #

Total comments: 4

Patch Set 6 : rebase. +comment. #

Patch Set 7 : shrink binary size #

Patch Set 8 : attempt #2 #

Patch Set 9 : attempt #3 #

Patch Set 10 : fix android build #

Total comments: 9

Patch Set 11 : +explicit #

Total comments: 2

Patch Set 12 : +explicit again. move BASE_EXPORT to .h #

Total comments: 2

Patch Set 13 : #

Total comments: 1

Patch Set 14 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+105 lines, -38 lines) Patch
M base/callback.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +16 lines, -21 lines 0 comments Download
M base/callback_forward.h View 1 2 3 4 1 chunk +12 lines, -1 line 0 comments Download
M base/callback_internal.h View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +29 lines, -5 lines 0 comments Download
M base/callback_internal.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +47 lines, -10 lines 0 comments Download
M base/callback_unittest.nc View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 68 (27 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/20001
4 years, 10 months ago (2016-02-15 02:04:47 UTC) #2
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/173841)
4 years, 10 months ago (2016-02-15 02:45:09 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/40001
4 years, 10 months ago (2016-02-15 04:33:28 UTC) #7
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/60001
4 years, 10 months ago (2016-02-15 04:52:38 UTC) #10
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_compile_dbg_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_compile_dbg_ng/builds/145483)
4 years, 10 months ago (2016-02-15 07:25:19 UTC) #12
tzik
PTAL
4 years, 10 months ago (2016-02-15 20:52:51 UTC) #14
Nico
filed https://code.google.com/p/chromium/issues/detail?id=586967 for the red build
4 years, 10 months ago (2016-02-15 21:39:18 UTC) #15
Nico
Cool. Is the idea that the type is a transitional thing, or will we have ...
4 years, 10 months ago (2016-02-15 21:47:57 UTC) #16
tzik
On 2016/02/15 21:47:57, Nico wrote: > Cool. Is the idea that the type is a ...
4 years, 10 months ago (2016-02-16 08:59:29 UTC) #17
tzik
https://codereview.chromium.org/1699773002/diff/60001/base/callback.h File base/callback.h (left): https://codereview.chromium.org/1699773002/diff/60001/base/callback.h#oldcode356 base/callback.h:356: // please include "base/callback_forward.h" instead. On 2016/02/15 21:47:57, Nico ...
4 years, 10 months ago (2016-02-16 09:33:32 UTC) #18
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/80001
4 years, 10 months ago (2016-02-16 09:33:46 UTC) #20
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 10 months ago (2016-02-16 12:02:02 UTC) #22
dcheng
https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h File base/callback_internal.h (left): https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h#oldcode86 base/callback_internal.h:86: explicit CallbackBase(BindStateBase* bind_state); Why change this from initializing in ...
4 years, 10 months ago (2016-02-16 23:12:27 UTC) #23
tzik
https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h File base/callback_internal.h (left): https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h#oldcode86 base/callback_internal.h:86: explicit CallbackBase(BindStateBase* bind_state); On 2016/02/16 23:12:26, dcheng wrote: > ...
4 years, 10 months ago (2016-02-17 00:46:56 UTC) #24
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/100001
4 years, 9 months ago (2016-02-29 14:27:34 UTC) #26
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-02-29 16:01:45 UTC) #28
dcheng
https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h File base/callback_internal.h (left): https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h#oldcode86 base/callback_internal.h:86: explicit CallbackBase(BindStateBase* bind_state); On 2016/02/17 at 00:46:56, tzik wrote: ...
4 years, 9 months ago (2016-02-29 17:51:58 UTC) #29
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/120001
4 years, 9 months ago (2016-03-01 00:28:58 UTC) #31
tzik
On 2016/02/29 17:51:58, dcheng wrote: > https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h > File base/callback_internal.h (left): > > https://codereview.chromium.org/1699773002/diff/80001/base/callback_internal.h#oldcode86 > ...
4 years, 9 months ago (2016-03-01 00:29:05 UTC) #32
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/160001
4 years, 9 months ago (2016-03-01 01:24:35 UTC) #34
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_compile_dbg_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_compile_dbg_ng/builds/152989)
4 years, 9 months ago (2016-03-01 02:11:29 UTC) #36
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/180001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/180001
4 years, 9 months ago (2016-03-01 05:04:03 UTC) #38
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: chromeos_x86-generic_chromium_compile_only_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromeos_x86-generic_chromium_compile_only_ng/builds/100678)
4 years, 9 months ago (2016-03-01 05:42:42 UTC) #40
tzik
Updated! Linux bot failure looks a dependency issue, that is not directly related to this ...
4 years, 9 months ago (2016-03-01 07:31:33 UTC) #41
dcheng
https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc#newcode21 base/callback_internal.cc:21: BASE_EXPORT CallbackBase<CopyMode::MoveOnly>::CallbackBase(CallbackBase&& c) Huh. It's surprising to see _EXPORT ...
4 years, 9 months ago (2016-03-02 08:02:36 UTC) #42
tzik
https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc#newcode63 base/callback_internal.cc:63: } On 2016/03/02 08:02:36, dcheng wrote: > Can we ...
4 years, 9 months ago (2016-03-02 08:13:14 UTC) #43
tzik
https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc#newcode21 base/callback_internal.cc:21: BASE_EXPORT CallbackBase<CopyMode::MoveOnly>::CallbackBase(CallbackBase&& c) On 2016/03/02 08:02:36, dcheng wrote: > ...
4 years, 9 months ago (2016-03-02 13:09:52 UTC) #44
dcheng
https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/180001/base/callback_internal.cc#newcode21 base/callback_internal.cc:21: BASE_EXPORT CallbackBase<CopyMode::MoveOnly>::CallbackBase(CallbackBase&& c) On 2016/03/02 at 13:09:52, tzik wrote: ...
4 years, 9 months ago (2016-03-02 17:04:57 UTC) #45
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/220001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/220001
4 years, 9 months ago (2016-03-03 15:21:39 UTC) #47
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-03 18:22:00 UTC) #49
tzik
https://codereview.chromium.org/1699773002/diff/200001/base/callback_internal.h File base/callback_internal.h (right): https://codereview.chromium.org/1699773002/diff/200001/base/callback_internal.h#newcode113 base/callback_internal.h:113: CallbackBase(BindStateBase* bind_state) On 2016/03/02 17:04:56, dcheng wrote: > Make ...
4 years, 9 months ago (2016-03-03 18:53:26 UTC) #50
dcheng
lgtm https://codereview.chromium.org/1699773002/diff/220001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/220001/base/callback_internal.cc#newcode65 base/callback_internal.cc:65: CallbackBase<CopyMode::Copyable>::CallbackBase( Same nit from earlier: the definitions should ...
4 years, 9 months ago (2016-03-03 21:20:04 UTC) #51
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/240001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/240001
4 years, 9 months ago (2016-03-07 16:12:36 UTC) #53
tzik
Updated. Nico: Could you PTAL to this? https://codereview.chromium.org/1699773002/diff/220001/base/callback_internal.cc File base/callback_internal.cc (right): https://codereview.chromium.org/1699773002/diff/220001/base/callback_internal.cc#newcode65 base/callback_internal.cc:65: CallbackBase<CopyMode::Copyable>::CallbackBase( On ...
4 years, 9 months ago (2016-03-07 16:18:01 UTC) #54
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-07 19:41:42 UTC) #56
Nico
lgtm, thanks! Also thanks to dcheng for helping with the review, this is really useful. ...
4 years, 9 months ago (2016-03-09 03:24:53 UTC) #57
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/260001
4 years, 9 months ago (2016-03-09 07:02:27 UTC) #59
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 9 months ago (2016-03-09 08:45:28 UTC) #61
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1699773002/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1699773002/260001
4 years, 9 months ago (2016-03-09 09:33:07 UTC) #64
commit-bot: I haz the power
Committed patchset #14 (id:260001)
4 years, 9 months ago (2016-03-09 09:47:12 UTC) #66
commit-bot: I haz the power
4 years, 9 months ago (2016-03-09 09:48:17 UTC) #68
Message was sent while issue was closed.
Patchset 14 (id:??) landed as
https://crrev.com/77d41139d261342a429d2775c59d8e8a386d4c81
Cr-Commit-Position: refs/heads/master@{#380108}

Powered by Google App Engine
This is Rietveld 408576698