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

Issue 2084213003: Make container classes in SkTemplates.h more consistent (Closed)

Created:
4 years, 6 months ago by csmartdalton
Modified:
4 years, 6 months ago
Reviewers:
bsalomon, mtklein, reed1
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

Make container classes in SkTemplates.h more consistent Ensures that ".get()" always returns null when a container is empty. Also ensures consistent assert behavior for array counts. There are still differences in that the malloc variants take a size_t and the arrays take an int, and that SkAutoSTMalloc defaults to the stack-allocated buffer wheras the other containers default to null. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2084213003 Committed: https://skia.googlesource.com/skia/+/d0e402f99949127624b5c5e6d673a44a71940489

Patch Set 1 #

Total comments: 6

Patch Set 2 : Make buffer classes in SkTemplates.h more consistent #

Patch Set 3 : Make buffer classes in SkTemplates.h more consistent #

Total comments: 2

Patch Set 4 : rebase #

Patch Set 5 : comments #

Patch Set 6 : Make container classes in SkTemplates.h more consistent #

Patch Set 7 : Make container classes in SkTemplates.h more consistent #

Patch Set 8 : Make container classes in SkTemplates.h more consistent #

Patch Set 9 : break dependency #

Unified diffs Side-by-side diffs Delta from patch set Stats (+75 lines, -6 lines) Patch
M include/private/SkTemplates.h View 1 2 3 4 5 6 chunks +19 lines, -6 lines 0 comments Download
M tests/TemplatesTest.cpp View 1 2 3 4 5 6 7 1 chunk +56 lines, -0 lines 0 comments Download

Messages

Total messages: 26 (11 generated)
csmartdalton
What do you guys think of this change?
4 years, 6 months ago (2016-06-22 02:17:19 UTC) #3
reed1
neutral -- if we're emulating/wrapping malloc, then null may not be as correct, since malloc ...
4 years, 6 months ago (2016-06-22 11:33:30 UTC) #5
csmartdalton
On 2016/06/22 11:33:30, reed1 wrote: > neutral -- if we're emulating/wrapping malloc, then null may ...
4 years, 6 months ago (2016-06-22 12:19:11 UTC) #6
bsalomon
I'm also neutral on this. Maybe you could show a use case? https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h File include/private/SkTemplates.h ...
4 years, 6 months ago (2016-06-22 13:30:29 UTC) #7
csmartdalton
On 2016/06/22 13:30:29, bsalomon wrote: > I'm also neutral on this. Maybe you could show ...
4 years, 6 months ago (2016-06-22 13:40:51 UTC) #8
csmartdalton
Make the changes as discussed earlier this morning. https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h File include/private/SkTemplates.h (right): https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h#newcode332 include/private/SkTemplates.h:332: SkASSERT(0 ...
4 years, 6 months ago (2016-06-23 17:07:46 UTC) #10
csmartdalton
Make the changes as discussed earlier this morning.
4 years, 6 months ago (2016-06-23 17:07:51 UTC) #11
csmartdalton
Make the changes as discussed earlier this morning.
4 years, 6 months ago (2016-06-23 17:07:55 UTC) #12
reed1
https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h File include/private/SkTemplates.h (right): https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h#newcode332 include/private/SkTemplates.h:332: SkASSERT(0 == count); On 2016/06/23 17:07:46, csmartdalton wrote: > ...
4 years, 6 months ago (2016-06-23 17:44:36 UTC) #13
bsalomon
lgtm https://codereview.chromium.org/2084213003/diff/40001/include/private/SkTemplates.h File include/private/SkTemplates.h (right): https://codereview.chromium.org/2084213003/diff/40001/include/private/SkTemplates.h#newcode212 include/private/SkTemplates.h:212: SkASSERT(0 == count); I think it'd be slightly ...
4 years, 6 months ago (2016-06-23 17:53:34 UTC) #14
csmartdalton
https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h File include/private/SkTemplates.h (right): https://codereview.chromium.org/2084213003/diff/1/include/private/SkTemplates.h#newcode332 include/private/SkTemplates.h:332: SkASSERT(0 == count); On 2016/06/23 17:44:36, reed1 wrote: > ...
4 years, 6 months ago (2016-06-23 18:07:26 UTC) #15
reed1
lgtm
4 years, 6 months ago (2016-06-23 18:31:08 UTC) #16
commit-bot: I haz the power
This CL has an open dependency (Issue 2085043002 Patch 100001). Please resolve the dependency and ...
4 years, 6 months ago (2016-06-23 19:16:51 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2084213003/150001
4 years, 6 months ago (2016-06-23 19:35:21 UTC) #24
commit-bot: I haz the power
4 years, 6 months ago (2016-06-23 19:55:17 UTC) #26
Message was sent while issue was closed.
Committed patchset #9 (id:150001) as
https://skia.googlesource.com/skia/+/d0e402f99949127624b5c5e6d673a44a71940489

Powered by Google App Engine
This is Rietveld 408576698