summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/include/lldb/Core/ValueObject.h11
-rw-r--r--lldb/include/lldb/Core/ValueObjectChild.h3
-rw-r--r--lldb/include/lldb/Core/ValueObjectDynamicValue.h13
-rw-r--r--lldb/include/lldb/Core/ValueObjectSyntheticFilter.h15
-rw-r--r--lldb/source/Core/ValueObjectChild.cpp8
5 files changed, 33 insertions, 17 deletions
diff --git a/lldb/include/lldb/Core/ValueObject.h b/lldb/include/lldb/Core/ValueObject.h
index b9e1e54fe7a..cdc507093b2 100644
--- a/lldb/include/lldb/Core/ValueObject.h
+++ b/lldb/include/lldb/Core/ValueObject.h
@@ -858,10 +858,10 @@ public:
return m_update_point.IsConstant();
}
- virtual bool
+ bool
NeedsUpdating ()
{
- const bool accept_invalid_exe_ctx = false;
+ const bool accept_invalid_exe_ctx = CanUpdateWithInvalidExecutionContext();
return m_update_point.NeedsUpdating(accept_invalid_exe_ctx);
}
@@ -1137,6 +1137,7 @@ protected:
m_did_calculate_complete_objc_class_type:1,
m_is_synthetic_children_generated:1;
+ friend class ValueObjectChild;
friend class ClangExpressionDeclMap; // For GetValue
friend class ClangExpressionVariable; // For SetName
friend class Target; // For SetName
@@ -1171,6 +1172,12 @@ protected:
virtual bool
UpdateValue () = 0;
+ virtual bool
+ CanUpdateWithInvalidExecutionContext ()
+ {
+ return false;
+ }
+
virtual void
CalculateDynamicValue (lldb::DynamicValueType use_dynamic);
diff --git a/lldb/include/lldb/Core/ValueObjectChild.h b/lldb/include/lldb/Core/ValueObjectChild.h
index 7bbfe8a662d..bf8707ea3b0 100644
--- a/lldb/include/lldb/Core/ValueObjectChild.h
+++ b/lldb/include/lldb/Core/ValueObjectChild.h
@@ -83,6 +83,9 @@ public:
protected:
virtual bool
UpdateValue ();
+
+ virtual bool
+ CanUpdateWithInvalidExecutionContext ();
virtual ClangASTType
GetClangTypeImpl ()
diff --git a/lldb/include/lldb/Core/ValueObjectDynamicValue.h b/lldb/include/lldb/Core/ValueObjectDynamicValue.h
index 09f2f195e29..8d42706be16 100644
--- a/lldb/include/lldb/Core/ValueObjectDynamicValue.h
+++ b/lldb/include/lldb/Core/ValueObjectDynamicValue.h
@@ -62,13 +62,6 @@ public:
return false;
}
- virtual bool
- NeedsUpdating ()
- {
- const bool accept_invalid_exe_ctx = true;
- return m_update_point.NeedsUpdating(accept_invalid_exe_ctx);
- }
-
virtual ValueObject *
GetParent()
{
@@ -116,6 +109,12 @@ protected:
virtual bool
UpdateValue ();
+ virtual bool
+ CanUpdateWithInvalidExecutionContext ()
+ {
+ return true;
+ }
+
virtual lldb::DynamicValueType
GetDynamicValueTypeImpl ()
{
diff --git a/lldb/include/lldb/Core/ValueObjectSyntheticFilter.h b/lldb/include/lldb/Core/ValueObjectSyntheticFilter.h
index 2ee14f71446..88824ef4fa5 100644
--- a/lldb/include/lldb/Core/ValueObjectSyntheticFilter.h
+++ b/lldb/include/lldb/Core/ValueObjectSyntheticFilter.h
@@ -145,14 +145,7 @@ public:
{
return false;
}
-
- virtual bool
- NeedsUpdating ()
- {
- const bool accept_invalid_exe_ctx = true;
- return m_update_point.NeedsUpdating(accept_invalid_exe_ctx);
- }
-
+
virtual bool
SetValueFromCString (const char *value_str, Error& error);
@@ -163,6 +156,12 @@ protected:
virtual bool
UpdateValue ();
+ virtual bool
+ CanUpdateWithInvalidExecutionContext ()
+ {
+ return true;
+ }
+
virtual ClangASTType
GetClangTypeImpl ();
diff --git a/lldb/source/Core/ValueObjectChild.cpp b/lldb/source/Core/ValueObjectChild.cpp
index 2b3c8344af8..c1e45e1f48d 100644
--- a/lldb/source/Core/ValueObjectChild.cpp
+++ b/lldb/source/Core/ValueObjectChild.cpp
@@ -110,6 +110,14 @@ ValueObjectChild::GetDisplayTypeName()
}
bool
+ValueObjectChild::CanUpdateWithInvalidExecutionContext ()
+{
+ if (m_parent)
+ return m_parent->CanUpdateWithInvalidExecutionContext();
+ return this->ValueObject::CanUpdateWithInvalidExecutionContext();
+}
+
+bool
ValueObjectChild::UpdateValue ()
{
m_error.Clear();
OpenPOWER on IntegriCloud