Reorganise struct bfd
[deliverable/binutils-gdb.git] / gdb / value.h
index f03cf76676579745d67622aa71d779f1bfedd9aa..c2e9faf9c284c928b4e843442cede10b188ca847 100644 (file)
@@ -1,6 +1,6 @@
 /* Definitions for values of C expressions, for GDB.
 
-   Copyright (C) 1986-2013 Free Software Foundation, Inc.
+   Copyright (C) 1986-2014 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -31,6 +31,7 @@ struct type;
 struct ui_file;
 struct language_defn;
 struct value_print_options;
+struct xmethod_worker;
 
 /* The structure which defines the type of a value.  It should never
    be possible for a program lval value to survive over a call to the
@@ -273,6 +274,11 @@ extern void set_value_lazy (struct value *value, int val);
 extern int value_stack (struct value *);
 extern void set_value_stack (struct value *value, int val);
 
+/* Throw an error complaining that the value has been optimized
+   out.  */
+
+extern void error_value_optimized_out (void);
+
 /* value_contents() and value_contents_raw() both return the address
    of the gdb buffer used to hold a copy of the contents of the lval.
    value_contents() is used when the contents of the buffer are needed
@@ -431,6 +437,14 @@ extern int value_bits_synthetic_pointer (const struct value *value,
 extern int value_bytes_available (const struct value *value,
                                  int offset, int length);
 
+/* Given a value, determine whether the contents bits starting at
+   OFFSET and extending for LENGTH bits are available.  This returns
+   nonzero if all bits in the given range are available, zero if any
+   bit is unavailable.  */
+
+extern int value_bits_available (const struct value *value,
+                                int offset, int length);
+
 /* Like value_bytes_available, but return false if any byte in the
    whole object is unavailable.  */
 extern int value_entirely_available (struct value *value);
@@ -445,6 +459,12 @@ extern int value_entirely_unavailable (struct value *value);
 extern void mark_value_bytes_unavailable (struct value *value,
                                          int offset, int length);
 
+/* Mark VALUE's content bits starting at OFFSET and extending for
+   LENGTH bits as unavailable.  */
+
+extern void mark_value_bits_unavailable (struct value *value,
+                                        int offset, int length);
+
 /* Compare LENGTH bytes of VAL1's contents starting at OFFSET1 with
    LENGTH bytes of VAL2's contents starting at OFFSET2.
 
@@ -555,14 +575,17 @@ extern struct value *value_from_history_ref (char *, char **);
 extern struct value *value_at (struct type *type, CORE_ADDR addr);
 extern struct value *value_at_lazy (struct type *type, CORE_ADDR addr);
 
+extern struct value *value_from_contents_and_address_unresolved
+     (struct type *, const gdb_byte *, CORE_ADDR);
 extern struct value *value_from_contents_and_address (struct type *,
                                                      const gdb_byte *,
                                                      CORE_ADDR);
 extern struct value *value_from_contents (struct type *, const gdb_byte *);
 
-extern struct value *default_value_from_register (struct type *type,
+extern struct value *default_value_from_register (struct gdbarch *gdbarch,
+                                                 struct type *type,
                                                  int regnum,
-                                                 struct frame_info *frame);
+                                                 struct frame_id frame_id);
 
 extern void read_frame_register_value (struct value *value,
                                       struct frame_info *frame);
@@ -570,7 +593,7 @@ extern void read_frame_register_value (struct value *value,
 extern struct value *value_from_register (struct type *type, int regnum,
                                          struct frame_info *frame);
 
-extern CORE_ADDR address_from_register (struct type *type, int regnum,
+extern CORE_ADDR address_from_register (int regnum,
                                        struct frame_info *frame);
 
 extern struct value *value_of_variable (struct symbol *var,
@@ -593,7 +616,6 @@ extern struct value *default_read_var_value (struct symbol *var,
 
 extern struct value *allocate_value (struct type *type);
 extern struct value *allocate_value_lazy (struct type *type);
-extern void allocate_value_contents (struct value *value);
 extern void value_contents_copy (struct value *dst, int dst_offset,
                                 struct value *src, int src_offset,
                                 int length);
@@ -652,8 +674,13 @@ extern struct value *value_struct_elt (struct value **argp,
                                       const char *name, int *static_memfuncp,
                                       const char *err);
 
+extern struct value *value_struct_elt_bitpos (struct value **argp,
+                                             int bitpos,
+                                             struct type *field_type,
+                                             const char *err);
+
 extern struct value *value_aggregate_elt (struct type *curtype,
-                                         char *name,
+                                         const char *name,
                                          struct type *expect_type,
                                          int want_address,
                                          enum noside noside);
@@ -987,4 +1014,9 @@ struct value *call_internal_function (struct gdbarch *gdbarch,
 
 char *value_internal_function_name (struct value *);
 
+extern struct value *value_of_xmethod (struct xmethod_worker *);
+
+struct value *call_xmethod (struct value *function,
+                           int argc, struct value **argv);
+
 #endif /* !defined (VALUE_H) */
This page took 0.027835 seconds and 4 git commands to generate.