[binutils-gdb] Use boolean literals for pagination_enabled

Tom Tromey tromey@sourceware.org
Thu Nov 17 16:38:38 GMT 2022


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=2f6831b8066cd758e2f39c38503d2fa41608b9a7

commit 2f6831b8066cd758e2f39c38503d2fa41608b9a7
Author: Tom Tromey <tromey@adacore.com>
Date:   Thu Nov 17 09:35:20 2022 -0700

    Use boolean literals for pagination_enabled
    
    I noticed a couple of spots that used '0' rather than 'false' when
    modifying pagination_enabled.  This patch cleans these up.

Diff:
---
 gdb/infrun.c       | 2 +-
 gdb/tui/tui-regs.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/gdb/infrun.c b/gdb/infrun.c
index debc6054624..96346e1f25b 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -259,7 +259,7 @@ set_observer_mode (const char *args, int from_tty,
      going out we leave it that way.  */
   if (observer_mode)
     {
-      pagination_enabled = 0;
+      pagination_enabled = false;
       non_stop = non_stop_1 = true;
     }
 
diff --git a/gdb/tui/tui-regs.c b/gdb/tui/tui-regs.c
index 3eff98a5b69..af7f4942aba 100644
--- a/gdb/tui/tui-regs.c
+++ b/gdb/tui/tui-regs.c
@@ -93,7 +93,7 @@ tui_register_format (frame_info_ptr frame, int regnum)
   tab_expansion_file stream;
 
   scoped_restore save_pagination
-    = make_scoped_restore (&pagination_enabled, 0);
+    = make_scoped_restore (&pagination_enabled, false);
   scoped_restore save_stdout
     = make_scoped_restore (&gdb_stdout, &stream);


More information about the Gdb-cvs mailing list