summaryrefslogtreecommitdiff
path: root/include/getopt.h
diff options
context:
space:
mode:
authorsayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2002-10-27 00:54:50 +0000
committersayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2002-10-27 00:54:50 +0000
commit4a1587e6f52fb79d2128ff78d6566a9bfd4bdcad (patch)
tree5e3ada24f03a30ad8a8fc940a03f7dda5731d22f /include/getopt.h
parent47a2de94fde874a46705dcca42c192cce2b13bb0 (diff)
downloadgcc-4a1587e6f52fb79d2128ff78d6566a9bfd4bdcad.tar.gz
PR bootstrap/8351
* getopt.h: Avoid prototyping getopt with no arguments in C++. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58569 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'include/getopt.h')
-rw-r--r--include/getopt.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/getopt.h b/include/getopt.h
index da09cee3be1..9495a4846fd 100644
--- a/include/getopt.h
+++ b/include/getopt.h
@@ -112,7 +112,9 @@ struct option
errors, only prototype getopt for the GNU C library. */
extern int getopt (int argc, char *const *argv, const char *shortopts);
#else
+#ifndef __cplusplus
extern int getopt ();
+#endif /* __cplusplus */
#endif
#endif /* !HAVE_DECL_GETOPT */