]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* tui/tui-regs.c (tui_display_register): Add comment about
authorJoel Brobecker <brobecker@gnat.com>
Fri, 16 Apr 2010 04:34:31 +0000 (04:34 +0000)
committerJoel Brobecker <brobecker@gnat.com>
Fri, 16 Apr 2010 04:34:31 +0000 (04:34 +0000)
        a couple of casts.
        * tui/tui-stack.c (tui_show_locator_content): Ditto.

gdb/ChangeLog
gdb/tui/tui-regs.c
gdb/tui/tui-stack.c

index 0a8f5b1c78df04abe76645fe978df836e25364c8..7c2ec949aea65e9068bb3e59668ecdafe4b2ff18 100644 (file)
@@ -1,3 +1,9 @@
+2010-04-16  Joel Brobecker  <brobecker@adacore.com>
+
+       * tui/tui-regs.c (tui_display_register): Add comment about
+       a couple of casts.
+       * tui/tui-stack.c (tui_show_locator_content): Ditto.
+
 2010-04-15  Stan Shebs  <stan@codesourcery.com>
 
        * frame.c: Include tracepoint.h.
index 8cbd338aae99d337e5223e551fe2eb97519dc149..a339beadc6078ea6dea47012fc85266a8091404a 100644 (file)
@@ -541,6 +541,11 @@ tui_display_register (struct tui_data_element *data,
       int i;
 
       if (data->highlight)
+       /* We ignore the return value, casting it to void in order to avoid
+          a compiler warning.  The warning itself was introduced by a patch
+          to ncurses 5.7 dated 2009-08-29, changing this macro to expand
+          to code that causes the compiler to generate an unused-value
+          warning.  */
        (void) wstandout (win_info->handle);
       
       wmove (win_info->handle, 0, 0);
@@ -551,6 +556,11 @@ tui_display_register (struct tui_data_element *data,
         waddstr (win_info->handle, data->content);
 
       if (data->highlight)
+       /* We ignore the return value, casting it to void in order to avoid
+          a compiler warning.  The warning itself was introduced by a patch
+          to ncurses 5.7 dated 2009-08-29, changing this macro to expand
+          to code that causes the compiler to generate an unused-value
+          warning.  */
        (void) wstandend (win_info->handle);
       tui_refresh_win (win_info);
     }
index 1630beaa59fdac4a5c71243f9083c7e91efd7a35..d6b514d1d28067901a447226d000bf1f5de6405f 100644 (file)
@@ -256,6 +256,11 @@ tui_show_locator_content (void)
 
       string = tui_make_status_line (&element->which_element.locator);
       wmove (locator->handle, 0, 0);
+      /* We ignore the return value from wstandout and wstandend, casting
+        them to void in order to avoid a compiler warning.  The warning
+        itself was introduced by a patch to ncurses 5.7 dated 2009-08-29,
+        changing these macro to expand to code that causes the compiler
+        to generate an unused-value warning.  */
       (void) wstandout (locator->handle);
       waddstr (locator->handle, string);
       wclrtoeol (locator->handle);