[1/3] gdb: regenerate target-delegates.c

Message ID b03f96baf03fd61dd4bda47fcd725a07938547a0.1699953637.git.tankut.baris.aktemur@intel.com
State New
Headers
Series [1/3] gdb: regenerate target-delegates.c |

Checks

Context Check Description
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 fail Patch failed to apply
linaro-tcwg-bot/tcwg_gdb_build--master-arm fail Patch failed to apply

Commit Message

Aktemur, Tankut Baris Nov. 14, 2023, 9:41 a.m. UTC
  I ran './make-target-delegates.py' and there as one minor difference,
where an older style declaration is converted to a newer
initialization style.  Add this change.
---
 gdb/target-delegates.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
  

Comments

Pedro Alves Nov. 14, 2023, 11:14 a.m. UTC | #1
On 2023-11-14 09:41, Tankut Baris Aktemur wrote:
> I ran './make-target-delegates.py' and there as one minor difference,
> where an older style declaration is converted to a newer
> initialization style.  Add this change.
> ---
>  gdb/target-delegates.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/gdb/target-delegates.c b/gdb/target-delegates.c
> index c5540c366e4..a27b66df100 100644
> --- a/gdb/target-delegates.c
> +++ b/gdb/target-delegates.c
> @@ -2291,9 +2291,9 @@ dummy_target::supports_set_thread_options (gdb_thread_options arg0)
>  bool
>  debug_target::supports_set_thread_options (gdb_thread_options arg0)
>  {
> -  bool result;
>    gdb_printf (gdb_stdlog, "-> %s->supports_set_thread_options (...)\n", this->beneath ()->shortname ());
> -  result = this->beneath ()->supports_set_thread_options (arg0);
> +  bool result
> +    = this->beneath ()->supports_set_thread_options (arg0);
>    gdb_printf (gdb_stdlog, "<- %s->supports_set_thread_options (", this->beneath ()->shortname ());
>    target_debug_print_gdb_thread_options (arg0);
>    gdb_puts (") = ", gdb_stdlog);


Whoops, my fault, missed the need to regenerate before pushing.

Approved-By: Pedro Alves <pedro@palves.net>
  
Tom Tromey Nov. 14, 2023, 2:18 p.m. UTC | #2
>>>>> "Tankut" == Tankut Baris Aktemur <tankut.baris.aktemur@intel.com> writes:

Tankut> I ran './make-target-delegates.py' and there as one minor difference,
Tankut> where an older style declaration is converted to a newer
Tankut> initialization style.  Add this change.

FAOD, I think it's fine to treat regenerations like this as obvious.

I suppose the exception would be if you have some reason to believe the
change to one of the inputs was incorrect, so regenerating would
introduce a bug.  But, I think that's pretty rare.

thanks,
Tom
  

Patch

diff --git a/gdb/target-delegates.c b/gdb/target-delegates.c
index c5540c366e4..a27b66df100 100644
--- a/gdb/target-delegates.c
+++ b/gdb/target-delegates.c
@@ -2291,9 +2291,9 @@  dummy_target::supports_set_thread_options (gdb_thread_options arg0)
 bool
 debug_target::supports_set_thread_options (gdb_thread_options arg0)
 {
-  bool result;
   gdb_printf (gdb_stdlog, "-> %s->supports_set_thread_options (...)\n", this->beneath ()->shortname ());
-  result = this->beneath ()->supports_set_thread_options (arg0);
+  bool result
+    = this->beneath ()->supports_set_thread_options (arg0);
   gdb_printf (gdb_stdlog, "<- %s->supports_set_thread_options (", this->beneath ()->shortname ());
   target_debug_print_gdb_thread_options (arg0);
   gdb_puts (") = ", gdb_stdlog);