gdb: remove LA_PRINT_ARRAY_INDEX macro
authorAndrew Burgess <andrew.burgess@embecosm.com>
Fri, 14 Aug 2020 14:06:08 +0000 (15:06 +0100)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Fri, 23 Oct 2020 09:57:14 +0000 (10:57 +0100)
Replace the single use of the LA_PRINT_ARRAY_INDEX macro with the
macro's definition, and delete the macro.

There should be no user visible changes after this commit.

gdb/ChangeLog:

* language.h (LA_PRINT_ARRAY_INDEX): Delete.
* valprint.c (maybe_print_array_index): Replace use of macro with
the macros definition.

gdb/ChangeLog
gdb/language.h
gdb/valprint.c

index ec1bdca6ea70cd289ac7cc103feaf7935a25d698..db2d3f172ec2f99c29f675c952ad844e80bd87e7 100644 (file)
@@ -1,3 +1,9 @@
+2020-10-23  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+       * language.h (LA_PRINT_ARRAY_INDEX): Delete.
+       * valprint.c (maybe_print_array_index): Replace use of macro with
+       the macros definition.
+
 2020-10-23  Andrew Burgess  <andrew.burgess@embecosm.com>
 
        * ada-lang.c (ada_language::print_array_index): Call value_print
index c85f90f8b4bdee9d9fbd1ded95ac767b68b1f376..bffa9fddfeec171cb6192d566d4f150fa809c04e 100644 (file)
@@ -652,10 +652,6 @@ extern enum language set_language (enum language);
 #define LA_EMIT_CHAR(ch, type, stream, quoter) \
   (current_language->emitchar (ch, type, stream, quoter))
 
-#define LA_PRINT_ARRAY_INDEX(index_type, index_value, stream, options) \
-  (current_language->print_array_index(index_type, index_value, stream, \
-                                      options))
-
 #define LA_ITERATE_OVER_SYMBOLS(BLOCK, NAME, DOMAIN, CALLBACK) \
   (current_language->iterate_over_symbols (BLOCK, NAME, DOMAIN, CALLBACK))
 
index 880d04f8c1dc05fc9f78c71be7f10a2698a8815a..4fdb9eaca3aa24605273e79034fc156583cc8575 100644 (file)
@@ -1866,8 +1866,8 @@ maybe_print_array_index (struct type *index_type, LONGEST index,
 {
   if (!options->print_array_indexes)
     return; 
-    
-  LA_PRINT_ARRAY_INDEX (index_type, index, stream, options);
+
+  current_language->print_array_index (index_type, index, stream, options);
 }
 
 /* See valprint.h.  */