Giving a warning to the user the first time children are truncated by the new cap setting
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@137462 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Commands/CommandObjectFrame.cpp b/source/Commands/CommandObjectFrame.cpp
index d03d3bb..a056638 100644
--- a/source/Commands/CommandObjectFrame.cpp
+++ b/source/Commands/CommandObjectFrame.cpp
@@ -660,6 +660,14 @@
result.SetStatus (eReturnStatusSuccessFinishResult);
}
}
+
+ if (m_interpreter.TruncationWarningNecessary())
+ {
+ result.GetOutputStream().Printf(m_interpreter.TruncationWarningText(),
+ m_cmd_name.c_str());
+ m_interpreter.TruncationWarningGiven();
+ }
+
return result.Succeeded();
}
protected:
diff --git a/source/Commands/CommandObjectTarget.cpp b/source/Commands/CommandObjectTarget.cpp
index 1da39a5..6bf136b 100644
--- a/source/Commands/CommandObjectTarget.cpp
+++ b/source/Commands/CommandObjectTarget.cpp
@@ -717,6 +717,14 @@
result.SetStatus (eReturnStatusFailed);
return false;
}
+
+ if (m_interpreter.TruncationWarningNecessary())
+ {
+ result.GetOutputStream().Printf(m_interpreter.TruncationWarningText(),
+ m_cmd_name.c_str());
+ m_interpreter.TruncationWarningGiven();
+ }
+
return result.Succeeded();
}
diff --git a/source/Core/ValueObject.cpp b/source/Core/ValueObject.cpp
index 6d157be..07adaed 100644
--- a/source/Core/ValueObject.cpp
+++ b/source/Core/ValueObject.cpp
@@ -31,6 +31,7 @@
#include "lldb/Host/Endian.h"
+#include "lldb/Interpreter/CommandInterpreter.h"
#include "lldb/Interpreter/ScriptInterpreterPython.h"
#include "lldb/Symbol/ClangASTType.h"
@@ -2915,7 +2916,10 @@
if (!flat_output)
{
if (print_dotdotdot)
+ {
+ valobj->GetUpdatePoint().GetTargetSP()->GetDebugger().GetCommandInterpreter().ChildrenTruncated();
s.Indent("...\n");
+ }
s.IndentLess();
s.Indent("}\n");
}