diff options
author | Alex Langford <alangford@apple.com> | 2023-05-16 10:38:49 -0700 |
---|---|---|
committer | Alex Langford <alangford@apple.com> | 2023-05-16 10:39:44 -0700 |
commit | d95aec2de2be114b4c331783fcceae233bf49aff (patch) | |
tree | 7ef0f03fc34a6b313076754a26573cf979e6f620 /lldb | |
parent | 198f6a9f36e4ffd056e27fac8c0636476958d3cf (diff) | |
download | llvm-d95aec2de2be114b4c331783fcceae233bf49aff.tar.gz |
[lldb][NFCI] Small adjustment to Breakpoint::AddName
m_name_list is a std::unordered_set<std::string>, we can insert the
string directly instead of grabbing the c_str and creating yet another
one.
Diffstat (limited to 'lldb')
-rw-r--r-- | lldb/source/Breakpoint/Breakpoint.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/source/Breakpoint/Breakpoint.cpp b/lldb/source/Breakpoint/Breakpoint.cpp index 54ac21ac9e48..9f00c967be43 100644 --- a/lldb/source/Breakpoint/Breakpoint.cpp +++ b/lldb/source/Breakpoint/Breakpoint.cpp @@ -842,7 +842,7 @@ bool Breakpoint::HasResolvedLocations() const { size_t Breakpoint::GetNumLocations() const { return m_locations.GetSize(); } bool Breakpoint::AddName(llvm::StringRef new_name) { - m_name_list.insert(new_name.str().c_str()); + m_name_list.insert(new_name.str()); return true; } |