aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@codesourcery.com>2000-07-25 20:17:28 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2000-07-25 20:17:28 +0000
commit7b300d1385d166fbb827450f969af269270430d8 (patch)
treee1fc72238d2233dc9f061fa05a7a5cf6fbbe273f
parent2c05a794ae84153cc6c67464d6ef9d459b45cb28 (diff)
downloadgcc-7b300d1385d166fbb827450f969af269270430d8.zip
gcc-7b300d1385d166fbb827450f969af269270430d8.tar.gz
gcc-7b300d1385d166fbb827450f969af269270430d8.tar.bz2
invoke.texi (strict-prototypes): Remove.
* invoke.texi (strict-prototypes): Remove. * extend.texi (Deprecated Features): Add strict-prototypes. (Backwards Compatibility): New node. From-SVN: r35253
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/extend.texi38
-rw-r--r--gcc/invoke.texi15
3 files changed, 45 insertions, 14 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 6da8a26..b1e123a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2000-07-25 Nathan Sidwell <nathan@codesourcery.com>
+
+ * invoke.texi (strict-prototypes): Remove.
+ * extend.texi (Deprecated Features): Add strict-prototypes.
+ (Backwards Compatibility): New node.
+
2000-07-25 Jakub Jelinek <jakub@redhat.com>
* config/i386/i386.md (andsi_1+1): Allow HImode.
diff --git a/gcc/extend.texi b/gcc/extend.texi
index 6eefa62..88efe7c 100644
--- a/gcc/extend.texi
+++ b/gcc/extend.texi
@@ -66,6 +66,7 @@ C++ Language}, for extensions that apply @emph{only} to C++.
* Return Address:: Getting the return or frame address of a function.
* Other Builtins:: Other built-in functions.
* Deprecated Features:: Things might disappear from g++.
+* Backwards Compatibility:: Compatibilities with earlier definitions of C++.
@end menu
@end ifset
@ifclear INTERNALS
@@ -114,6 +115,7 @@ C++ Language}, for extensions that apply @emph{only} to C++.
function.
* Return Address:: Getting the return or frame address of a function.
* Deprecated Features:: Things might disappear from g++.
+* Backwards Compatibility:: Compatibilities with earlier definitions of C++.
* Other Builtins:: Other built-in functions.
@end menu
@end ifclear
@@ -3292,6 +3294,42 @@ defines how template definitions have to be organized across
implementation units. g++ has an implicit instantiation mechanism that
should work just fine for standard-conforming code.
+@item -fstrict-prototype
+@itemx -fno-strict-prototype
+Previously it was possible to use an empty prototype parameter list to
+indicate an unspecified number of parameters (like C), rather than no
+parameters, as C++ demands. This feature has been removed, except where
+it is required for backwards compatibility @xref{Backwards Compatibility}
+
+@end table
+
+@node Backwards Compatibility
+@section Backwards Compatibility
+@cindex Backwards Compatibility
+@cindex ARM
+
+Now that there is a definitive ISO standard C++, g++ has a specification
+to adhere to. The C++ language evolved over time, and features that used
+to be acceptable in previous drafts of the standard, such as the ARM, are
+no longer accepted. In order to allow compilation of C++ written to such
+drafts, g++ contains some backwards compatibilities. @emph{All such
+backwards compatibility features are liable to disappear in future
+versions of g++.} They should be considered deprecated @xref{Deprecated
+Features}.
+
+@table @code
+@item For scope
+If a variable is declared at for scope, it used to remain in scope until
+the end of the scope which contained the for statement (rather than just
+within the for scope). g++ retains this, but issues a warning, if such a
+variable is accessed outside the for scope.
+
+@item implicit C language
+Old C system header files did not contain an @code{extern "C" @{...@}}
+scope to set the language. On such systems, all header files are
+implicitly scoped inside a C language scope. Also, an empty prototype
+@code{()} will be treated as an unspecified number of arguments, rather
+than no arguments, as C++ demands.
@end table
@node C++ Extensions
diff --git a/gcc/invoke.texi b/gcc/invoke.texi
index cb3b6a3..382fb7b 100644
--- a/gcc/invoke.texi
+++ b/gcc/invoke.texi
@@ -111,7 +111,7 @@ in the following sections.
-fhuge-objects -fno-implicit-templates -finit-priority
-fno-implement-inlines -fname-mangling-version-@var{n}
-fno-default-inline -fno-operator-names -fno-optional-diags -fpermissive
--frepo -fstrict-prototype -fsquangle -ftemplate-depth-@var{n}
+-frepo -fsquangle -ftemplate-depth-@var{n}
-fuse-cxa-atexit -fvtable-thunks -nostdinc++ -Wctor-dtor-privacy
-Wno-deprecated -Weffc++ -Wno-non-template-friend -Wnon-virtual-dtor
-Wold-style-cast -Woverloaded-virtual -Wno-pmf-conversions -Wreorder
@@ -1209,19 +1209,6 @@ of the language, you can save some space by using this flag. Note that
exception handling uses the same information, but it will generate it as
needed.
-@item -fstrict-prototype
-Within an @samp{extern "C"} linkage specification, treat a function
-declaration with no arguments, such as @samp{int foo ();}, as declaring
-the function to take no arguments. Normally, such a declaration means
-that the function @code{foo} can take any combination of arguments, as
-in C. @samp{-pedantic} implies @samp{-fstrict-prototype} unless
-overridden with @samp{-fno-strict-prototype}.
-
-Specifying this option will also suppress implicit declarations of
-functions.
-
-This flag no longer affects declarations with C++ linkage.
-
@item -fsquangle
@itemx -fno-squangle
@samp{-fsquangle} will enable a compressed form of name mangling for