[libc++] Replace several uses of 0 by nullptr

Differential Revision: https://reviews.llvm.org/D43159

GitOrigin-RevId: 527a7fdfbd7461e2aaa9eb279543c5d9dc8efa5a
diff --git a/src/stdlib_new_delete.cpp b/src/stdlib_new_delete.cpp
index 643108f..9df8454 100644
--- a/src/stdlib_new_delete.cpp
+++ b/src/stdlib_new_delete.cpp
@@ -27,7 +27,7 @@
     if (size == 0)
         size = 1;
     void* p;
-    while ((p = ::malloc(size)) == 0)
+    while ((p = ::malloc(size)) == nullptr)
     {
         // If malloc fails and there is a new_handler,
         // call it to try free up memory.
@@ -48,7 +48,7 @@
 void*
 operator new(size_t size, const std::nothrow_t&) _NOEXCEPT
 {
-    void* p = 0;
+    void* p = nullptr;
 #ifndef _LIBCXXABI_NO_EXCEPTIONS
     try
     {
@@ -74,7 +74,7 @@
 void*
 operator new[](size_t size, const std::nothrow_t&) _NOEXCEPT
 {
-    void* p = 0;
+    void* p = nullptr;
 #ifndef _LIBCXXABI_NO_EXCEPTIONS
     try
     {
@@ -170,7 +170,7 @@
 void*
 operator new(size_t size, std::align_val_t alignment, const std::nothrow_t&) _NOEXCEPT
 {
-    void* p = 0;
+    void* p = nullptr;
 #ifndef _LIBCXXABI_NO_EXCEPTIONS
     try
     {
@@ -196,7 +196,7 @@
 void*
 operator new[](size_t size, std::align_val_t alignment, const std::nothrow_t&) _NOEXCEPT
 {
-    void* p = 0;
+    void* p = nullptr;
 #ifndef _LIBCXXABI_NO_EXCEPTIONS
     try
     {