From 6ff4d8c61afc2ede16d60195dc30ea6538e2d5c9 Mon Sep 17 00:00:00 2001 From: Kevin Funk Date: Mon, 5 Dec 2016 13:18:57 +0100 Subject: [PATCH] QTest::addColumn: Use nullptr instead of 0 Fixes -Wzero-as-null-pointer-constant warning in user code Change-Id: I59492633d14947e90e91efa7c4fcd14c33fa413e Reviewed-by: Marc Mutz Reviewed-by: Thiago Macieira --- src/testlib/qtestcase.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/testlib/qtestcase.h b/src/testlib/qtestcase.h index c3ccfc3f8c..4c226830e9 100644 --- a/src/testlib/qtestcase.h +++ b/src/testlib/qtestcase.h @@ -309,7 +309,7 @@ namespace QTest Q_TESTLIB_EXPORT void addColumnInternal(int id, const char *name); template - inline void addColumn(const char *name, T * = 0) + inline void addColumn(const char *name, T * = nullptr) { typedef std::is_same QIsSameTConstChar; Q_STATIC_ASSERT_X(!QIsSameTConstChar::value, "const char* is not allowed as a test data format.");