aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3
diff options
context:
space:
mode:
authorBernd Edlinger <bernd.edlinger@hotmail.de>2016-02-01 11:13:40 +0000
committerJonathan Wakely <redi@gcc.gnu.org>2016-02-01 11:13:40 +0000
commit571512d5f54f0fdf9c06f9a348e46ddbab8a5088 (patch)
tree7ac2f4a6390cb6f754d2f262c9f6e8c29fdab738 /libstdc++-v3
parent04bd58cf162fc15b4308579036c4f26275060e7b (diff)
downloadgcc-571512d5f54f0fdf9c06f9a348e46ddbab8a5088.zip
gcc-571512d5f54f0fdf9c06f9a348e46ddbab8a5088.tar.gz
gcc-571512d5f54f0fdf9c06f9a348e46ddbab8a5088.tar.bz2
Don't define guard macros when doing #include_next in math.h and stdlib.h
2016-02-01 Bernd Edlinger <bernd.edlinger@hotmail.de> PR libstdc++/69581 * include/c_compatibility/math.h: Move header guards. * include/c_compatibility/stdlib.h: Likewise. From-SVN: r233035
Diffstat (limited to 'libstdc++-v3')
-rw-r--r--libstdc++-v3/ChangeLog6
-rw-r--r--libstdc++-v3/include/c_compatibility/math.h10
-rw-r--r--libstdc++-v3/include/c_compatibility/stdlib.h11
3 files changed, 16 insertions, 11 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index b4aae43..3edd72b 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,9 @@
+2016-02-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
+
+ PR libstdc++/69581
+ * include/c_compatibility/math.h: Move header guards.
+ * include/c_compatibility/stdlib.h: Likewise.
+
2016-01-29 Jonathan Wakely <jwakely@redhat.com>
PR libstdc++/69506
diff --git a/libstdc++-v3/include/c_compatibility/math.h b/libstdc++-v3/include/c_compatibility/math.h
index 243e631..1f579ee 100644
--- a/libstdc++-v3/include/c_compatibility/math.h
+++ b/libstdc++-v3/include/c_compatibility/math.h
@@ -26,13 +26,13 @@
* This is a Standard C++ Library header.
*/
+#if !defined __cplusplus || defined _GLIBCXX_INCLUDE_NEXT_C_HEADERS
+# include_next <math.h>
+#else
#ifndef _GLIBCXX_MATH_H
#define _GLIBCXX_MATH_H 1
-#if !defined __cplusplus || defined _GLIBCXX_INCLUDE_NEXT_C_HEADERS
-# include_next <math.h>
-#else
# include <cmath>
using std::abs;
@@ -177,7 +177,5 @@ using std::sph_neumannl;
using std::sph_neumann;
#endif // __STDCPP_WANT_MATH_SPEC_FUNCS__
-#endif // __cplusplus
-
#endif // _GLIBCXX_MATH_H
-
+#endif // __cplusplus
diff --git a/libstdc++-v3/include/c_compatibility/stdlib.h b/libstdc++-v3/include/c_compatibility/stdlib.h
index 31e7e5f..747ad76 100644
--- a/libstdc++-v3/include/c_compatibility/stdlib.h
+++ b/libstdc++-v3/include/c_compatibility/stdlib.h
@@ -26,12 +26,13 @@
* This is a Standard C++ Library header.
*/
-#ifndef _GLIBCXX_STDLIB_H
-#define _GLIBCXX_STDLIB_H 1
-
#if !defined __cplusplus || defined _GLIBCXX_INCLUDE_NEXT_C_HEADERS
# include_next <stdlib.h>
#else
+
+#ifndef _GLIBCXX_STDLIB_H
+#define _GLIBCXX_STDLIB_H 1
+
# include <cstdlib>
using std::abort;
@@ -81,5 +82,5 @@ using std::wctomb;
#endif // _GLIBCXX_USE_WCHAR_T
#endif
-#endif
-#endif
+#endif // _GLIBCXX_STDLIB_H
+#endif // __cplusplus