aboutsummaryrefslogtreecommitdiff
path: root/fixincludes/tests
diff options
context:
space:
mode:
authorRainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>2017-01-13 12:09:13 +0000
committerRainer Orth <ro@gcc.gnu.org>2017-01-13 12:09:13 +0000
commit2252a8025df20cb5c58659cde04ac0ee0eee3ee1 (patch)
tree7409cd5362bbab1784a96fbdfb5284ad35c4d7b6 /fixincludes/tests
parenta181b2bcd7d3d8e7af0f4503b5425ea0b5738c82 (diff)
downloadgcc-2252a8025df20cb5c58659cde04ac0ee0eee3ee1.zip
gcc-2252a8025df20cb5c58659cde04ac0ee0eee3ee1.tar.gz
gcc-2252a8025df20cb5c58659cde04ac0ee0eee3ee1.tar.bz2
Only declare gets for C++ < 2014 on Solaris (PR libstdc++/78979)
PR libstdc++/78979 * inclhack.def (solaris_gets_c11, solaris_gets_cxx14) (solaris_std_gets_cxx14, solaris_stdlib_noreturn): New fixes. * fixincl.x: Regenerate. * tests/base/iso/stdio_iso.h [SOLARIS_GETS_C11_CHECK, SOLARIS_GETS_CXX14_CHECK, SOLARIS_STD_GETS_CXX14_CHECK, SOLARIS_STDLIB_NORETURN_CHECK]: New tests. From-SVN: r244428
Diffstat (limited to 'fixincludes/tests')
-rw-r--r--fixincludes/tests/base/iso/stdio_iso.h13
-rw-r--r--fixincludes/tests/base/iso/stdlib_c99.h14
-rw-r--r--fixincludes/tests/base/stdio.h7
3 files changed, 34 insertions, 0 deletions
diff --git a/fixincludes/tests/base/iso/stdio_iso.h b/fixincludes/tests/base/iso/stdio_iso.h
index d476752..e2d70b4 100644
--- a/fixincludes/tests/base/iso/stdio_iso.h
+++ b/fixincludes/tests/base/iso/stdio_iso.h
@@ -12,3 +12,16 @@
#if defined( SOLARIS_GETC_STRICT_STDC_CHECK )
#if !defined(_REENTRANT) && !defined(_LP64) && (!defined(_STRICT_STDC) || (__cplusplus >= 199711L))
#endif /* SOLARIS_GETC_STRICT_STDC_CHECK */
+
+
+#if defined( SOLARIS_GETS_C11_CHECK )
+#if __STDC_VERSION__ < 201112L && __cplusplus < 201402L
+extern char *gets(char *) __attribute__((__deprecated__));
+#endif
+#endif /* SOLARIS_GETS_C11_CHECK */
+
+
+#if defined( SOLARIS_GETS_CXX14_CHECK )
+#if __STDC_VERSION__ < 201112L && __cplusplus < 201402L
+extern char *gets(char *) __ATTR_DEPRECATED;
+#endif /* SOLARIS_GETS_CXX14_CHECK */
diff --git a/fixincludes/tests/base/iso/stdlib_c99.h b/fixincludes/tests/base/iso/stdlib_c99.h
new file mode 100644
index 0000000..0c500de
--- /dev/null
+++ b/fixincludes/tests/base/iso/stdlib_c99.h
@@ -0,0 +1,14 @@
+/* DO NOT EDIT THIS FILE.
+
+ It has been auto-edited by fixincludes from:
+
+ "fixinc/tests/inc/iso/stdlib_c99.h"
+
+ This had to be done to correct non-standard usages in the
+ original, manufacturer supplied header file. */
+
+
+
+#if defined( SOLARIS_STDLIB_NORETURN_CHECK )
+extern void quick_exit(int) __attribute__((__noreturn__));
+#endif /* SOLARIS_STDLIB_NORETURN_CHECK */
diff --git a/fixincludes/tests/base/stdio.h b/fixincludes/tests/base/stdio.h
index 4ca4faf..491c75d 100644
--- a/fixincludes/tests/base/stdio.h
+++ b/fixincludes/tests/base/stdio.h
@@ -90,6 +90,13 @@ using std::__flsbuf;
#endif /* SOLARIS_STD___FILBUF_CHECK */
+#if defined( SOLARIS_STD_GETS_CXX14_CHECK )
+#if __cplusplus < 201402L
+using std::gets;
+#endif
+#endif /* SOLARIS_STD_GETS_CXX14_CHECK */
+
+
#if defined( STDIO_STDARG_H_CHECK )
#endif /* STDIO_STDARG_H_CHECK */