summaryrefslogtreecommitdiff
path: root/gdb/buildsym.h
diff options
context:
space:
mode:
authorKlee Dienes <kdienes@apple.com>2002-11-18 19:14:10 +0000
committerKlee Dienes <kdienes@apple.com>2002-11-18 19:14:10 +0000
commit60ffc12c2259eb8ab80321121aaddbff84e8f1a9 (patch)
tree1ad8242f1246b97260640016e25a7323c575bd8a /gdb/buildsym.h
parent9283744f2c87cf567ed3e9c4253f69d9ab82f17b (diff)
downloadgdb-60ffc12c2259eb8ab80321121aaddbff84e8f1a9.tar.gz
2002-11-18 Klee Dienes <kdienes@apple.com>
* buildsym.h (pop_context): Convert to function, defined in buildsym.c. * buildsym.c: Include gdb_assert.h. (pop_context): Implement as C function. Add check for stack underflow. * dbxread.c (process_one_symbol): Complain and stop processing that symbol if we are already at the top of the context stack for a function-end N_FUN (this would imply an umatched RBRAC). Ditto when processing N_RBRAC.
Diffstat (limited to 'gdb/buildsym.h')
-rw-r--r--gdb/buildsym.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/gdb/buildsym.h b/gdb/buildsym.h
index 968a5793845..25fe9b14d37 100644
--- a/gdb/buildsym.h
+++ b/gdb/buildsym.h
@@ -173,12 +173,6 @@ EXTERN int context_stack_depth;
EXTERN int context_stack_size;
-/* Macro "function" for popping contexts from the stack. Pushing is
- done by a real function, push_context. This returns a pointer to a
- struct context_stack. */
-
-#define pop_context() (&context_stack[--context_stack_depth]);
-
/* Non-zero if the context stack is empty. */
#define outermost_context_p() (context_stack_depth == 0)
@@ -272,6 +266,8 @@ extern void buildsym_init (void);
extern struct context_stack *push_context (int desc, CORE_ADDR valu);
+extern struct context_stack *pop_context (void);
+
extern void record_line (struct subfile *subfile, int line, CORE_ADDR pc);
extern void start_symtab (char *name, char *dirname, CORE_ADDR start_addr);