aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorMark Mitchell <mark@codesourcery.com>2000-10-31 01:30:59 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>2000-10-31 01:30:59 +0000
commitad50e811dc95387b52dddd7ab753db59512a3baf (patch)
tree62873128afbebb3b4075750f0c2dbc4160b90b4b /gcc/testsuite
parent4bc950092b4a22757f6893f53c1d1ad8fd85381b (diff)
downloadgcc-ad50e811dc95387b52dddd7ab753db59512a3baf.zip
gcc-ad50e811dc95387b52dddd7ab753db59512a3baf.tar.gz
gcc-ad50e811dc95387b52dddd7ab753db59512a3baf.tar.bz2
cp-tree.h (DECL_EXTERNAL_LINKAGE_P): New macro.
* cp-tree.h (DECL_EXTERNAL_LINKAGE_P): New macro. (linkage_kind): New enumeration. (decl_linkage): New function. * decl2.c (comdat_linkage): Extend comment. * error.c (dump_function_decl): Print the arguments used to instantiate a template, even when not printing the type of the function. * pt.c (convert_nontype_argument): Use DECL_EXTERNAL_LINKAGE_P, not TREE_PUBLIC, to test for external linkage. * tree.c (decl_linkage): New function. From-SVN: r37150
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.other/linkage6.C18
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.other/linkage6.C b/gcc/testsuite/g++.old-deja/g++.other/linkage6.C
new file mode 100644
index 0000000..65374ca
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.other/linkage6.C
@@ -0,0 +1,18 @@
+// Build don't link:
+// Special g++ Options: -fno-weak
+// Origin: Mark Mitchell <mark@codesourcery.com>
+
+template <typename T>
+void f ();
+
+void h () { f<int> (); }
+
+template <void (*X)()>
+void g () {}
+
+template <typename T>
+void f ()
+{
+ g<&f<T> >();
+}
+