Commit Graph

1 Commits

Author SHA1 Message Date
Dodji Seketeli
a7e6fbbd7d Initial support for member class templates
* src/abg-ir.cc (class_decl::add_member_function_template): Fix
	comment.
	(class_decl::add_member_class_template)
	(class_decl::member_class_template::operator==)
	(class_decl::member_class_template_hash::operator()): New
	definitions.
	(class_decl::operator==): Compare member templates.  Fix logic.
	(class_decl::data_member_hash::operator())
	(class_decl::member_function_hash::operator())
	(class_decl::member_function_template_hash::operator()): Don't
	hash the is_static boolean as it's hashed as part of the 'member'
	sub-object hashing.
	(class_decl::member_function_template::operator==): Move this out
	of line here, from the header file.
	(class_decl_hash::operator()): Hash member class templates.
	* src/abg-ir.h (class_decl::member::{m_is_static,is_static}): Add the is_static
	boolean here, so that it's factorized out of the inherited classes
	of this class.
	(class_decl::data_member::{is_static, m_is_static})
	(class_decl::member_function::{is_static, m_is_static})
	(class_decl::member_function_template::{is_static, m_is_static}): Remove this
	as it's now part of the base 'member' class.
	(class_decl::data_member::operator==)
	(class_decl::member_function::operator==): Don't compare the
	is_static boolean as it's now compared as part of the 'member'
	sub-object comparison.
	(class_decl::member_function_template::operator==): Move this
	out-of-line into src/abg-ir.cc.
	(class class_decl::member_class_template, struct
	class_decl::member_class_template_hash)
	(class_decl::{add_member_class_template,
	get_member_class_templates}): New declarations.
	(class_decl::member_class_templates_type): New typedef.
	* src/abg-reader.cc (build_class_decl): Support de-serializing
	member class templates.
	* src/abg-writer.cc (write_class_decl): Likewise, support
	serializing member class templates.
	* tests/data/test-read-write/test16.xml: New test input.
	* tests/test-read-write.cc (int_out_specs[]): Add the new test
	input to the list of inputs that are de-serialized and serialized
	back.
	* tests/Makefile.am: Add the new test input to the distribution.
2013-07-23 23:13:51 +02:00