@@ -40,7 +40,7 @@ std::string lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
40
40
41
41
// if this ValueObject is an Optional<T> with the Some(T) case selected,
42
42
// retrieve the value of the Some case..
43
- static PointerOrSP
43
+ static ValueObjectSP
44
44
ExtractSomeIfAny (ValueObject *optional,
45
45
bool synthetic_value = false ) {
46
46
if (!optional)
@@ -58,8 +58,8 @@ ExtractSomeIfAny(ValueObject *optional,
58
58
if (!value || value == g_None)
59
59
return nullptr ;
60
60
61
- PointerOrSP value_sp (
62
- non_synth_valobj->GetChildMemberWithName (g_Some, true ). get () );
61
+ ValueObjectSP value_sp (
62
+ non_synth_valobj->GetChildMemberWithName (g_Some, true ));
63
63
if (!value_sp)
64
64
return nullptr ;
65
65
@@ -86,7 +86,7 @@ ExtractSomeIfAny(ValueObject *optional,
86
86
DataExtractor extractor (buffer_sp, process_sp->GetByteOrder (),
87
87
process_sp->GetAddressByteSize ());
88
88
ExecutionContext exe_ctx (process_sp);
89
- value_sp = PointerOrSP (ValueObject::CreateValueObjectFromData (
89
+ value_sp = ValueObjectSP (ValueObject::CreateValueObjectFromData (
90
90
value_sp->GetName ().AsCString (), extractor, exe_ctx, value_type));
91
91
if (!value_sp)
92
92
return nullptr ;
@@ -116,12 +116,12 @@ ExtractSomeIfAny(ValueObject *optional,
116
116
value_sp = value_sp->GetSyntheticValue ();
117
117
118
118
return value_sp;
119
- }
119
+ }
120
120
121
121
static bool
122
122
SwiftOptional_SummaryProvider_Impl (ValueObject &valobj, Stream &stream,
123
123
const TypeSummaryOptions &options) {
124
- PointerOrSP some = ExtractSomeIfAny (&valobj, true );
124
+ ValueObjectSP some = ExtractSomeIfAny (&valobj, true );
125
125
if (!some) {
126
126
stream.Printf (" nil" );
127
127
return true ;
@@ -145,7 +145,7 @@ SwiftOptional_SummaryProvider_Impl(ValueObject &valobj, Stream &stream,
145
145
.SetSkipReferences (false );
146
146
StringSummaryFormat oneliner (oneliner_flags, " " );
147
147
std::string buffer;
148
- oneliner.FormatObject (some, buffer, options);
148
+ oneliner.FormatObject (some. get () , buffer, options);
149
149
stream.Printf (" %s" , buffer.c_str ());
150
150
}
151
151
@@ -172,7 +172,7 @@ bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
172
172
if (!target_valobj)
173
173
return false ;
174
174
175
- PointerOrSP some = ExtractSomeIfAny (target_valobj, true );
175
+ ValueObjectSP some = ExtractSomeIfAny (target_valobj, true );
176
176
177
177
if (!some)
178
178
return true ;
@@ -191,7 +191,7 @@ bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
191
191
return false ;
192
192
return some->HasChildren ();
193
193
}
194
- return some->HasChildren () && summary_sp->DoesPrintChildren (some);
194
+ return some->HasChildren () && summary_sp->DoesPrintChildren (some. get () );
195
195
}
196
196
197
197
bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
0 commit comments