@@ -40,7 +40,7 @@ std::string lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
4040
4141// if this ValueObject is an Optional<T> with the Some(T) case selected,
4242// retrieve the value of the Some case..
43- static PointerOrSP
43+ static ValueObjectSP
4444ExtractSomeIfAny (ValueObject *optional,
4545 bool synthetic_value = false ) {
4646 if (!optional)
@@ -58,8 +58,8 @@ ExtractSomeIfAny(ValueObject *optional,
5858 if (!value || value == g_None)
5959 return nullptr ;
6060
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 ));
6363 if (!value_sp)
6464 return nullptr ;
6565
@@ -86,7 +86,7 @@ ExtractSomeIfAny(ValueObject *optional,
8686 DataExtractor extractor (buffer_sp, process_sp->GetByteOrder (),
8787 process_sp->GetAddressByteSize ());
8888 ExecutionContext exe_ctx (process_sp);
89- value_sp = PointerOrSP (ValueObject::CreateValueObjectFromData (
89+ value_sp = ValueObjectSP (ValueObject::CreateValueObjectFromData (
9090 value_sp->GetName ().AsCString (), extractor, exe_ctx, value_type));
9191 if (!value_sp)
9292 return nullptr ;
@@ -116,12 +116,12 @@ ExtractSomeIfAny(ValueObject *optional,
116116 value_sp = value_sp->GetSyntheticValue ();
117117
118118 return value_sp;
119- }
119+ }
120120
121121static bool
122122SwiftOptional_SummaryProvider_Impl (ValueObject &valobj, Stream &stream,
123123 const TypeSummaryOptions &options) {
124- PointerOrSP some = ExtractSomeIfAny (&valobj, true );
124+ ValueObjectSP some = ExtractSomeIfAny (&valobj, true );
125125 if (!some) {
126126 stream.Printf (" nil" );
127127 return true ;
@@ -145,7 +145,7 @@ SwiftOptional_SummaryProvider_Impl(ValueObject &valobj, Stream &stream,
145145 .SetSkipReferences (false );
146146 StringSummaryFormat oneliner (oneliner_flags, " " );
147147 std::string buffer;
148- oneliner.FormatObject (some, buffer, options);
148+ oneliner.FormatObject (some. get () , buffer, options);
149149 stream.Printf (" %s" , buffer.c_str ());
150150 }
151151
@@ -172,7 +172,7 @@ bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
172172 if (!target_valobj)
173173 return false ;
174174
175- PointerOrSP some = ExtractSomeIfAny (target_valobj, true );
175+ ValueObjectSP some = ExtractSomeIfAny (target_valobj, true );
176176
177177 if (!some)
178178 return true ;
@@ -191,7 +191,7 @@ bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
191191 return false ;
192192 return some->HasChildren ();
193193 }
194- return some->HasChildren () && summary_sp->DoesPrintChildren (some);
194+ return some->HasChildren () && summary_sp->DoesPrintChildren (some. get () );
195195}
196196
197197bool lldb_private::formatters::swift::SwiftOptionalSummaryProvider::
0 commit comments