aboutsummaryrefslogtreecommitdiff
path: root/gdb/value.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2011-01-12 01:23:29 +0000
committerMichael Snyder <msnyder@vmware.com>2011-01-12 01:23:29 +0000
commit581e13c1888512fde1bd3ff9e46f1a3ec4c337d7 (patch)
tree6104f612ad3b70552635a01f728f6d8b2f5612d5 /gdb/value.c
parentd2a0f0327276336e2bfcca47563b22da64df0496 (diff)
downloadgdb-581e13c1888512fde1bd3ff9e46f1a3ec4c337d7.zip
gdb-581e13c1888512fde1bd3ff9e46f1a3ec4c337d7.tar.gz
gdb-581e13c1888512fde1bd3ff9e46f1a3ec4c337d7.tar.bz2
2011-01-11 Michael Snyder <msnyder@vmware.com>
* ui-file.c: Comment cleanup, mostly periods and spaces. * ui-file.h: Ditto. * ui-out.c: Ditto. * ui-out.h: Ditto. * utils.c: Ditto. * v850-tdep.c: Ditto. * valarith.c: Ditto. * valops.c: Ditto. * valprint.c: Ditto. * valprint.h: Ditto. * value.c: Ditto. * value.h: Ditto. * varobj.c: Ditto. * varobj.h: Ditto. * vax-tdep.c: Ditto. * vec.c: Ditto. * vec.h: Ditto. * version.h: Ditto. * windows-nat.c: Ditto. * windows-tdep.c: Ditto. * xcoffread.c: Ditto. * xcoffsolib.c: Ditto. * xml-support.c: Ditto. * xstormy16-tdep.c: Ditto. * xtensa-tdep.c: Ditto. * xtensa-tdep.h: Ditto.
Diffstat (limited to 'gdb/value.c')
-rw-r--r--gdb/value.c36
1 files changed, 17 insertions, 19 deletions
diff --git a/gdb/value.c b/gdb/value.c
index ffc85d6..9769d83 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -44,7 +44,7 @@
#include "tracepoint.h"
-/* Prototypes for exported functions. */
+/* Prototypes for exported functions. */
void _initialize_values (void);
@@ -107,7 +107,7 @@ struct value
/* Only used for bitfields; position of start of field. For
gdbarch_bits_big_endian=0 targets, it is the position of the LSB. For
- gdbarch_bits_big_endian=1 targets, it is the position of the MSB. */
+ gdbarch_bits_big_endian=1 targets, it is the position of the MSB. */
int bitpos;
/* Only used for bitfields; the containing value. This allows a
@@ -214,7 +214,7 @@ struct value
int reference_count;
};
-/* Prototypes for local functions. */
+/* Prototypes for local functions. */
static void show_values (char *, int);
@@ -239,7 +239,7 @@ struct value_history_chunk
static struct value_history_chunk *value_history_chain;
-static int value_history_count; /* Abs number of last entry stored */
+static int value_history_count; /* Abs number of last entry stored. */
/* List of all value objects currently allocated
@@ -1672,7 +1672,7 @@ value_as_double (struct value *val)
return foo;
}
-/* Extract a value as a C pointer. Does not deallocate the value.
+/* Extract a value as a C pointer. Does not deallocate the value.
Note that val's type may not actually be a pointer; value_as_long
handles all the cases. */
CORE_ADDR
@@ -1851,7 +1851,7 @@ unpack_double (struct type *type, const gdb_byte *valaddr, int *invp)
int len;
int nosign;
- *invp = 0; /* Assume valid. */
+ *invp = 0; /* Assume valid. */
CHECK_TYPEDEF (type);
code = TYPE_CODE (type);
len = TYPE_LENGTH (type);
@@ -1921,7 +1921,7 @@ unpack_pointer (struct type *type, const gdb_byte *valaddr)
/* Get the value of the FIELDNO'th field (which must be static) of
TYPE. Return NULL if the field doesn't exist or has been
- optimized out. */
+ optimized out. */
struct value *
value_static_field (struct type *type, int fieldno)
@@ -1937,13 +1937,13 @@ value_static_field (struct type *type, int fieldno)
case FIELD_LOC_KIND_PHYSNAME:
{
char *phys_name = TYPE_FIELD_STATIC_PHYSNAME (type, fieldno);
- /*TYPE_FIELD_NAME (type, fieldno);*/
+ /* TYPE_FIELD_NAME (type, fieldno); */
struct symbol *sym = lookup_symbol (phys_name, 0, VAR_DOMAIN, 0);
if (sym == NULL)
{
/* With some compilers, e.g. HP aCC, static data members are
- reported as non-debuggable symbols */
+ reported as non-debuggable symbols. */
struct minimal_symbol *msym = lookup_minimal_symbol (phys_name,
NULL, NULL);
@@ -1985,7 +1985,7 @@ set_value_enclosing_type (struct value *val, struct type *new_encl_type)
/* Given a value ARG1 (offset by OFFSET bytes)
of a struct or union type ARG_TYPE,
extract and return the value of one of its (non-static) fields.
- FIELDNO says which field. */
+ FIELDNO says which field. */
struct value *
value_primitive_field (struct value *arg1, int offset,
@@ -2085,7 +2085,7 @@ value_primitive_field (struct value *arg1, int offset,
/* Given a value ARG1 of a struct or union type,
extract and return the value of one of its (non-static) fields.
- FIELDNO says which field. */
+ FIELDNO says which field. */
struct value *
value_field (struct value *arg1, int fieldno)
@@ -2098,8 +2098,7 @@ value_field (struct value *arg1, int fieldno)
J is an index into F which provides the desired method.
We only use the symbol for its address, so be happy with either a
- full symbol or a minimal symbol.
- */
+ full symbol or a minimal symbol. */
struct value *
value_fn_field (struct value **arg1p, struct fn_field *f,
@@ -2149,8 +2148,7 @@ value_fn_field (struct value **arg1p, struct fn_field *f,
value_addr (*arg1p)));
/* Move the `this' pointer according to the offset.
- VALUE_OFFSET (*arg1p) += offset;
- */
+ VALUE_OFFSET (*arg1p) += offset; */
}
return v;
@@ -2170,7 +2168,7 @@ value_fn_field (struct value **arg1p, struct fn_field *f,
number of bits from the LSB of the anonymous object to the LSB of the
bitfield.
- If the field is signed, we also do sign extension. */
+ If the field is signed, we also do sign extension. */
LONGEST
unpack_bits_as_long (struct type *field_type, const gdb_byte *valaddr,
@@ -2193,7 +2191,7 @@ unpack_bits_as_long (struct type *field_type, const gdb_byte *valaddr,
val = extract_unsigned_integer (valaddr + bitpos / 8,
bytes_read, byte_order);
- /* Extract bits. See comment above. */
+ /* Extract bits. See comment above. */
if (gdbarch_bits_big_endian (get_type_arch (field_type)))
lsbcount = (bytes_read * 8 - bitpos % 8 - bitsize);
@@ -2202,7 +2200,7 @@ unpack_bits_as_long (struct type *field_type, const gdb_byte *valaddr,
val >>= lsbcount;
/* If the field does not entirely fill a LONGEST, then zero the sign bits.
- If the field is signed, and is negative, then sign extend. */
+ If the field is signed, and is negative, then sign extend. */
if ((bitsize > 0) && (bitsize < 8 * (int) sizeof (val)))
{
@@ -2235,7 +2233,7 @@ unpack_field_as_long (struct type *type, const gdb_byte *valaddr, int fieldno)
/* Modify the value of a bitfield. ADDR points to a block of memory in
target byte order; the bitfield starts in the byte pointed to. FIELDVAL
is the desired value of the field, in host byte order. BITPOS and BITSIZE
- indicate which bits (in target bit order) comprise the bitfield.
+ indicate which bits (in target bit order) comprise the bitfield.
Requires 0 < BITSIZE <= lbits, 0 <= BITPOS % 8 + BITSIZE <= lbits, and
0 <= BITPOS, where lbits is the size of a LONGEST in bits. */