mirror of
git://sourceware.org/git/libabigail.git
synced 2025-02-08 17:47:13 +00:00
Fix style cleanups
* include/abg-ir.h (method_type::{method_type, set_class_type, get_type, set_type}): Use type_base_sptr and class_decl_sptr instead of the full non-typedefed name. (method_type):Do some cleanups in the definition of the convenience typedefs. * src/abg-ir.cc (method_type::{method_type, set_class_type, get_type, set_type}): Use type_base_sptr and class_decl_sptr instead of the full non-typedefed name. * src/abg-writer.cc (write_class_decl): Add a comment. Signed-off-by: Dodji Seketeli <dodji@redhat.com>
This commit is contained in:
parent
1eecd89ee1
commit
421aa4ab5f
@ -2494,19 +2494,19 @@ public:
|
||||
/// Hasher for intances of method_type
|
||||
struct hash;
|
||||
|
||||
method_type(shared_ptr<type_base> return_type,
|
||||
shared_ptr<class_decl> class_type,
|
||||
method_type(type_base_sptr return_type,
|
||||
class_decl_sptr class_type,
|
||||
const std::vector<shared_ptr<function_decl::parameter> >& parms,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits);
|
||||
|
||||
method_type(shared_ptr<type_base> return_type,
|
||||
shared_ptr<type_base> class_type,
|
||||
method_type(type_base_sptr return_type,
|
||||
type_base_sptr class_type,
|
||||
const std::vector<shared_ptr<function_decl::parameter> >& parms,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits);
|
||||
|
||||
method_type(shared_ptr<class_decl> class_type,
|
||||
method_type(class_decl_sptr class_type,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits);
|
||||
|
||||
@ -2518,7 +2518,7 @@ public:
|
||||
{return class_decl_sptr(class_type_);}
|
||||
|
||||
void
|
||||
set_class_type(shared_ptr<class_decl> t);
|
||||
set_class_type(class_decl_sptr t);
|
||||
|
||||
virtual string
|
||||
get_pretty_representation(bool internal = false) const;
|
||||
@ -2905,15 +2905,15 @@ public:
|
||||
/// Convenience typedef
|
||||
/// @{
|
||||
typedef shared_ptr<base_spec> base_spec_sptr;
|
||||
typedef std::vector<base_spec_sptr> base_specs;
|
||||
typedef std::vector<type_base_sptr> member_types;
|
||||
typedef std::vector<var_decl_sptr> data_members;
|
||||
typedef vector<base_spec_sptr> base_specs;
|
||||
typedef vector<type_base_sptr> member_types;
|
||||
typedef vector<var_decl_sptr> data_members;
|
||||
typedef shared_ptr<method_decl> method_decl_sptr;
|
||||
typedef std::vector<method_decl_sptr> member_functions;
|
||||
typedef shared_ptr<member_function_template> member_function_template_sptr;
|
||||
typedef std::vector<member_function_template_sptr> member_function_templates;
|
||||
typedef shared_ptr<member_class_template> member_class_template_sptr;
|
||||
typedef std::vector<member_class_template_sptr> member_class_templates;
|
||||
typedef vector<method_decl_sptr> member_functions;
|
||||
typedef shared_ptr<member_function_template> member_function_template_sptr;
|
||||
typedef vector<member_function_template_sptr> member_function_templates;
|
||||
typedef shared_ptr<member_class_template> member_class_template_sptr;
|
||||
typedef vector<member_class_template_sptr> member_class_templates;
|
||||
/// @}
|
||||
|
||||
private:
|
||||
@ -3415,11 +3415,11 @@ public:
|
||||
|
||||
/// @return the type of the current instance of the
|
||||
/// class_decl::method_decl.
|
||||
const shared_ptr<method_type>
|
||||
const method_type_sptr
|
||||
get_type() const;
|
||||
|
||||
void
|
||||
set_type(shared_ptr<method_type> fn_type)
|
||||
set_type(const method_type_sptr fn_type)
|
||||
{function_decl::set_type(fn_type);}
|
||||
|
||||
friend bool
|
||||
|
@ -9701,12 +9701,11 @@ function_type::~function_type()
|
||||
///
|
||||
/// @param alignment_in_bits the alignment of an instance of
|
||||
/// method_type, expressed in bits.
|
||||
method_type::method_type
|
||||
(shared_ptr<type_base> return_type,
|
||||
shared_ptr<class_decl> class_type,
|
||||
const std::vector<shared_ptr<function_decl::parameter> >& parms,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits)
|
||||
method_type::method_type (type_base_sptr return_type,
|
||||
class_decl_sptr class_type,
|
||||
const std::vector<shared_ptr<function_decl::parameter> >& parms,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits)
|
||||
: type_base(size_in_bits, alignment_in_bits),
|
||||
function_type(return_type, parms, size_in_bits, alignment_in_bits)
|
||||
{set_class_type(class_type);}
|
||||
@ -9730,9 +9729,8 @@ method_type::method_type
|
||||
///
|
||||
/// @param alignment_in_bits the alignment of an instance of
|
||||
/// method_type, expressed in bits.
|
||||
|
||||
method_type::method_type(shared_ptr<type_base> return_type,
|
||||
shared_ptr<type_base> class_type,
|
||||
method_type::method_type(type_base_sptr return_type,
|
||||
type_base_sptr class_type,
|
||||
const std::vector<shared_ptr<function_decl::parameter> >& parms,
|
||||
size_t size_in_bits,
|
||||
size_t alignment_in_bits)
|
||||
|
@ -2443,6 +2443,8 @@ write_class_decl(const class_decl_sptr decl,
|
||||
{
|
||||
function_decl_sptr fn = *f;
|
||||
if (get_member_function_is_virtual(fn))
|
||||
// All virtual member functions are emitted together,
|
||||
// later.
|
||||
continue;
|
||||
|
||||
assert(!get_member_function_is_virtual(fn));
|
||||
|
Loading…
Reference in New Issue
Block a user