From 96fcdcc219d2a0d3579719b84b28bede76efba64 Mon Sep 17 00:00:00 2001 From: halcanary Date: Thu, 27 Aug 2015 07:41:13 -0700 Subject: Style Change: NULL->nullptr DOCS_PREVIEW= https://skia.org/?cl=1316233002 Review URL: https://codereview.chromium.org/1316233002 --- tests/DataRefTest.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'tests/DataRefTest.cpp') diff --git a/tests/DataRefTest.cpp b/tests/DataRefTest.cpp index 58600ef3ee..177c9d37d5 100644 --- a/tests/DataRefTest.cpp +++ b/tests/DataRefTest.cpp @@ -33,10 +33,10 @@ static void test_datatable_is_empty(skiatest::Reporter* reporter, static void test_emptytable(skiatest::Reporter* reporter) { SkAutoTUnref table0(SkDataTable::NewEmpty()); - SkAutoTUnref table1(SkDataTable::NewCopyArrays(NULL, NULL, 0)); - SkAutoTUnref table2(SkDataTable::NewCopyArray(NULL, 0, 0)); - SkAutoTUnref table3(SkDataTable::NewArrayProc(NULL, 0, 0, - NULL, NULL)); + SkAutoTUnref table1(SkDataTable::NewCopyArrays(nullptr, nullptr, 0)); + SkAutoTUnref table2(SkDataTable::NewCopyArray(nullptr, 0, 0)); + SkAutoTUnref table3(SkDataTable::NewArrayProc(nullptr, 0, 0, + nullptr, nullptr)); test_datatable_is_empty(reporter, table0); test_datatable_is_empty(reporter, table1); @@ -122,7 +122,7 @@ static void test_globaltable(skiatest::Reporter* reporter) { int count = SK_ARRAY_COUNT(gData); SkAutoTUnref table(SkDataTable::NewArrayProc(gData, - sizeof(gData[0]), count, NULL, NULL)); + sizeof(gData[0]), count, nullptr, nullptr)); REPORTER_ASSERT(reporter, table->count() == count); for (int i = 0; i < count; ++i) { @@ -168,7 +168,7 @@ static void test_cstring(skiatest::Reporter* reporter) { REPORTER_ASSERT(reporter, r0->equals(r1)); - SkAutoTUnref r2(SkData::NewWithCString(NULL)); + SkAutoTUnref r2(SkData::NewWithCString(nullptr)); REPORTER_ASSERT(reporter, 1 == r2->size()); REPORTER_ASSERT(reporter, 0 == *r2->bytes()); } @@ -193,13 +193,13 @@ static void test_files(skiatest::Reporter* reporter) { SkFILE* file = sk_fopen(path.c_str(), kRead_SkFILE_Flag); SkAutoTUnref r1(SkData::NewFromFILE(file)); - REPORTER_ASSERT(reporter, r1.get() != NULL); + REPORTER_ASSERT(reporter, r1.get() != nullptr); REPORTER_ASSERT(reporter, r1->size() == 26); REPORTER_ASSERT(reporter, strncmp(static_cast(r1->data()), s, 26) == 0); int fd = sk_fileno(file); SkAutoTUnref r2(SkData::NewFromFD(fd)); - REPORTER_ASSERT(reporter, r2.get() != NULL); + REPORTER_ASSERT(reporter, r2.get() != nullptr); REPORTER_ASSERT(reporter, r2->size() == 26); REPORTER_ASSERT(reporter, strncmp(static_cast(r2->data()), s, 26) == 0); } -- cgit v1.2.3