mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-13 04:13:33 +08:00
Move value_ref_policy methods out-of-line
This moves the value_ref_policy methods to be defined out-of-line. This is a necessary step to change value_incref and value_decref to be methods of value. Approved-By: Simon Marchi <simon.marchi@efficios.com>
This commit is contained in:
parent
e989e63761
commit
d3824ae14a
23
gdb/value.h
23
gdb/value.h
@ -124,15 +124,8 @@ extern void value_decref (struct value *val);
|
||||
|
||||
struct value_ref_policy
|
||||
{
|
||||
static void incref (struct value *ptr)
|
||||
{
|
||||
value_incref (ptr);
|
||||
}
|
||||
|
||||
static void decref (struct value *ptr)
|
||||
{
|
||||
value_decref (ptr);
|
||||
}
|
||||
static void incref (struct value *ptr);
|
||||
static void decref (struct value *ptr);
|
||||
};
|
||||
|
||||
/* A gdb:;ref_ptr pointer to a struct value. */
|
||||
@ -677,6 +670,18 @@ private:
|
||||
int length) const;
|
||||
};
|
||||
|
||||
inline void
|
||||
value_ref_policy::incref (struct value *ptr)
|
||||
{
|
||||
value_incref (ptr);
|
||||
}
|
||||
|
||||
inline void
|
||||
value_ref_policy::decref (struct value *ptr)
|
||||
{
|
||||
value_decref (ptr);
|
||||
}
|
||||
|
||||
/* Returns value_type or value_enclosing_type depending on
|
||||
value_print_options.objectprint.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user