aboutsummaryrefslogtreecommitdiff
path: root/sources
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2018-03-15 15:27:13 -0700
committerElliott Hughes <enh@google.com>2018-03-15 15:27:13 -0700
commitbbaff93af4be14829a3c990faf48f77536588d19 (patch)
tree4386dba1f49114ee9389e345f62cfbed4517dcd4 /sources
parent381321633d20a756ac4cf21e95302f38639df560 (diff)
downloadndk-bbaff93af4be14829a3c990faf48f77536588d19.tar.gz
Add nullptr_t to the "system STL"'s <cstddef>.
Bug: http://b/65466378 Test: test builds Change-Id: Id9693ae4749d15b01a0f04d32f3b790bd089c5a8
Diffstat (limited to 'sources')
-rw-r--r--sources/cxx-stl/system/include/cstddef19
1 files changed, 9 insertions, 10 deletions
diff --git a/sources/cxx-stl/system/include/cstddef b/sources/cxx-stl/system/include/cstddef
index cb06b49c8..91fb7af00 100644
--- a/sources/cxx-stl/system/include/cstddef
+++ b/sources/cxx-stl/system/include/cstddef
@@ -1,4 +1,3 @@
-/* -*- c++ -*- */
/*
* Copyright (C) 2009 The Android Open Source Project
* All rights reserved.
@@ -30,21 +29,21 @@
#ifndef BIONIC_LIBSTDCPP_INCLUDE_CSTDDEF__
#define BIONIC_LIBSTDCPP_INCLUDE_CSTDDEF__
-/*
- * Standard C++ Library wrapper around the C stddef.h header file.
- * The following 2 types are also declared in the 'std' namespace:
- * . ptrdiff_t
- * . size_t
- */
#include <stddef.h>
extern "C++" {
namespace std {
+
using ::ptrdiff_t;
using ::size_t;
-} // namespace std
-} // extern C++
+#if __cplusplus >= 201103L
+typedef decltype(nullptr) nullptr_t;
+#endif
+
+}
+
+}
-#endif // BIONIC_LIBSTDCPP_INCLUDE_CSTDDEF__
+#endif