Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [python] [doc] PR 12930/12802 (clarify Breakpoint::stop doco)
@ 2011-10-06 10:59 Phil Muldoon
  2011-10-06 13:40 ` Pedro Alves
  2011-10-06 18:32 ` Eli Zaretskii
  0 siblings, 2 replies; 7+ messages in thread
From: Phil Muldoon @ 2011-10-06 10:59 UTC (permalink / raw)
  To: gdb-patches; +Cc: eli, pedro


This patch address the PRs 12930, and 12802 which both arise from
confusion regarding the scope of actions in the Breakpoint::stop
callback.  I have added some documentation to clarify.

Pedro, please excuse the gratuitous CC, but beyond Eli's normal review
can you please fact-check the documentation to make sure I am not
writing something about states that is incorrect.

Cheers,

Phil

--

2011-10-06  Phil Muldoon  <pmuldoon@redhat.com>

	PR python/12930
	PR python/12802

	* gdb.texinfo (Breakpoints In Python): Clarify behavior in the
	stop method.

--

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index dd0f7f6..0a66f5c 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -23552,6 +23552,18 @@ methods have a chance to execute at that location.  In this scenario
 if one of the methods returns @code{True} but the others return
 @code{False}, the inferior will still be stopped.
 
+When @value{GDBN} executes each @code{stop} method, the inferior has
+been stopped, but the internal state accounting for that inferior is
+undetermined.  As the return value from each @code{stop} method has the
+potential to instruct @value{GDBN} to restart the inferior, or keep it
+in a stopped state, this indeterminate state will remain until the
+execution scope of each @code{stop} method has been completed. Therefore
+you should not alter the execution state of the inferior (IE step, next,
+etc), alter the current frame context (IE change the current active
+frame), or alter, add or delete any breakpoint.  As a general rule, you
+should not alter any data within @value{GDBN} or the inferior at this
+time.
+
 Example @code{stop} implementation:
 
 @smallexample


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-10-07 13:48 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-06 10:59 [python] [doc] PR 12930/12802 (clarify Breakpoint::stop doco) Phil Muldoon
2011-10-06 13:40 ` Pedro Alves
2011-10-06 13:58   ` Phil Muldoon
2011-10-06 14:02     ` Pedro Alves
2011-10-06 18:32 ` Eli Zaretskii
2011-10-07 10:22   ` Phil Muldoon
2011-10-07 13:48   ` Phil Muldoon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox