* config.in: Regenerate.
[binutils-gdb.git] / gdb / parser-defs.h
index c4eb1a042a814713e6788501e8d6b606211215b8..864f789e397210f3ddc3cdd9d728950690892095 100644 (file)
@@ -192,6 +192,11 @@ extern void operator_length (struct expression *, int, int *, int *);
 
 extern void operator_length_standard (struct expression *, int, int *, int *);
 
+extern int operator_check_standard (struct expression *exp, int pos,
+                                   int (*objfile_func)
+                                     (struct objfile *objfile, void *data),
+                                   void *data);
+
 extern char *op_name_standard (enum exp_opcode);
 
 extern struct type *follow_types (struct type *);
@@ -270,6 +275,19 @@ struct exp_descriptor
        the number of subexpressions it takes.  */
     void (*operator_length) (struct expression*, int, int*, int *);
 
+    /* Call TYPE_FUNC and OBJFILE_FUNC for any TYPE and OBJFILE found being
+       referenced by the single operator of EXP at position POS.  Operator
+       parameters are located at positive (POS + number) offsets in EXP.
+       The functions should never be called with NULL TYPE or NULL OBJFILE.
+       Functions should get passed an arbitrary caller supplied DATA pointer.
+       If any of the functions returns non-zero value then (any other) non-zero
+       value should be immediately returned to the caller.  Otherwise zero
+       should be returned.  */
+    int (*operator_check) (struct expression *exp, int pos,
+                          int (*objfile_func) (struct objfile *objfile,
+                                               void *data),
+                          void *data);
+
     /* Name of this operator for dumping purposes.  */
     char *(*op_name) (enum exp_opcode);
 
@@ -300,6 +318,8 @@ extern void print_subexp_standard (struct expression *, int *,
 /* Function used to avoid direct calls to fprintf
    in the code generated by the bison parser.  */
 
-extern void parser_fprintf (FILE *, const char *, ...) ATTR_FORMAT (printf, 2 ,3);
+extern void parser_fprintf (FILE *, const char *, ...) ATTRIBUTE_PRINTF (2, 3);
+
+extern int exp_uses_objfile (struct expression *exp, struct objfile *objfile);
 
 #endif /* PARSER_DEFS_H */