Updated the revision of LLVM/Clang used by LLDB.
This takes two important changes:
- Calling blocks is now supported. You need to
cast their return values, but that works fine.
- We now can correctly run JIT-compiled
expressions that use floating-point numbers.
Also, we have taken a fix that allows us to
ignore access control in Objective-C as in C++.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@152286 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Target/ObjCLanguageRuntime.cpp b/source/Target/ObjCLanguageRuntime.cpp
index 0076ff0..6d6caef 100644
--- a/source/Target/ObjCLanguageRuntime.cpp
+++ b/source/Target/ObjCLanguageRuntime.cpp
@@ -27,7 +27,8 @@
}
ObjCLanguageRuntime::ObjCLanguageRuntime (Process *process) :
- LanguageRuntime (process)
+ LanguageRuntime (process),
+ m_has_new_literals_and_indexing (eLazyBoolCalculate)
{
}
diff --git a/source/Target/StackFrame.cpp b/source/Target/StackFrame.cpp
index 1d6cb93..4b462ee 100644
--- a/source/Target/StackFrame.cpp
+++ b/source/Target/StackFrame.cpp
@@ -724,13 +724,23 @@
if (valobj_sp->IsPointerType ())
{
- if (no_synth_child == false
- &&
- ClangASTType::GetMinimumLanguage(valobj_sp->GetClangAST(),
- valobj_sp->GetClangType()) == eLanguageTypeObjC /* is ObjC pointer */
- &&
- ClangASTContext::IsPointerType(ClangASTType::GetPointeeType(valobj_sp->GetClangType())) == false /* is not double-ptr */)
+ bool is_objc_pointer = true;
+
+ if (ClangASTType::GetMinimumLanguage(valobj_sp->GetClangAST(), valobj_sp->GetClangType()) != eLanguageTypeObjC)
+ is_objc_pointer = false;
+ else if (!ClangASTContext::IsPointerType(valobj_sp->GetClangType()))
+ is_objc_pointer = false;
+
+ if (no_synth_child && is_objc_pointer)
{
+ error.SetErrorStringWithFormat("\"(%s) %s\" is an Objective-C pointer, and cannot be subscripted",
+ valobj_sp->GetTypeName().AsCString("<invalid type>"),
+ var_expr_path_strm.GetString().c_str());
+
+ return ValueObjectSP();
+ }
+ else if (is_objc_pointer)
+ {
// dereferencing ObjC variables is not valid.. so let's try and recur to synthetic children
ValueObjectSP synthetic = valobj_sp->GetSyntheticValue(eUseSyntheticFilter);
if (synthetic.get() == NULL /* no synthetic */