]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
make common_block const
authorTom Tromey <tromey@redhat.com>
Wed, 11 Jun 2014 14:02:48 +0000 (08:02 -0600)
committerTom Tromey <tromey@redhat.com>
Wed, 18 Jun 2014 14:17:00 +0000 (08:17 -0600)
This changes general_symbol_info to make "common_block" const.

2014-06-18  Tom Tromey  <tromey@redhat.com>

* f-valprint.c (info_common_command_for_block): Update.
* symtab.h (struct general_symbol_info) <common_block>: Now
const.

gdb/ChangeLog
gdb/f-valprint.c
gdb/symtab.h

index d851f71fbfe7ec8f3b9292dae027a1bb37413e57..dca4ef2bb3e74310810c01d14ce06938cc030f80 100644 (file)
@@ -1,3 +1,9 @@
+2014-06-18  Tom Tromey  <tromey@redhat.com>
+
+       * f-valprint.c (info_common_command_for_block): Update.
+       * symtab.h (struct general_symbol_info) <common_block>: Now
+       const.
+
 2014-06-18  Tom Tromey  <tromey@redhat.com>
 
        * symtab.h (struct symtab) <blockvector>: Now const.
index 0040bbd31f2946f57bd38b717048970b9a7af58f..408c8cc622017ba227bc2e0385e0bfd003402ebc 100644 (file)
@@ -424,7 +424,7 @@ info_common_command_for_block (const struct block *block, const char *comname,
   ALL_BLOCK_SYMBOLS (block, iter, sym)
     if (SYMBOL_DOMAIN (sym) == COMMON_BLOCK_DOMAIN)
       {
-       struct common_block *common = SYMBOL_VALUE_COMMON_BLOCK (sym);
+       const struct common_block *common = SYMBOL_VALUE_COMMON_BLOCK (sym);
        size_t index;
 
        gdb_assert (SYMBOL_CLASS (sym) == LOC_COMMON_BLOCK);
index 5ccc7ecb84774c279171e391dcb66b6fb470712a..5a6f83106da4ee2b343716c5511a22049dcfe255 100644 (file)
@@ -122,7 +122,7 @@ struct general_symbol_info
 
     /* A common block.  Used with LOC_COMMON_BLOCK.  */
 
-    struct common_block *common_block;
+    const struct common_block *common_block;
 
     /* For opaque typedef struct chain.  */