Skip to content

Commit a378833

Browse files
mstorsjomedismailben
authored andcommitted
[lldb] Fix building with latest libc++
Since https://reviews.llvm.org/D157058 in libc++, the base template for char_traits has been removed - it is only provided for char, wchar_t, char8_t, char16_t and char32_t. (Thus, to use basic_string with a type other than those, we'd need to supply suitable traits ourselves.) For this particular use, a vector works just as well as basic_string. Differential Revision: https://reviews.llvm.org/D157589 (cherry picked from commit 68744ff)
1 parent d3b6753 commit a378833

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -631,7 +631,7 @@ static void WriteRegisterValueInHexFixedWidth(
631631
} else {
632632
// Zero-out any unreadable values.
633633
if (reg_info.byte_size > 0) {
634-
std::basic_string<uint8_t> zeros(reg_info.byte_size, '\0');
634+
std::vector<uint8_t> zeros(reg_info.byte_size, '\0');
635635
AppendHexValue(response, zeros.data(), zeros.size(), false);
636636
}
637637
}

0 commit comments

Comments
 (0)