]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gdb: change gdbarch_has_global_{solist,breakpoints} to bool
authorSimon Marchi <simon.marchi@efficios.com>
Fri, 27 Feb 2026 20:05:22 +0000 (15:05 -0500)
committerSimon Marchi <simon.marchi@efficios.com>
Mon, 9 Mar 2026 17:15:47 +0000 (13:15 -0400)
Change-Id: I136cfd2fd42e8a3e3fbfc2e34a4b99e9f8fd438a
Approved-By: Tom Tromey <tom@tromey.com>
gdb/dicos-tdep.c
gdb/gdbarch-gen.c
gdb/gdbarch-gen.h
gdb/gdbarch_components.py

index e1d44f0e58ac76398c3160e93aea44847196b9b6..f6a071184d66b7e2912c52f170f5ced1750de797 100644 (file)
@@ -32,11 +32,11 @@ dicos_init_abi (struct gdbarch *gdbarch)
   /* Every process, although has its own address space, sees the same
      list of shared libraries.  There's no "main executable" in DICOS,
      so this accounts for all code.  */
-  set_gdbarch_has_global_solist (gdbarch, 1);
+  set_gdbarch_has_global_solist (gdbarch, true);
 
   /* The DICOS breakpoint API takes care of magically making
      breakpoints visible to all inferiors.  */
-  set_gdbarch_has_global_breakpoints (gdbarch, 1);
+  set_gdbarch_has_global_breakpoints (gdbarch, true);
 
   /* There's no (standard definition of) entry point or a guaranteed
      text location with a symbol where to place the call dummy, so we
index c670698b1f1f3d817ec208016e48d69d32c234d6..3ba67a79fbf6fa255121043fb5a9fb70eb938e8d 100644 (file)
@@ -220,8 +220,8 @@ struct gdbarch
   gdbarch_dtrace_probe_is_enabled_ftype *dtrace_probe_is_enabled = nullptr;
   gdbarch_dtrace_enable_probe_ftype *dtrace_enable_probe = nullptr;
   gdbarch_dtrace_disable_probe_ftype *dtrace_disable_probe = nullptr;
-  int has_global_solist = 0;
-  int has_global_breakpoints = 0;
+  bool has_global_solist = false;
+  bool has_global_breakpoints = false;
   gdbarch_has_shared_address_space_ftype *has_shared_address_space = default_has_shared_address_space;
   gdbarch_fast_tracepoint_valid_at_ftype *fast_tracepoint_valid_at = default_fast_tracepoint_valid_at;
   gdbarch_guess_tracepoint_registers_ftype *guess_tracepoint_registers = default_guess_tracepoint_registers;
@@ -4698,7 +4698,7 @@ set_gdbarch_dtrace_disable_probe (struct gdbarch *gdbarch,
   gdbarch->dtrace_disable_probe = dtrace_disable_probe;
 }
 
-int
+bool
 gdbarch_has_global_solist (struct gdbarch *gdbarch)
 {
   gdb_assert (gdbarch != NULL);
@@ -4710,12 +4710,12 @@ gdbarch_has_global_solist (struct gdbarch *gdbarch)
 
 void
 set_gdbarch_has_global_solist (struct gdbarch *gdbarch,
-                              int has_global_solist)
+                              bool has_global_solist)
 {
   gdbarch->has_global_solist = has_global_solist;
 }
 
-int
+bool
 gdbarch_has_global_breakpoints (struct gdbarch *gdbarch)
 {
   gdb_assert (gdbarch != NULL);
@@ -4727,7 +4727,7 @@ gdbarch_has_global_breakpoints (struct gdbarch *gdbarch)
 
 void
 set_gdbarch_has_global_breakpoints (struct gdbarch *gdbarch,
-                                   int has_global_breakpoints)
+                                   bool has_global_breakpoints)
 {
   gdbarch->has_global_breakpoints = has_global_breakpoints;
 }
index f01aa7921792622f40e4318843ac8f9644bf3ea4..4949d92d69e37da57cf8290dceac9581eec04209 100644 (file)
@@ -1496,16 +1496,16 @@ extern void set_gdbarch_dtrace_disable_probe (struct gdbarch *gdbarch, gdbarch_d
    an address space, will see the same set of symbols at the same
    addresses. */
 
-extern int gdbarch_has_global_solist (struct gdbarch *gdbarch);
-extern void set_gdbarch_has_global_solist (struct gdbarch *gdbarch, int has_global_solist);
+extern bool gdbarch_has_global_solist (struct gdbarch *gdbarch);
+extern void set_gdbarch_has_global_solist (struct gdbarch *gdbarch, bool has_global_solist);
 
 /* On some targets, even though each inferior has its own private
    address space, the debug interface takes care of making breakpoints
    visible to all address spaces automatically.  For such cases,
    this property should be set to true. */
 
-extern int gdbarch_has_global_breakpoints (struct gdbarch *gdbarch);
-extern void set_gdbarch_has_global_breakpoints (struct gdbarch *gdbarch, int has_global_breakpoints);
+extern bool gdbarch_has_global_breakpoints (struct gdbarch *gdbarch);
+extern void set_gdbarch_has_global_breakpoints (struct gdbarch *gdbarch, bool has_global_breakpoints);
 
 /* True if inferiors share an address space (e.g., uClinux). */
 
index 8bce7e7753c2417ee58ae4bec82ff79f6c5d0419..cb88a15872a01df1ac5d66560c5c894a24c9f0a3 100644 (file)
@@ -2371,9 +2371,9 @@ This usually means that all processes, although may or may not share
 an address space, will see the same set of symbols at the same
 addresses.
 """,
-    type="int",
+    type="bool",
     name="has_global_solist",
-    predefault="0",
+    predefault="false",
     invalid=False,
 )
 
@@ -2384,9 +2384,9 @@ address space, the debug interface takes care of making breakpoints
 visible to all address spaces automatically.  For such cases,
 this property should be set to true.
 """,
-    type="int",
+    type="bool",
     name="has_global_breakpoints",
-    predefault="0",
+    predefault="false",
     invalid=False,
 )