Skip to content

Commit 2a4f2a3

Browse files
n2h9JDevlieghere
andauthored
Update lldb/source/API/SBTarget.cpp
Co-authored-by: Jonas Devlieghere <[email protected]>
1 parent a3620de commit 2a4f2a3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lldb/source/API/SBTarget.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1618,9 +1618,9 @@ const char *SBTarget::GetArchName() {
16181618
LLDB_INSTRUMENT_VA(this);
16191619

16201620
if (TargetSP target_sp = GetSP()) {
1621-
std::string arch_name =
1622-
target_sp->GetArchitecture().GetTriple().getArchName().str();
1623-
ConstString const_arch_name(arch_name.c_str());
1621+
llvm::StringRef arch_name =
1622+
target_sp->GetArchitecture().GetTriple().getArchName();
1623+
ConstString const_arch_name(arch_name);
16241624

16251625
return const_arch_name.GetCString();
16261626
}

0 commit comments

Comments
 (0)