+1999-03-25 Jason Merrill <jason@yorick.cygnus.com>
+
+ * decl2.c (comdat_linkage): Treat vtables like functions.
+
1999-03-25 Mark Mitchell <mark@codesourcery.com>
* pt.c (tsubst_decl): Tsubst into DECL_BEFRIENDING_CLASSES.
{
if (flag_weak)
make_decl_one_only (decl);
- else if (TREE_CODE (decl) == FUNCTION_DECL)
+ else if (TREE_CODE (decl) == FUNCTION_DECL || DECL_VIRTUAL_P (decl))
+ /* We can just emit functions and vtables statically; it doesn't really
+ matter if we have multiple copies. */
TREE_PUBLIC (decl) = 0;
else
{
+ /* Static data member template instantiations, however, cannot
+ have multiple copies. */
if (DECL_INITIAL (decl) == 0
|| DECL_INITIAL (decl) == error_mark_node)
DECL_COMMON (decl) = 1;