[Lldb-commits] [lldb] 46fb5d5 - [lldb][NFC] clang-format CPlusPlusLanguage.cpp
Raphael Isemann via lldb-commits
lldb-commits at lists.llvm.org
Thu Oct 21 01:02:29 PDT 2021
Author: Raphael Isemann
Date: 2021-10-21T10:01:18+02:00
New Revision: 46fb5d5ddffdccbd14a09c7dcff63de6fef63c07
URL: https://github.com/llvm/llvm-project/commit/46fb5d5ddffdccbd14a09c7dcff63de6fef63c07
DIFF: https://github.com/llvm/llvm-project/commit/46fb5d5ddffdccbd14a09c7dcff63de6fef63c07.diff
LOG: [lldb][NFC] clang-format CPlusPlusLanguage.cpp
Added:
Modified:
lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
Removed:
################################################################################
diff --git a/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp b/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
index 6dd0a07780f12..2fabbff61c66b 100644
--- a/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
+++ b/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
@@ -326,13 +326,12 @@ class ManglingSubstitutor
public:
ManglingSubstitutor() : Base(nullptr, nullptr) {}
- template<typename... Ts>
+ template <typename... Ts>
ConstString substitute(llvm::StringRef Mangled, Ts &&... Vals) {
this->getDerived().reset(Mangled, std::forward<Ts>(Vals)...);
return substituteImpl(Mangled);
}
-
protected:
void reset(llvm::StringRef Mangled) {
Base::reset(Mangled.begin(), Mangled.end());
@@ -386,7 +385,6 @@ class ManglingSubstitutor
llvm::StringRef(Written, std::distance(Written, currentParserPos()));
Written = currentParserPos();
}
-
};
/// Given a mangled function `Mangled`, replace all the primitive function type
@@ -560,26 +558,23 @@ static void LoadLibCxxFormatters(lldb::TypeCategoryImplSP cpp_category_sp) {
AddCXXSummary(cpp_category_sp,
lldb_private::formatters::LibcxxStringSummaryProviderUTF16,
"std::u16string summary provider",
- ConstString(
- "^std::__[[:alnum:]]+::basic_string<char16_t, "
- "std::__[[:alnum:]]+::char_traits<char16_t>, "
- "std::__[[:alnum:]]+::allocator<char16_t> >$"),
+ ConstString("^std::__[[:alnum:]]+::basic_string<char16_t, "
+ "std::__[[:alnum:]]+::char_traits<char16_t>, "
+ "std::__[[:alnum:]]+::allocator<char16_t> >$"),
stl_summary_flags, true);
AddCXXSummary(cpp_category_sp,
lldb_private::formatters::LibcxxStringSummaryProviderUTF32,
"std::u32string summary provider",
- ConstString(
- "^std::__[[:alnum:]]+::basic_string<char32_t, "
- "std::__[[:alnum:]]+::char_traits<char32_t>, "
- "std::__[[:alnum:]]+::allocator<char32_t> >$"),
+ ConstString("^std::__[[:alnum:]]+::basic_string<char32_t, "
+ "std::__[[:alnum:]]+::char_traits<char32_t>, "
+ "std::__[[:alnum:]]+::allocator<char32_t> >$"),
stl_summary_flags, true);
- AddCXXSummary(cpp_category_sp,
- lldb_private::formatters::LibcxxWStringSummaryProvider,
- "std::wstring summary provider",
- ConstString("^std::__[[:alnum:]]+::wstring$"),
- stl_summary_flags, true);
+ AddCXXSummary(
+ cpp_category_sp, lldb_private::formatters::LibcxxWStringSummaryProvider,
+ "std::wstring summary provider",
+ ConstString("^std::__[[:alnum:]]+::wstring$"), stl_summary_flags, true);
AddCXXSummary(cpp_category_sp,
lldb_private::formatters::LibcxxWStringSummaryProvider,
"std::wstring summary provider",
@@ -776,11 +771,11 @@ static void LoadLibCxxFormatters(lldb::TypeCategoryImplSP cpp_category_sp) {
"libc++ std::tuple summary provider",
ConstString("^std::__[[:alnum:]]+::tuple<.*>(( )?&)?$"),
stl_summary_flags, true);
- AddCXXSummary(
- cpp_category_sp, lldb_private::formatters::LibCxxAtomicSummaryProvider,
- "libc++ std::atomic summary provider",
- ConstString("^std::__[[:alnum:]]+::atomic<.+>$"), stl_summary_flags,
- true);
+ AddCXXSummary(cpp_category_sp,
+ lldb_private::formatters::LibCxxAtomicSummaryProvider,
+ "libc++ std::atomic summary provider",
+ ConstString("^std::__[[:alnum:]]+::atomic<.+>$"),
+ stl_summary_flags, true);
AddCXXSummary(cpp_category_sp,
lldb_private::formatters::LibcxxOptionalSummaryProvider,
"libc++ std::optional summary provider",
@@ -867,7 +862,8 @@ static void LoadLibStdcppFormatters(lldb::TypeCategoryImplSP cpp_category_sp) {
"std::allocator<char> >"),
cxx11_string_summary_sp);
cpp_category_sp->GetTypeSummariesContainer()->Add(
- ConstString("std::__cxx11::basic_string<unsigned char, std::char_traits<unsigned char>, "
+ ConstString("std::__cxx11::basic_string<unsigned char, "
+ "std::char_traits<unsigned char>, "
"std::allocator<unsigned char> >"),
cxx11_string_summary_sp);
@@ -1172,9 +1168,8 @@ CPlusPlusLanguage::GetHardcodedSynthetics() {
llvm::call_once(g_initialize, []() -> void {
g_formatters.push_back([](lldb_private::ValueObject &valobj,
- lldb::DynamicValueType,
- FormatManager &
- fmt_mgr) -> SyntheticChildren::SharedPointer {
+ lldb::DynamicValueType, FormatManager &fmt_mgr)
+ -> SyntheticChildren::SharedPointer {
static CXXSyntheticChildren::SharedPointer formatter_sp(
new CXXSyntheticChildren(
SyntheticChildren::Flags()
@@ -1191,9 +1186,8 @@ CPlusPlusLanguage::GetHardcodedSynthetics() {
return nullptr;
});
g_formatters.push_back([](lldb_private::ValueObject &valobj,
- lldb::DynamicValueType,
- FormatManager &
- fmt_mgr) -> SyntheticChildren::SharedPointer {
+ lldb::DynamicValueType, FormatManager &fmt_mgr)
+ -> SyntheticChildren::SharedPointer {
static CXXSyntheticChildren::SharedPointer formatter_sp(
new CXXSyntheticChildren(
SyntheticChildren::Flags()
@@ -1208,7 +1202,6 @@ CPlusPlusLanguage::GetHardcodedSynthetics() {
}
return nullptr;
});
-
});
return g_formatters;
More information about the lldb-commits
mailing list