We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b6e6f45 + 052a44d commit d28e4b9Copy full SHA for d28e4b9
lldb/source/Plugins/TypeSystem/Swift/TypeSystemSwiftTypeRef.cpp
@@ -2926,11 +2926,11 @@ bool TypeSystemSwiftTypeRef::DumpTypeValue(
2926
data_byte_size = 4;
2927
break;
2928
case eFormatAddressInfo:
2929
- if (data_byte_size == 0) {
2930
- data_byte_size = exe_scope->CalculateTarget()
2931
- ->GetArchitecture()
2932
- .GetAddressByteSize();
2933
- item_count = 1;
+ if (data_byte_size == 0 && exe_scope) {
+ if (auto target_sp = exe_scope->CalculateTarget()) {
+ data_byte_size = target_sp->GetArchitecture().GetAddressByteSize();
+ item_count = 1;
+ }
2934
}
2935
2936
default:
0 commit comments