summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp
diff options
context:
space:
mode:
authorAdrian Prantl <aprantl@apple.com>2018-04-30 16:49:04 +0000
committerAdrian Prantl <aprantl@apple.com>2018-04-30 16:49:04 +0000
commit05097246f352eca76207c9ebb08656c88bdf751a (patch)
treebfc4ec8250a939aaf4ade6fc6c528726183e5367 /lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp
parentadd59c052dd6768fd54431e6a3bf045e7f25cb59 (diff)
downloadbcm5719-llvm-05097246f352eca76207c9ebb08656c88bdf751a.tar.gz
bcm5719-llvm-05097246f352eca76207c9ebb08656c88bdf751a.zip
Reflow paragraphs in comments.
This is intended as a clean up after the big clang-format commit (r280751), which unfortunately resulted in many of the comment paragraphs in LLDB being very hard to read. FYI, the script I used was: import textwrap import commands import os import sys import re tmp = "%s.tmp"%sys.argv[1] out = open(tmp, "w+") with open(sys.argv[1], "r") as f: header = "" text = "" comment = re.compile(r'^( *//) ([^ ].*)$') special = re.compile(r'^((([A-Z]+[: ])|([0-9]+ )).*)|(.*;)$') for line in f: match = comment.match(line) if match and not special.match(match.group(2)): # skip intentionally short comments. if not text and len(match.group(2)) < 40: out.write(line) continue if text: text += " " + match.group(2) else: header = match.group(1) text = match.group(2) continue if text: filled = textwrap.wrap(text, width=(78-len(header)), break_long_words=False) for l in filled: out.write(header+" "+l+'\n') text = "" out.write(line) os.rename(tmp, sys.argv[1]) Differential Revision: https://reviews.llvm.org/D46144 llvm-svn: 331197
Diffstat (limited to 'lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp')
-rw-r--r--lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp29
1 files changed, 14 insertions, 15 deletions
diff --git a/lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp b/lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp
index 0dae98f03ef..e8ea73f3c6a 100644
--- a/lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp
+++ b/lldb/source/Target/ThreadPlanCallOnFunctionExit.cpp
@@ -23,8 +23,8 @@ ThreadPlanCallOnFunctionExit::ThreadPlanCallOnFunctionExit(
}
void ThreadPlanCallOnFunctionExit::DidPush() {
- // We now want to queue the "step out" thread plan so it executes
- // and completes.
+ // We now want to queue the "step out" thread plan so it executes and
+ // completes.
// Set stop vote to eVoteNo.
m_step_out_threadplan_sp = GetThread().QueueThreadPlanForStepOut(
@@ -59,9 +59,9 @@ bool ThreadPlanCallOnFunctionExit::ValidatePlan(Stream *error) {
}
bool ThreadPlanCallOnFunctionExit::ShouldStop(Event *event_ptr) {
- // If this is where we find out that an internal stop came in, then:
- // Check if the step-out plan completed. If it did, then we want to
- // run the callback here (our reason for living...)
+ // If this is where we find out that an internal stop came in, then: Check if
+ // the step-out plan completed. If it did, then we want to run the callback
+ // here (our reason for living...)
if (m_step_out_threadplan_sp && m_step_out_threadplan_sp->IsPlanComplete()) {
m_callback();
@@ -71,8 +71,8 @@ bool ThreadPlanCallOnFunctionExit::ShouldStop(Event *event_ptr) {
// Indicate that this plan is done and can be discarded.
SetPlanComplete();
- // We're done now, but we want to return false so that we
- // don't cause the thread to really stop.
+ // We're done now, but we want to return false so that we don't cause the
+ // thread to really stop.
}
return false;
@@ -80,21 +80,20 @@ bool ThreadPlanCallOnFunctionExit::ShouldStop(Event *event_ptr) {
bool ThreadPlanCallOnFunctionExit::WillStop() {
// The code looks like the return value is ignored via ThreadList::
- // ShouldStop().
- // This is called when we really are going to stop. We don't care
- // and don't need to do anything here.
+ // ShouldStop(). This is called when we really are going to stop. We don't
+ // care and don't need to do anything here.
return false;
}
bool ThreadPlanCallOnFunctionExit::DoPlanExplainsStop(Event *event_ptr) {
- // We don't ever explain a stop. The only stop that is relevant
- // to us directly is the step_out plan we added to do the heavy lifting
- // of getting us past the current method.
+ // We don't ever explain a stop. The only stop that is relevant to us
+ // directly is the step_out plan we added to do the heavy lifting of getting
+ // us past the current method.
return false;
}
lldb::StateType ThreadPlanCallOnFunctionExit::GetPlanRunState() {
- // This value doesn't matter - we'll never be the top thread plan, so
- // nobody will ask us this question.
+ // This value doesn't matter - we'll never be the top thread plan, so nobody
+ // will ask us this question.
return eStateRunning;
}
OpenPOWER on IntegriCloud