diff options
author | Joel Brobecker <brobecker@gnat.com> | 2009-09-09 17:23:55 +0000 |
---|---|---|
committer | Joel Brobecker <brobecker@gnat.com> | 2009-09-09 17:23:55 +0000 |
commit | 49e794ac6235d43615f123d660113873ee3049ec (patch) | |
tree | b470349c0eea1456fcae165050f1b80cf30c684e /gdb/block.c | |
parent | 52c745b5d3f4dc981e404858aa1ead14cbda882e (diff) | |
download | gdb-49e794ac6235d43615f123d660113873ee3049ec.zip gdb-49e794ac6235d43615f123d660113873ee3049ec.tar.gz gdb-49e794ac6235d43615f123d660113873ee3049ec.tar.bz2 |
* block.c (contained_in): Return zero for nested functions.
* blockframe.c (block_innermost_frame): Delete unreferenced local
variable.
Diffstat (limited to 'gdb/block.c')
-rw-r--r-- | gdb/block.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gdb/block.c b/gdb/block.c index 1889ecd..97ea67a 100644 --- a/gdb/block.c +++ b/gdb/block.c @@ -52,6 +52,10 @@ contained_in (const struct block *a, const struct block *b) { if (a == b) return 1; + /* If A is a function block, then A cannot be contained in B, + except if A was inlined. */ + if (BLOCK_FUNCTION (a) != NULL && !block_inlined_p (a)) + return 0; a = BLOCK_SUPERBLOCK (a); } while (a != NULL); |