[Lldb-commits] [PATCH] D152870: [lldb][NFCI] Remove StructuredData::Array::GetItemAtIndexAsString overloads with ConstString

Alex Langford via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Jul 6 09:22:51 PDT 2023


bulbazord added inline comments.


================
Comment at: lldb/source/Target/DynamicRegisterInfo.cpp:204
+        m_sets.push_back(
+            {ConstString(set_name).AsCString(), nullptr, 0, nullptr});
       } else {
----------------
mib wrote:
> I guess `m_sets` is a vector of `char*` ... Should we change it to `lldb::StringList` or `llvm::StringSet` so we don't have to create a `ConstString` here ?
`m_sets` is a vector of `lldb_private::RegisterSet` (which contains a `const char *`). I think it's assumed that they are backed by a `ConstString`. Because `RegisterSet` is defined in `lldb-private-types.h` we'd have to move it somewhere else before we could actually use any types other than `const char *`, I think?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D152870/new/

https://reviews.llvm.org/D152870



More information about the lldb-commits mailing list