We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b210b13 + 2e31fa3 commit 107de6aCopy full SHA for 107de6a
lldb/source/Plugins/TypeSystem/Swift/TypeSystemSwiftTypeRef.cpp
@@ -229,10 +229,13 @@ TypeSP TypeSystemSwiftTypeRef::LookupClangType(
229
return result;
230
}
231
232
- SwiftASTContext *target_holder = GetSwiftASTContext();
233
- if (!target_holder)
234
- return {};
235
- TargetSP target_sp = target_holder->GetTargetWP().lock();
+ TargetSP target_sp = GetTargetWP().lock();
+ if (!target_sp) {
+ SwiftASTContext *target_holder = GetSwiftASTContext();
+ if (!target_holder)
236
+ return {};
237
+ target_sp = target_holder->GetTargetWP().lock();
238
+ }
239
if (!target_sp)
240
return {};
241
target_sp->GetImages().ForEach([&](const ModuleSP &module) -> bool {
0 commit comments