diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2011-10-09 19:36:06 +0000 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2011-10-09 19:36:06 +0000 |
commit | ac71a68c85a70ebe474e39ef64773112f6474514 (patch) | |
tree | d0cbedd1ea96a621dfddc70732269da7342c6502 /gdb/value.h | |
parent | e18b27534c2181c92dc9b685adc05bcf6b685817 (diff) | |
download | gdb-ac71a68c85a70ebe474e39ef64773112f6474514.zip gdb-ac71a68c85a70ebe474e39ef64773112f6474514.tar.gz gdb-ac71a68c85a70ebe474e39ef64773112f6474514.tar.bz2 |
gdb/
Make some lval_funcs methods to default on NULL.
* valops.c (value_fetch_lazy): Check if lval_computed read method is
NULL.
(value_assign): Check if lval_computed write method is NULL.
* value.h (struct lval_funcs): Comment NULL values for read and write
methods.
Diffstat (limited to 'gdb/value.h')
-rw-r--r-- | gdb/value.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/value.h b/gdb/value.h index 5d61a0b..83c94fc 100644 --- a/gdb/value.h +++ b/gdb/value.h @@ -156,13 +156,15 @@ struct lval_funcs { /* Fill in VALUE's contents. This is used to "un-lazy" values. If a problem arises in obtaining VALUE's bits, this function should - call 'error'. */ + call 'error'. If it is NULL value_fetch_lazy on "un-lazy" + non-optimized-out value is an internal error. */ void (*read) (struct value *v); /* Handle an assignment TOVAL = FROMVAL by writing the value of FROMVAL to TOVAL's location. The contents of TOVAL have not yet been updated. If a problem arises in doing so, this function - should call 'error'. */ + should call 'error'. If it is NULL such TOVAL assignment is an error as + TOVAL is not considered as an lvalue. */ void (*write) (struct value *toval, struct value *fromval); /* Check the validity of some bits in VALUE. This should return 1 |