+2000-08-02 Mark Mitchell <mark@codesourcery.com>
+
+ * cp-tree.h (DECL_NEEDED_P): Tweak.
+
2000-07-28 Jason Merrill <jason@redhat.com>
* lang-specs.h: Use %i in rule for .ii files.
anything that isn't comdat, but we don't know for sure whether or
not something is comdat until end-of-file. */
#define DECL_NEEDED_P(DECL) \
- ((at_eof && !DECL_COMDAT (DECL)) \
+ ((at_eof && TREE_PUBLIC (DECL) && !DECL_COMDAT (DECL)) \
|| (TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME ((DECL)))) \
|| (flag_syntax_only && TREE_USED ((DECL))))