Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Joel Brobecker <brobecker@gnat.com>
To: Michael Snyder <msnyder@redhat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [PATCH] Minor reformatting in infrun.c
Date: Fri, 23 Aug 2002 10:29:00 -0000	[thread overview]
Message-ID: <20020823162729.GZ25997@gnat.com> (raw)
In-Reply-To: <3D657A41.EBE52A4B@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 851 bytes --]

> Err, I was actually meaning to say "let's conform with indent", 
> rather than "let's defeat indent".  How about moving the comment
> outside the argument list?  Then the args can stay as they were.

I see what you mean now. I should have tried it before, instead of
assuming that moving the comment up would not prevent indent from
formatting the args back to the same previous unreadable way (I did not
realize that the comment had this effect in the formatting result)...

I can commit the following patch. I verified that a later re-indent
does not cause a formatting change in the second argument.

2002-08-23  Joel Brobecker  <brobecker@gnat.com>

        * infrun.c (handle_inferior_event): Move a comment outside of a
        function call, in order to avoid indent reformatting this part
        of the code in an unreadable way.

-- 
Joel

[-- Attachment #2: infrun.c.diff --]
[-- Type: text/plain, Size: 2392 bytes --]

Index: infrun.c
===================================================================
RCS file: /cvs/src/src/gdb/infrun.c,v
retrieving revision 1.68
diff -c -3 -p -r1.68 infrun.c
*** infrun.c	20 Aug 2002 23:01:29 -0000	1.68
--- infrun.c	23 Aug 2002 16:17:49 -0000
*************** handle_inferior_event (struct execution_
*** 2110,2127 ****
  	     This is only important on targets where DECR_PC_AFTER_BREAK
  	     is non-zero.  The prev_pc test is meant to distinguish between
  	     singlestepping a trap instruction, and singlestepping thru a
! 	     jump to the instruction following a trap instruction. */
  
  	  stop_bpstat =
              bpstat_stop_status
                (&stop_pc,
-                /* Pass TRUE if our reason for stopping is something other
-                   than hitting a breakpoint.  We do this by checking that
-                   either we detected earlier a software single step trap or
-                   1) stepping is going on and 2) we didn't hit a breakpoint
-                   in a signal handler without an intervening stop in
-                   sigtramp, which is detected by a new stack pointer value
-                   below any usual function calling stack adjustments.  */
                 sw_single_step_trap_p
                 || (currently_stepping (ecs)
                     && prev_pc != stop_pc - DECR_PC_AFTER_BREAK
--- 2110,2127 ----
  	     This is only important on targets where DECR_PC_AFTER_BREAK
  	     is non-zero.  The prev_pc test is meant to distinguish between
  	     singlestepping a trap instruction, and singlestepping thru a
! 	     jump to the instruction following a trap instruction.
  
+            Therefore, pass TRUE if our reason for stopping is
+            something other than hitting a breakpoint.  We do this by
+            checking that either: we detected earlier a software single
+            step trap or, 1) stepping is going on and 2) we didn't hit
+            a breakpoint in a signal handler without an intervening stop
+            in sigtramp, which is detected by a new stack pointer value
+            below any usual function calling stack adjustments.  */
  	  stop_bpstat =
              bpstat_stop_status
                (&stop_pc,
                 sw_single_step_trap_p
                 || (currently_stepping (ecs)
                     && prev_pc != stop_pc - DECR_PC_AFTER_BREAK

  reply	other threads:[~2002-08-23 16:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-08-16 17:18 Joel Brobecker
2002-08-16 19:48 ` Michael Snyder
2002-08-22 16:52   ` Joel Brobecker
2002-08-22 18:25     ` Michael Snyder
2002-08-23 10:29       ` Joel Brobecker [this message]
2002-08-23 11:31         ` Michael Snyder
2002-08-23 15:06           ` Joel Brobecker
2002-08-23 15:23             ` Andrew Cagney
2002-08-23 16:15             ` Michael Snyder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020823162729.GZ25997@gnat.com \
    --to=brobecker@gnat.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=msnyder@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox