[libc++abi] Use std::nullptr_t instead of declaring it manually
authorRyan Prichard <rprichard@google.com>
Fri, 4 Nov 2022 22:51:44 +0000 (15:51 -0700)
committerRyan Prichard <rprichard@google.com>
Fri, 4 Nov 2022 22:51:44 +0000 (15:51 -0700)
commit292533324cadf0164a7e1d532508cb59775e0a72
tree3906b3a3781f9c5ef96683d3f3e6dad8ac1deba9
parentada6aa3f5c9693130747549f99b6bb27cff58f2f
[libc++abi] Use std::nullptr_t instead of declaring it manually

Sometimes libc++'s stddef.h wrapper gets included, which defines
::nullptr_t. This test is compiled with -Wshadow -Werror, so shadowing
::nullptr_t with a nullptr_t in main is an error. Include cstddef,
which is guaranteed to define std::nullptr_t in C++11 and forward.

Reviewed By: ldionne, #libc_abi

Differential Revision: https://reviews.llvm.org/D137127
libcxxabi/test/catch_reference_nullptr.pass.cpp