clayborg requested changes to this revision. clayborg added a comment. This revision now requires changes to proceed.
So any functions that are "StructureData::<class> *" raw pointers in this source code should switch over to returning on of the StruturedData definitions from StructuredData.h: class StructuredData { typedef std::shared_ptr<Object> ObjectSP; typedef std::shared_ptr<Array> ArraySP; typedef std::shared_ptr<Integer> IntegerSP; typedef std::shared_ptr<Float> FloatSP; typedef std::shared_ptr<Boolean> BooleanSP; typedef std::shared_ptr<String> StringSP; typedef std::shared_ptr<Dictionary> DictionarySP; typedef std::shared_ptr<Generic> GenericSP; ================ Comment at: lldb/source/Plugins/InstrumentationRuntime/TSan/InstrumentationRuntimeTSan.cpp:227 static StructuredData::Array *ConvertToStructuredArray( ValueObjectSP return_value_sp, const std::string &items_name, ---------------- JDevlieghere wrote: > fixathon wrote: > > Function creating heap-based allocation > Could this return a unique_ptr instead? This should return StructureData::ArraySP. Look at the other usages of this function where they will eventually put the result into a dictionary ================ Comment at: lldb/source/Plugins/InstrumentationRuntime/TSan/InstrumentationRuntimeTSan.cpp:351 StructuredData::Array *stacks = ConvertToStructuredArray( main_value, ".stacks", ".stack_count", ---------------- If we make ConvertToStructuredArray return a ArraySP, then this code would change Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131900/new/ https://reviews.llvm.org/D131900 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits