cp-tree.h (struct lang_type_class): add field for key method
authorMatt Austern <austern@apple.com>
Fri, 3 Jan 2003 19:48:55 +0000 (19:48 +0000)
committerMatt Austern <austern@gcc.gnu.org>
Fri, 3 Jan 2003 19:48:55 +0000 (19:48 +0000)
commit9aad8f83a8c33f5af53fa712234677766716659d
treefcf7fb52bf769a2736649a456198023537d5a286
parent6cce57b0d073bc545a9a2855885e65a4ca43ce4d
cp-tree.h (struct lang_type_class): add field for key method

        * cp-tree.h (struct lang_type_class): add field for key method
        (cp_global_trees): rename dynamic_classes to keyed_classes
        (key_method): add definition
        * class.c (finish_struct_1): compute class's key method, and add
        the class to keyed_classes list if there is no key method.
        * decl.c (finish_function): add class to keyed_classes list if we
        see a definition of the class's key method.
        * pt.c (instantiate_class_template): add template specialization
        of a dynamic class to keyed_classes list.
        * decl2.c (key_method): remove
        (finish_file): iterate only through keyed_classes list when
        deciding whether to emit vtables, remove class from its list after
        we do the emission.

From-SVN: r60850
gcc/cp/ChangeLog
gcc/cp/class.c
gcc/cp/cp-tree.h
gcc/cp/decl.c
gcc/cp/decl2.c
gcc/cp/pt.c