diff options
author | Simon Marchi <simon.marchi@polymtl.ca> | 2022-04-06 10:42:03 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@polymtl.ca> | 2022-04-07 13:04:53 -0400 |
commit | 44281e6c08cae11d4e116d87ea34ad391d58ae91 (patch) | |
tree | 7d79dd1cb4870a6d73026985325059b01cde89c2 /gdb/linespec.c | |
parent | e4730328287f755eb313c3762d83d389462cde15 (diff) | |
download | gdb-44281e6c08cae11d4e116d87ea34ad391d58ae91.zip gdb-44281e6c08cae11d4e116d87ea34ad391d58ae91.tar.gz gdb-44281e6c08cae11d4e116d87ea34ad391d58ae91.tar.bz2 |
gdb: remove symtab::blockvector
symtab::blockvector is a wrapper around compunit_symtab::blockvector.
It is a bit misleadnig, as it gives the impression that a symtab has a
blockvector. Remove it, change all users to fetch the blockvector
through the compunit instead.
Change-Id: Ibd062cd7926112a60d52899dff9224591cbdeebf
Diffstat (limited to 'gdb/linespec.c')
-rw-r--r-- | gdb/linespec.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gdb/linespec.c b/gdb/linespec.c index 4d41f74..5a6b620 100644 --- a/gdb/linespec.c +++ b/gdb/linespec.c @@ -1188,12 +1188,11 @@ iterate_over_all_matching_symtabs { const struct block *block; int i; + const blockvector *bv = symtab->compunit ()->blockvector (); - for (i = FIRST_LOCAL_BLOCK; - i < BLOCKVECTOR_NBLOCKS (symtab->blockvector ()); - i++) + for (i = FIRST_LOCAL_BLOCK; i < BLOCKVECTOR_NBLOCKS (bv); i++) { - block = BLOCKVECTOR_BLOCK (symtab->blockvector (), i); + block = BLOCKVECTOR_BLOCK (bv, i); state->language->iterate_over_symbols (block, lookup_name, name_domain, [&] (block_symbol *bsym) @@ -1232,7 +1231,8 @@ iterate_over_file_blocks { const struct block *block; - for (block = BLOCKVECTOR_BLOCK (symtab->blockvector (), STATIC_BLOCK); + for (block = BLOCKVECTOR_BLOCK (symtab->compunit ()->blockvector (), + STATIC_BLOCK); block != NULL; block = BLOCK_SUPERBLOCK (block)) current_language->iterate_over_symbols (block, name, domain, callback); |