From 1d02ac8371b1d3b31ed029c29fa23fadeca48787 Mon Sep 17 00:00:00 2001 From: Jason Merrill Date: Fri, 9 Jul 1999 08:44:37 -0400 Subject: decl2.c (reparse_absdcl_as_casts): Don't warn about old-style casts in system headers or extern "C" blocks. * decl2.c (reparse_absdcl_as_casts): Don't warn about old-style casts in system headers or extern "C" blocks. * decl2.c (write_virtuals): Deleted declaration. * cp-tree.h (write_virtuals): Deleted extern declaration. * class.c (finish_struct_1): Removed #if 0'd code that mentions write_virtuals. * semantics.c (begin_class_definition): Rewrite code to not depend on write_virtuals. * lex.c (cp_pragma_interface): New function. (cp_pragma_implementation): Likewise. (handle_cp_pragma): Call them. From-SVN: r28045 --- gcc/cp/semantics.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) (limited to 'gcc/cp/semantics.c') diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 1659ec8..059375b 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -1329,16 +1329,12 @@ begin_class_definition (t) SET_CLASSTYPE_INTERFACE_UNKNOWN_X (t, interface_unknown); } - - /* Record how to set the access of this class's - virtual functions. If write_virtuals == 3, then - inline virtuals are ``extern inline''. */ - if (write_virtuals == 3) - needs_writing = ! CLASSTYPE_INTERFACE_ONLY (t) - && CLASSTYPE_INTERFACE_KNOWN (t); - else - needs_writing = 1; - CLASSTYPE_VTABLE_NEEDS_WRITING (t) = needs_writing; + + /* Only leave this bit clear if we know this + class is part of an interface-only specification. */ + if (! CLASSTYPE_INTERFACE_KNOWN (t) + || ! CLASSTYPE_INTERFACE_ONLY (t)) + CLASSTYPE_VTABLE_NEEDS_WRITING (t) = 1; } #if 0 tmp = TYPE_IDENTIFIER ($0); -- cgit v1.1