diff options
author | 2012-07-21 19:39:24 +0000 | |
---|---|---|
committer | 2012-07-21 19:39:24 +0000 | |
commit | 0c6a736617d242547135b731adb8333581b2f2dc (patch) | |
tree | eec20f210e3556a558fdcfdeb711ca41af9a008b | |
parent | 80ba7964cde0f7805d76cf0170cf3b920146a007 (diff) |
include <new> since we use placement-new
git-svn-id: http://skia.googlecode.com/svn/trunk@4710 2bbb7eff-a529-9590-31e7-b0007b416f81
-rwxr-xr-x | src/core/SkTRefArray.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/SkTRefArray.h b/src/core/SkTRefArray.h index f352cf1ba5..7d00a4d699 100755 --- a/src/core/SkTRefArray.h +++ b/src/core/SkTRefArray.h @@ -10,6 +10,7 @@ #define SkTRefArray_DEFINED #include "SkThread.h" +#include <new> /** * Wrapper to manage thread-safe sharing of an array of T objects. The array @@ -23,12 +24,11 @@ public: obj->fCount = count; obj->fRefCnt = 1; - + T* array = const_cast<T*>(obj->begin()); for (int i = 0; i < count; ++i) { new (&array[i]) T; } - return obj; } |