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

Unified Diff: include/core/SkColorTable.h

Issue 1311893010: Specialize SkOncePtr<T[]>. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | include/private/SkOncePtr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkColorTable.h
diff --git a/include/core/SkColorTable.h b/include/core/SkColorTable.h
index ff2bf7cde205e895300a9e816dff407c3c382bb4..cb613befb1756499a48ca882cf5ecee794c2901f 100644
--- a/include/core/SkColorTable.h
+++ b/include/core/SkColorTable.h
@@ -61,11 +61,9 @@ private:
// assumes ownership of colors (assumes it was allocated w/ malloc)
SkColorTable(SkPMColor* colors, int count, AllocatedWithMalloc);
- struct Free16BitCache { void operator()(uint16_t* cache) const { sk_free(cache); } };
-
- SkPMColor* fColors;
- SkOncePtr<uint16_t, Free16BitCache> f16BitCache;
- int fCount;
+ SkPMColor* fColors;
+ SkOncePtr<uint16_t[]> f16BitCache;
+ int fCount;
void init(const SkPMColor* colors, int count);
« no previous file with comments | « no previous file | include/private/SkOncePtr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698