string &return_type_name,
string &class_name,
vector<string>& parm_names,
- bool& is_const);
+ bool& is_const,
+ bool& is_static);
static string
die_function_signature(read_context& ctxt, Dwarf_Die *die, size_t where_offset);
string class_name;
vector<string> parm_names;
bool is_const = false;
+ bool is_static = false;
die_return_and_parm_names_from_fn_type_die(ctxt, die, where_offset,
/*pretty_print=*/true,
return_type_name, class_name,
- parm_names, is_const);
+ parm_names, is_const,
+ is_static);
if (return_type_name.empty())
return_type_name = "void";
///
/// @param is_const out parameter. If the function is a member
/// function, this is set to true iff the member function is const.
+///
+/// @param is_static out parameter. If the function is a static
+/// member function, then this is set to true.
static void
die_return_and_parm_names_from_fn_type_die(read_context& ctxt,
Dwarf_Die* die,
string &return_type_name,
string &class_name,
vector<string>& parm_names,
- bool& is_const)
+ bool& is_const,
+ bool& is_static)
{
Dwarf_Die child;
Dwarf_Die ret_type_die;
return_type_name = "void";
Dwarf_Die object_pointer_die, class_die;
- bool is_static = false;
bool is_method_type =
die_function_type_is_method_type(ctxt, die, where_offset,
object_pointer_die,
string class_name;
vector<string> parm_names;
bool is_const = false;
+ bool is_static = false;
die_return_and_parm_names_from_fn_type_die(ctxt, fn_die, where_offset,
/*pretty_print=*/false,
return_type_name, class_name,
- parm_names, is_const);
+ parm_names, is_const, is_static);
bool is_virtual = die_is_virtual(fn_die);
repr += ", ";
}
else
- if (!class_name.empty())
- // We are printing a method name, skip the implicit "this"
+ if (!is_static && !class_name.empty())
+ // We are printing a non-static method name, skip the implicit "this"
// parameter type.
continue;
repr += *i;
string class_name;
vector<string> parm_names;
bool is_const = false;
+ bool is_static = false;
die_return_and_parm_names_from_fn_type_die(ctxt, die, where_offset,
/*pretty_print=*/true,
return_type_name, class_name,
- parm_names, is_const);
+ parm_names, is_const,
+ is_static);
if (class_name.empty())
repr = "function type";
else