aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJason Merrill <jason@gcc.gnu.org>2002-07-24 12:23:14 -0400
committerJason Merrill <jason@gcc.gnu.org>2002-07-24 12:23:14 -0400
commit979b1d183472367e813ccae5f9ca7c8463f6cb26 (patch)
tree07bf4d009a8b0f196def3d72b1f2c8b2a07818a5 /gcc
parent7e51e626abae2f44754bf4a4f1a9bec9cc5fe8d1 (diff)
downloadgcc-979b1d183472367e813ccae5f9ca7c8463f6cb26.zip
gcc-979b1d183472367e813ccae5f9ca7c8463f6cb26.tar.gz
gcc-979b1d183472367e813ccae5f9ca7c8463f6cb26.tar.bz2
stop recommending -fexternal-templates
From-SVN: r55713
Diffstat (limited to 'gcc')
-rw-r--r--gcc/doc/extend.texi35
1 files changed, 0 insertions, 35 deletions
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
index c37701b..8fa3f99 100644
--- a/gcc/doc/extend.texi
+++ b/gcc/doc/extend.texi
@@ -7164,41 +7164,6 @@ each translation unit will contain instances of each of the templates it
uses. In a large program, this can lead to an unacceptable amount of code
duplication.
-@item
-@opindex fexternal-templates
-Add @samp{#pragma interface} to all files containing template
-definitions. For each of these files, add @samp{#pragma implementation
-"@var{filename}"} to the top of some @samp{.C} file which
-@samp{#include}s it. Then compile everything with
-@option{-fexternal-templates}. The templates will then only be expanded
-in the translation unit which implements them (i.e.@: has a @samp{#pragma
-implementation} line for the file where they live); all other files will
-use external references. If you're lucky, everything should work
-properly. If you get undefined symbol errors, you need to make sure
-that each template instance which is used in the program is used in the
-file which implements that template. If you don't have any use for a
-particular instance in that file, you can just instantiate it
-explicitly, using the syntax from the latest C++ working paper:
-
-@example
-template class A<int>;
-template ostream& operator << (ostream&, const A<int>&);
-@end example
-
-This strategy will work with code written for either model. If you are
-using code written for the Cfront model, the file containing a class
-template and the file containing its member templates should be
-implemented in the same translation unit.
-
-@item
-@opindex falt-external-templates
-A slight variation on this approach is to use the flag
-@option{-falt-external-templates} instead. This flag causes template
-instances to be emitted in the translation unit that implements the
-header where they are first instantiated, rather than the one which
-implements the file where the templates are defined. This header must
-be the same in all translation units, or things are likely to break.
-
@xref{C++ Interface,,Declarations and Definitions in One Header}, for
more discussion of these pragmas.
@end enumerate