File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
lldb/source/Plugins/Language/Swift Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -884,6 +884,15 @@ std::vector<ConstString> SwiftLanguage::GetPossibleFormattersMatches(
884
884
if (use_dynamic == lldb::eNoDynamicValues)
885
885
return result;
886
886
887
+ // There is no point in attempting to format Clang types here, since
888
+ // FormatManager will try to format all Swift types also as
889
+ // Objective-C types and vice versa. Due to the incomplete
890
+ // ClangImporter implementation for C++, continuing here for
891
+ // Objective-C++ types can actually lead to crashes that can be
892
+ // avoided by just formatting those types as Objective-C types.
893
+ if (valobj.GetObjectRuntimeLanguage () == eLanguageTypeObjC)
894
+ return result;
895
+
887
896
SwiftASTContextLock scratch_ctx_lock (&valobj.GetExecutionContextRef ());
888
897
CompilerType compiler_type (valobj.GetCompilerType ());
889
898
You can’t perform that action at this time.
0 commit comments