Skip to content

Commit 3ef49db

Browse files
address comments
1 parent e9462be commit 3ef49db

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

lldb/include/lldb/Target/StackFrame.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ class StackFrame : public ExecutionContextScope,
354354
/// \param [in] frame_marker
355355
/// Optional string that will be prepended to the frame output description.
356356
void DumpUsingSettingsFormat(Stream *strm, bool show_unique = false,
357-
const std::string &frame_marker = "");
357+
llvm::StringRef frame_marker = "");
358358

359359
/// Print a description for this frame using a default format.
360360
///
@@ -390,8 +390,7 @@ class StackFrame : public ExecutionContextScope,
390390
/// \return
391391
/// Returns true if successful.
392392
bool GetStatus(Stream &strm, bool show_frame_info, bool show_source,
393-
bool show_unique = false,
394-
const std::string &frame_marker = "");
393+
bool show_unique = false, llvm::StringRef frame_marker = "");
395394

396395
/// Query whether this frame is a concrete frame on the call stack, or if it
397396
/// is an inlined frame derived from the debug information and presented by

lldb/source/Target/StackFrame.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1935,7 +1935,7 @@ bool StackFrame::DumpUsingFormat(Stream &strm,
19351935
}
19361936

19371937
void StackFrame::DumpUsingSettingsFormat(Stream *strm, bool show_unique,
1938-
const std::string &frame_marker) {
1938+
llvm::StringRef frame_marker) {
19391939
if (strm == nullptr)
19401940
return;
19411941

@@ -2035,7 +2035,7 @@ bool StackFrame::HasCachedData() const {
20352035
}
20362036

20372037
bool StackFrame::GetStatus(Stream &strm, bool show_frame_info, bool show_source,
2038-
bool show_unique, const std::string &frame_marker) {
2038+
bool show_unique, llvm::StringRef frame_marker) {
20392039
if (show_frame_info) {
20402040
strm.Indent();
20412041
DumpUsingSettingsFormat(&strm, show_unique, frame_marker);

lldb/source/Target/StackFrameList.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -900,15 +900,14 @@ bool StackFrameList::IsPreviousFrameHidden(lldb_private::StackFrame &frame) {
900900

901901
std::wstring StackFrameList::FrameMarker(lldb::StackFrameSP frame_sp,
902902
lldb::StackFrameSP selected_frame_sp) {
903-
if (frame_sp == selected_frame_sp) {
903+
if (frame_sp == selected_frame_sp)
904904
return Terminal::SupportsUnicode() ? L" * " : L"* ";
905-
} else if (!Terminal::SupportsUnicode()) {
905+
else if (!Terminal::SupportsUnicode())
906906
return L" ";
907-
} else if (IsPreviousFrameHidden(*frame_sp)) {
907+
else if (IsPreviousFrameHidden(*frame_sp))
908908
return L"";
909-
} else if (IsNextFrameHidden(*frame_sp)) {
909+
else if (IsNextFrameHidden(*frame_sp))
910910
return L"";
911-
}
912911
return L"  ";
913912
}
914913

0 commit comments

Comments
 (0)