[Lldb-commits] [PATCH] Add const versions of SBFrame::GetFunctionName and SBFrame::IsInlined.
Oleksiy Vyalov
ovyalov at google.com
Wed Jun 24 14:05:42 PDT 2015
Hi jingham, labath,
Add const versions of SBFrame::GetFunctionName and SBFrame::IsInlined.
http://reviews.llvm.org/D10711
Files:
include/lldb/API/SBFrame.h
scripts/interface/SBFrame.i
source/API/SBFrame.cpp
Index: include/lldb/API/SBFrame.h
===================================================================
--- include/lldb/API/SBFrame.h
+++ include/lldb/API/SBFrame.h
@@ -91,12 +91,18 @@
const char *
GetFunctionName();
+ const char *
+ GetFunctionName() const;
+
/// Return true if this frame represents an inlined function.
///
/// See also GetFunctionName().
bool
IsInlined();
-
+
+ bool
+ IsInlined() const;
+
/// The version that doesn't supply a 'use_dynamic' value will use the
/// target's default.
lldb::SBValue
Index: scripts/interface/SBFrame.i
===================================================================
--- scripts/interface/SBFrame.i
+++ scripts/interface/SBFrame.i
@@ -128,14 +128,20 @@
const char *
GetFunctionName();
+ const char *
+ GetFunctionName() const;
+
%feature("docstring", "
/// Return true if this frame represents an inlined function.
///
/// See also GetFunctionName().
") IsInlined;
bool
IsInlined();
-
+
+ bool
+ IsInlined() const;
+
%feature("docstring", "
/// The version that doesn't supply a 'use_dynamic' value will use the
/// target's default.
Index: source/API/SBFrame.cpp
===================================================================
--- source/API/SBFrame.cpp
+++ source/API/SBFrame.cpp
@@ -1501,6 +1501,12 @@
bool
SBFrame::IsInlined()
{
+ return static_cast<const SBFrame*>(this)->IsInlined();
+}
+
+bool
+SBFrame::IsInlined() const
+{
Log *log(GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
ExecutionContext exe_ctx(m_opaque_sp.get());
StackFrame *frame = NULL;
@@ -1538,6 +1544,12 @@
const char *
SBFrame::GetFunctionName()
{
+ return static_cast<const SBFrame*>(this)->GetFunctionName();
+}
+
+const char *
+SBFrame::GetFunctionName() const
+{
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
const char *name = NULL;
ExecutionContext exe_ctx(m_opaque_sp.get());
@@ -1590,4 +1602,3 @@
}
return name;
}
-
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D10711.28400.patch
Type: text/x-patch
Size: 2076 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150624/e763af6a/attachment.bin>
More information about the lldb-commits
mailing list