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

Unified Diff: tests/LazyPtrTest.cpp

Issue 1316123003: Style Change: SkNEW->new; SkDELETE->delete (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-26 (Wednesday) 15:59:00 EDT Created 5 years, 4 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 | « tests/LayerRasterizerTest.cpp ('k') | tests/PDFInvalidBitmapTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/LazyPtrTest.cpp
diff --git a/tests/LazyPtrTest.cpp b/tests/LazyPtrTest.cpp
index 89443f9a808e7cafd5291e4e42b0604e162aa4ad..c6ffd72e2547385abc6fcf3b061dc3bb70e45f26 100644
--- a/tests/LazyPtrTest.cpp
+++ b/tests/LazyPtrTest.cpp
@@ -14,7 +14,7 @@ namespace {
struct CreateIntFromFloat {
CreateIntFromFloat(float val) : fVal(val) {}
- int* operator()() const { return SkNEW_ARGS(int, ((int)fVal)); }
+ int* operator()() const { return new int((int)fVal); }
float fVal;
};
@@ -24,7 +24,7 @@ void custom_destroy(int* ptr) { *ptr = 99; }
} // namespace
DEF_TEST(LazyPtr, r) {
- // Basic usage: calls SkNEW(int).
+ // Basic usage: calls new int.
SkLazyPtr<int> lazy;
int* ptr = lazy.get();
REPORTER_ASSERT(r, ptr);
@@ -48,7 +48,7 @@ DEF_TEST(LazyPtr, r) {
REPORTER_ASSERT(r, ptr);
REPORTER_ASSERT(r, 99 == *ptr);
// Since custom_destroy didn't actually delete ptr, we do now.
- SkDELETE(ptr);
+ delete ptr;
}
DEF_TEST(LazyPtr_Threaded, r) {
« no previous file with comments | « tests/LayerRasterizerTest.cpp ('k') | tests/PDFInvalidBitmapTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698