use remote-utils facilities for baud_rate
[deliverable/binutils-gdb.git] / gdb / value.h
index 7333578b276339f946dce260b77da5be62fda27b..15b505349e780db111c6dbc6bf772a13db14c212 100644 (file)
@@ -52,7 +52,7 @@ struct value
       {
        /* Address in inferior or byte of registers structure.  */
        CORE_ADDR address;
-       /* Pointer to interrnal variable.  */
+       /* Pointer to internal variable.  */
        struct internalvar *internalvar;
        /* Number of register.  Only used with
           lval_reg_frame_relative.  */
@@ -62,7 +62,9 @@ struct value
     int offset;        
     /* Only used for bitfields; number of bits contained in them.  */
     int bitsize;
-    /* Only used for bitfields; position of start of field.  */
+    /* Only used for bitfields; position of start of field.
+       For BITS_BIG_ENDIAN=0 targets, it is the position of the LSB.
+       For BITS_BIG_ENDIAN=1 targets, it is the position of the MSB. */
     int bitpos;
     /* Frame value is relative to.  In practice, this address is only
        used if the value is stored in several registers in other than
@@ -100,7 +102,7 @@ struct value
     union {
       long contents[1];
       double force_double_align;
-#ifdef LONG_LONG
+#ifdef CC_HAS_LONG_LONG
       long long force_longlong_align;
 #endif
     } aligner;
@@ -182,6 +184,12 @@ struct internalvar
   value value;
 };
 
+/* Pointer to member function.  Depends on compiler implementation. */
+
+#define METHOD_PTR_IS_VIRTUAL(ADDR)  ((ADDR) & 0x80000000)
+#define METHOD_PTR_FROM_VOFFSET(OFFSET) (0x80000000 + (OFFSET))
+#define METHOD_PTR_TO_VOFFSET(ADDR) (~0x80000000 & (ADDR))
+
 \f
 #include "symtab.h"
 #include "gdbtypes.h"
@@ -189,6 +197,7 @@ struct internalvar
 
 #ifdef __STDC__
 struct frame_info;
+struct fn_field;
 #endif
 
 extern void
@@ -212,7 +221,7 @@ unpack_double PARAMS ((struct type *type, char *valaddr, int *invp));
 extern CORE_ADDR
 unpack_pointer PARAMS ((struct type *type, char *valaddr));
 
-extern long
+extern LONGEST
 unpack_field_as_long PARAMS ((struct type *type, char *valaddr,
                              int fieldno));
 
@@ -262,6 +271,12 @@ value_free_to_mark PARAMS ((value mark));
 extern value
 value_string PARAMS ((char *ptr, int len));
 
+extern value
+value_array PARAMS ((int lowbound, int highbound, value *elemvec));
+
+extern value
+value_concat PARAMS ((value arg1, value arg2));
+
 extern value
 value_binop PARAMS ((value arg1, value arg2, enum exp_opcode op));
 
@@ -290,7 +305,7 @@ extern value
 value_neg PARAMS ((value arg1));
 
 extern value
-value_lognot PARAMS ((value arg1));
+value_complement PARAMS ((value arg1));
 
 extern value
 value_struct_elt PARAMS ((value *argp, value *args, char *name,
@@ -298,6 +313,7 @@ value_struct_elt PARAMS ((value *argp, value *args, char *name,
 
 extern value
 value_struct_elt_for_reference PARAMS ((struct type *domain,
+                                       int offset,
                                        struct type *curtype,
                                        char *name,
                                        struct type *intype));
@@ -381,7 +397,7 @@ extern int
 value_less PARAMS ((value arg1, value arg2));
 
 extern int
-value_zerop PARAMS ((value arg1));
+value_logical_not PARAMS ((value arg1));
 
 /* C++ */
 
@@ -396,11 +412,12 @@ extern value
 value_x_unop PARAMS ((value arg1, enum exp_opcode op));
 
 extern value
-value_fn_field PARAMS ((struct fn_field *f, int j));
+value_fn_field PARAMS ((value *arg1p, struct fn_field *f, int j,
+                       struct type* type, int offset));
 
 extern value
-value_virtual_fn_field PARAMS ((value arg1, struct fn_field *f, int j,
-                               struct type *type));
+value_virtual_fn_field PARAMS ((value *arg1p, struct fn_field *f, int j,
+                               struct type *type, int offset));
 
 extern int
 binop_user_defined_p PARAMS ((enum exp_opcode op, value arg1, value arg2));
@@ -408,13 +425,10 @@ binop_user_defined_p PARAMS ((enum exp_opcode op, value arg1, value arg2));
 extern int
 unop_user_defined_p PARAMS ((enum exp_opcode op, value arg1));
 
-extern int
-typecmp PARAMS ((int staticp, struct type *t1[], value t2[]));
-
 extern int
 destructor_name_p PARAMS ((const char *name, const struct type *type));
 
-#define value_free(val) free (val)
+#define value_free(val) free ((PTR)val)
 
 extern void
 free_all_values PARAMS ((void));
@@ -459,23 +473,14 @@ extern void
 type_print PARAMS ((struct type *type, char *varstring, FILE *stream,
                    int show));
 
-extern void
-type_print_1 PARAMS ((struct type *type, char *varstring, FILE *stream,
-                     int show, int level));
-
-/* Possibilities for prettyprint parameters to routines which print
-   things.  */
-enum val_prettyprint {
-  Val_no_prettyprint = 0,
-  Val_prettyprint,
-  /* Use the default setting which the user has specified.  */
-  Val_pretty_default
-  };
-
 extern char *
 baseclass_addr PARAMS ((struct type *type, int index, char *valaddr,
                        value *valuep, int *errp));
 
+extern void
+print_longest PARAMS ((FILE *stream, char format, int use_local,
+                      LONGEST value));
+
 extern void
 print_floating PARAMS ((char *valaddr, struct type *type, FILE *stream));
 
@@ -488,6 +493,9 @@ val_print PARAMS ((struct type *type, char *valaddr, CORE_ADDR address,
                   FILE *stream, int format, int deref_ref,
                   int recurse, enum val_prettyprint pretty));
 
+extern int
+val_print_string PARAMS ((CORE_ADDR addr, unsigned int len, FILE *stream));
+
 /* FIXME:  Assumes equivalence of "struct frame_info *" and "FRAME" */
 extern void
 print_variable_value PARAMS ((struct symbol *var, struct frame_info *frame,
@@ -500,7 +508,7 @@ extern int
 check_field PARAMS ((value, const char *));
 
 extern void
-typedef_print PARAMS ((struct type *type, struct symbol *new, FILE *stream));
+c_typedef_print PARAMS ((struct type *type, struct symbol *new, FILE *stream));
 
 extern char *
 internalvar_name PARAMS ((struct internalvar *var));
@@ -516,6 +524,9 @@ clear_internalvars PARAMS ((void));
 extern value
 value_copy PARAMS ((value));
 
+extern int
+baseclass_offset PARAMS ((struct type *, int, value, int));
+
 /* From valops.c */
 
 extern value
This page took 0.025361 seconds and 4 git commands to generate.