[Lldb-commits] [lldb] 47b9aad - [lldb] Remove redundant member initialization (NFC)

Kazu Hirata via lldb-commits lldb-commits at lists.llvm.org
Sun Jan 9 12:21:25 PST 2022


Author: Kazu Hirata
Date: 2022-01-09T12:21:04-08:00
New Revision: 47b9aadb3215e914119d0c45827ea58cb7499204

URL: https://github.com/llvm/llvm-project/commit/47b9aadb3215e914119d0c45827ea58cb7499204
DIFF: https://github.com/llvm/llvm-project/commit/47b9aadb3215e914119d0c45827ea58cb7499204.diff

LOG: [lldb] Remove redundant member initialization (NFC)

Added: 
    

Modified: 
    lldb/include/lldb/Breakpoint/BreakpointOptions.h
    lldb/include/lldb/Breakpoint/WatchpointOptions.h
    lldb/include/lldb/Core/Address.h
    lldb/include/lldb/Core/Declaration.h
    lldb/include/lldb/Core/Disassembler.h
    lldb/include/lldb/Core/FormatEntity.h
    lldb/include/lldb/Core/LoadedModuleInfoList.h
    lldb/include/lldb/Core/Module.h
    lldb/include/lldb/Core/ModuleSpec.h
    lldb/include/lldb/Core/StructuredDataImpl.h
    lldb/include/lldb/Core/ThreadSafeValue.h
    lldb/include/lldb/Core/Value.h
    lldb/include/lldb/Core/ValueObject.h
    lldb/include/lldb/DataFormatters/FormatClasses.h
    lldb/include/lldb/DataFormatters/TypeSynthetic.h
    lldb/include/lldb/Expression/IRExecutionUnit.h
    lldb/include/lldb/Host/Debug.h
    lldb/include/lldb/Host/FileSystem.h
    lldb/include/lldb/Interpreter/OptionValueArray.h
    lldb/include/lldb/Symbol/CompactUnwindInfo.h
    lldb/include/lldb/Symbol/DWARFCallFrameInfo.h
    lldb/include/lldb/Symbol/ObjectContainer.h
    lldb/include/lldb/Symbol/Type.h
    lldb/include/lldb/Symbol/UnwindPlan.h
    lldb/include/lldb/Target/InstrumentationRuntime.h
    lldb/include/lldb/Target/Language.h
    lldb/include/lldb/Target/Platform.h
    lldb/include/lldb/Target/Process.h
    lldb/include/lldb/Target/RegisterCheckpoint.h
    lldb/include/lldb/Target/SectionLoadHistory.h
    lldb/include/lldb/Target/SectionLoadList.h
    lldb/include/lldb/Target/Unwind.h
    lldb/include/lldb/Target/UnwindLLDB.h
    lldb/include/lldb/Utility/Environment.h
    lldb/include/lldb/Utility/Event.h
    lldb/include/lldb/Utility/GDBRemote.h
    lldb/include/lldb/Utility/Predicate.h
    lldb/include/lldb/Utility/ProcessInfo.h
    lldb/include/lldb/Utility/ReproducerProvider.h
    lldb/include/lldb/Utility/SharedCluster.h
    lldb/include/lldb/Utility/StreamTee.h
    lldb/include/lldb/Utility/StringExtractorGDBRemote.h
    lldb/include/lldb/Utility/StructuredData.h

Removed: 
    


################################################################################
diff  --git a/lldb/include/lldb/Breakpoint/BreakpointOptions.h b/lldb/include/lldb/Breakpoint/BreakpointOptions.h
index 7b78265920a2e..ec39c976f7ac0 100644
--- a/lldb/include/lldb/Breakpoint/BreakpointOptions.h
+++ b/lldb/include/lldb/Breakpoint/BreakpointOptions.h
@@ -43,11 +43,10 @@ friend class Breakpoint;
                      | eCondition | eAutoContinue)
   };
   struct CommandData {
-    CommandData() : user_source(), script_source() {}
+    CommandData() {}
 
     CommandData(const StringList &user_source, lldb::ScriptLanguage interp)
-        : user_source(user_source), script_source(), interpreter(interp),
-          stop_on_error(true) {}
+        : user_source(user_source), interpreter(interp), stop_on_error(true) {}
 
     virtual ~CommandData() = default;
 

diff  --git a/lldb/include/lldb/Breakpoint/WatchpointOptions.h b/lldb/include/lldb/Breakpoint/WatchpointOptions.h
index fbfcb91c4249e..c5ad90c334c48 100644
--- a/lldb/include/lldb/Breakpoint/WatchpointOptions.h
+++ b/lldb/include/lldb/Breakpoint/WatchpointOptions.h
@@ -166,7 +166,7 @@ class WatchpointOptions {
                            lldb::user_id_t watch_id);
 
   struct CommandData {
-    CommandData() : user_source(), script_source() {}
+    CommandData() {}
 
     ~CommandData() = default;
 

diff  --git a/lldb/include/lldb/Core/Address.h b/lldb/include/lldb/Core/Address.h
index dc50e27ca277a..f77ffc2fd25e6 100644
--- a/lldb/include/lldb/Core/Address.h
+++ b/lldb/include/lldb/Core/Address.h
@@ -116,7 +116,7 @@ class Address {
   ///
   /// Initialize with a invalid section (NULL) and an invalid offset
   /// (LLDB_INVALID_ADDRESS).
-  Address() : m_section_wp() {}
+  Address() {}
 
   /// Copy constructor
   ///

diff  --git a/lldb/include/lldb/Core/Declaration.h b/lldb/include/lldb/Core/Declaration.h
index f81de21bc8f8b..67ab09f21c8d5 100644
--- a/lldb/include/lldb/Core/Declaration.h
+++ b/lldb/include/lldb/Core/Declaration.h
@@ -24,7 +24,7 @@ namespace lldb_private {
 class Declaration {
 public:
   /// Default constructor.
-  Declaration() : m_file() {}
+  Declaration() {}
 
   /// Construct with file specification, and optional line and column.
   ///
@@ -45,7 +45,7 @@ class Declaration {
 
   /// Construct with a pointer to another Declaration object.
   Declaration(const Declaration *decl_ptr)
-      : m_file(), m_line(0), m_column(LLDB_INVALID_COLUMN_NUMBER) {
+      : m_line(0), m_column(LLDB_INVALID_COLUMN_NUMBER) {
     if (decl_ptr)
       *this = *decl_ptr;
   }

diff  --git a/lldb/include/lldb/Core/Disassembler.h b/lldb/include/lldb/Core/Disassembler.h
index 0925bf358b9c3..87979fd925846 100644
--- a/lldb/include/lldb/Core/Disassembler.h
+++ b/lldb/include/lldb/Core/Disassembler.h
@@ -465,7 +465,7 @@ class Disassembler : public std::enable_shared_from_this<Disassembler>,
     uint32_t line = LLDB_INVALID_LINE_NUMBER;
     uint32_t column = 0;
 
-    SourceLine() : file() {}
+    SourceLine() {}
 
     bool operator==(const SourceLine &rhs) const {
       return file == rhs.file && line == rhs.line && rhs.column == column;
@@ -489,7 +489,7 @@ class Disassembler : public std::enable_shared_from_this<Disassembler>,
     // Whether to print a blank line at the end of the source lines.
     bool print_source_context_end_eol = true;
 
-    SourceLinesToDisplay() : lines() {}
+    SourceLinesToDisplay() {}
   };
 
   // Get the function's declaration line number, hopefully a line number

diff  --git a/lldb/include/lldb/Core/FormatEntity.h b/lldb/include/lldb/Core/FormatEntity.h
index ecae8500df40d..cd9019d555547 100644
--- a/lldb/include/lldb/Core/FormatEntity.h
+++ b/lldb/include/lldb/Core/FormatEntity.h
@@ -148,7 +148,7 @@ class FormatEntity {
 
     Entry(Type t = Type::Invalid, const char *s = nullptr,
           const char *f = nullptr)
-        : string(s ? s : ""), printf_format(f ? f : ""), children(), type(t) {}
+        : string(s ? s : ""), printf_format(f ? f : ""), type(t) {}
 
     Entry(llvm::StringRef s);
     Entry(char ch);

diff  --git a/lldb/include/lldb/Core/LoadedModuleInfoList.h b/lldb/include/lldb/Core/LoadedModuleInfoList.h
index ad6da2bd75592..3f65ddc06d733 100644
--- a/lldb/include/lldb/Core/LoadedModuleInfoList.h
+++ b/lldb/include/lldb/Core/LoadedModuleInfoList.h
@@ -101,7 +101,7 @@ class LoadedModuleInfoList {
     lldb::addr_t m_dynamic;
   };
 
-  LoadedModuleInfoList() : m_list() {}
+  LoadedModuleInfoList() {}
 
   void add(const LoadedModuleInfo &mod) { m_list.push_back(mod); }
 

diff  --git a/lldb/include/lldb/Core/Module.h b/lldb/include/lldb/Core/Module.h
index 6b1e4f8f3704b..d53481a1c7202 100644
--- a/lldb/include/lldb/Core/Module.h
+++ b/lldb/include/lldb/Core/Module.h
@@ -905,7 +905,7 @@ class Module : public std::enable_shared_from_this<Module>,
   /// correctly.
   class LookupInfo {
   public:
-    LookupInfo() : m_name(), m_lookup_name() {}
+    LookupInfo() {}
 
     LookupInfo(ConstString name, lldb::FunctionNameType name_type_mask,
                lldb::LanguageType language);

diff  --git a/lldb/include/lldb/Core/ModuleSpec.h b/lldb/include/lldb/Core/ModuleSpec.h
index 8e5deebbab9a7..bcf4ec30a673c 100644
--- a/lldb/include/lldb/Core/ModuleSpec.h
+++ b/lldb/include/lldb/Core/ModuleSpec.h
@@ -25,18 +25,14 @@ namespace lldb_private {
 
 class ModuleSpec {
 public:
-  ModuleSpec()
-      : m_file(), m_platform_file(), m_symbol_file(), m_arch(), m_uuid(),
-        m_object_name(), m_source_mappings() {}
+  ModuleSpec() {}
 
   /// If the \c data argument is passed, its contents will be used
   /// as the module contents instead of trying to read them from
   /// \c file_spec .
   ModuleSpec(const FileSpec &file_spec, const UUID &uuid = UUID(),
              lldb::DataBufferSP data = lldb::DataBufferSP())
-      : m_file(file_spec), m_platform_file(), m_symbol_file(), m_arch(),
-        m_uuid(uuid), m_object_name(), m_object_offset(0), m_source_mappings(),
-        m_data(data) {
+      : m_file(file_spec), m_uuid(uuid), m_object_offset(0), m_data(data) {
     if (data)
       m_object_size = data->GetByteSize();
     else if (m_file)
@@ -44,10 +40,8 @@ class ModuleSpec {
   }
 
   ModuleSpec(const FileSpec &file_spec, const ArchSpec &arch)
-      : m_file(file_spec), m_platform_file(), m_symbol_file(), m_arch(arch),
-        m_uuid(), m_object_name(), m_object_offset(0),
-        m_object_size(FileSystem::Instance().GetByteSize(file_spec)),
-        m_source_mappings() {}
+      : m_file(file_spec), m_arch(arch), m_object_offset(0),
+        m_object_size(FileSystem::Instance().GetByteSize(file_spec)) {}
 
   FileSpec *GetFileSpecPtr() { return (m_file ? &m_file : nullptr); }
 
@@ -279,9 +273,9 @@ class ModuleSpec {
 
 class ModuleSpecList {
 public:
-  ModuleSpecList() : m_specs(), m_mutex() {}
+  ModuleSpecList() {}
 
-  ModuleSpecList(const ModuleSpecList &rhs) : m_specs(), m_mutex() {
+  ModuleSpecList(const ModuleSpecList &rhs) {
     std::lock_guard<std::recursive_mutex> lhs_guard(m_mutex);
     std::lock_guard<std::recursive_mutex> rhs_guard(rhs.m_mutex);
     m_specs = rhs.m_specs;

diff  --git a/lldb/include/lldb/Core/StructuredDataImpl.h b/lldb/include/lldb/Core/StructuredDataImpl.h
index 8930ebff81667..355aa77c4e5ce 100644
--- a/lldb/include/lldb/Core/StructuredDataImpl.h
+++ b/lldb/include/lldb/Core/StructuredDataImpl.h
@@ -25,7 +25,7 @@ namespace lldb_private {
 
 class StructuredDataImpl {
 public:
-  StructuredDataImpl() : m_plugin_wp(), m_data_sp() {}
+  StructuredDataImpl() {}
 
   StructuredDataImpl(const StructuredDataImpl &rhs) = default;
 

diff  --git a/lldb/include/lldb/Core/ThreadSafeValue.h b/lldb/include/lldb/Core/ThreadSafeValue.h
index 51820ec9cd9db..979f008b3170d 100644
--- a/lldb/include/lldb/Core/ThreadSafeValue.h
+++ b/lldb/include/lldb/Core/ThreadSafeValue.h
@@ -18,7 +18,7 @@ namespace lldb_private {
 template <class T> class ThreadSafeValue {
 public:
   ThreadSafeValue() = default;
-  ThreadSafeValue(const T &value) : m_value(value), m_mutex() {}
+  ThreadSafeValue(const T &value) : m_value(value) {}
 
   ~ThreadSafeValue() = default;
 

diff  --git a/lldb/include/lldb/Core/Value.h b/lldb/include/lldb/Core/Value.h
index 1ee4fe639e6e9..9f00a14251e20 100644
--- a/lldb/include/lldb/Core/Value.h
+++ b/lldb/include/lldb/Core/Value.h
@@ -156,7 +156,7 @@ class Value {
 
 class ValueList {
 public:
-  ValueList() : m_values() {}
+  ValueList() {}
 
   ValueList(const ValueList &rhs);
 

diff  --git a/lldb/include/lldb/Core/ValueObject.h b/lldb/include/lldb/Core/ValueObject.h
index 192149f054366..dac7aac062464 100644
--- a/lldb/include/lldb/Core/ValueObject.h
+++ b/lldb/include/lldb/Core/ValueObject.h
@@ -795,7 +795,7 @@ class ValueObject {
 
   class ChildrenManager {
   public:
-    ChildrenManager() : m_mutex(), m_children() {}
+    ChildrenManager() {}
 
     bool HasChildAtIndex(size_t idx) {
       std::lock_guard<std::recursive_mutex> guard(m_mutex);

diff  --git a/lldb/include/lldb/DataFormatters/FormatClasses.h b/lldb/include/lldb/DataFormatters/FormatClasses.h
index b8540de3d7408..2b47bcdf3a69e 100644
--- a/lldb/include/lldb/DataFormatters/FormatClasses.h
+++ b/lldb/include/lldb/DataFormatters/FormatClasses.h
@@ -105,23 +105,23 @@ class FormattersMatchData {
 
 class TypeNameSpecifierImpl {
 public:
-  TypeNameSpecifierImpl() : m_type() {}
+  TypeNameSpecifierImpl() {}
 
   TypeNameSpecifierImpl(llvm::StringRef name, bool is_regex)
-      : m_is_regex(is_regex), m_type() {
+      : m_is_regex(is_regex) {
     m_type.m_type_name = std::string(name);
   }
 
   // if constructing with a given type, is_regex cannot be true since we are
   // giving an exact type to match
-  TypeNameSpecifierImpl(lldb::TypeSP type) : m_is_regex(false), m_type() {
+  TypeNameSpecifierImpl(lldb::TypeSP type) : m_is_regex(false) {
     if (type) {
       m_type.m_type_name = std::string(type->GetName().GetStringRef());
       m_type.m_compiler_type = type->GetForwardCompilerType();
     }
   }
 
-  TypeNameSpecifierImpl(CompilerType type) : m_is_regex(false), m_type() {
+  TypeNameSpecifierImpl(CompilerType type) : m_is_regex(false) {
     if (type.IsValid()) {
       m_type.m_type_name.assign(type.GetTypeName().GetCString());
       m_type.m_compiler_type = type;

diff  --git a/lldb/include/lldb/DataFormatters/TypeSynthetic.h b/lldb/include/lldb/DataFormatters/TypeSynthetic.h
index 24322bd51a0c3..3f58297a529b3 100644
--- a/lldb/include/lldb/DataFormatters/TypeSynthetic.h
+++ b/lldb/include/lldb/DataFormatters/TypeSynthetic.h
@@ -279,11 +279,11 @@ class TypeFilterImpl : public SyntheticChildren {
 
 public:
   TypeFilterImpl(const SyntheticChildren::Flags &flags)
-      : SyntheticChildren(flags), m_expression_paths() {}
+      : SyntheticChildren(flags) {}
 
   TypeFilterImpl(const SyntheticChildren::Flags &flags,
                  const std::initializer_list<const char *> items)
-      : SyntheticChildren(flags), m_expression_paths() {
+      : SyntheticChildren(flags) {
     for (auto path : items)
       AddExpressionPath(path);
   }
@@ -391,7 +391,7 @@ class ScriptedSyntheticChildren : public SyntheticChildren {
 public:
   ScriptedSyntheticChildren(const SyntheticChildren::Flags &flags,
                             const char *pclass, const char *pcode = nullptr)
-      : SyntheticChildren(flags), m_python_class(), m_python_code() {
+      : SyntheticChildren(flags) {
     if (pclass)
       m_python_class = pclass;
     if (pcode)

diff  --git a/lldb/include/lldb/Expression/IRExecutionUnit.h b/lldb/include/lldb/Expression/IRExecutionUnit.h
index bb43851e17c9c..ef53ca512d75e 100644
--- a/lldb/include/lldb/Expression/IRExecutionUnit.h
+++ b/lldb/include/lldb/Expression/IRExecutionUnit.h
@@ -347,10 +347,9 @@ class IRExecutionUnit : public std::enable_shared_from_this<IRExecutionUnit>,
     AllocationRecord(uintptr_t host_address, uint32_t permissions,
                      lldb::SectionType sect_type, size_t size,
                      unsigned alignment, unsigned section_id, const char *name)
-        : m_name(), m_process_address(LLDB_INVALID_ADDRESS),
-          m_host_address(host_address), m_permissions(permissions),
-          m_sect_type(sect_type), m_size(size), m_alignment(alignment),
-          m_section_id(section_id) {
+        : m_process_address(LLDB_INVALID_ADDRESS), m_host_address(host_address),
+          m_permissions(permissions), m_sect_type(sect_type), m_size(size),
+          m_alignment(alignment), m_section_id(section_id) {
       if (name && name[0])
         m_name = name;
     }

diff  --git a/lldb/include/lldb/Host/Debug.h b/lldb/include/lldb/Host/Debug.h
index 7da59dd04a66b..e4e410474c02c 100644
--- a/lldb/include/lldb/Host/Debug.h
+++ b/lldb/include/lldb/Host/Debug.h
@@ -32,15 +32,13 @@ struct ResumeAction {
 // send a signal to the thread when the action is run or step.
 class ResumeActionList {
 public:
-  ResumeActionList() : m_actions(), m_signal_handled() {}
+  ResumeActionList() {}
 
-  ResumeActionList(lldb::StateType default_action, int signal)
-      : m_actions(), m_signal_handled() {
+  ResumeActionList(lldb::StateType default_action, int signal) {
     SetDefaultThreadActionIfNeeded(default_action, signal);
   }
 
-  ResumeActionList(const ResumeAction *actions, size_t num_actions)
-      : m_actions(), m_signal_handled() {
+  ResumeActionList(const ResumeAction *actions, size_t num_actions) {
     if (actions && num_actions) {
       m_actions.assign(actions, actions + num_actions);
       m_signal_handled.assign(num_actions, false);

diff  --git a/lldb/include/lldb/Host/FileSystem.h b/lldb/include/lldb/Host/FileSystem.h
index 54f7ac5ddb583..9f863e8a9d7e2 100644
--- a/lldb/include/lldb/Host/FileSystem.h
+++ b/lldb/include/lldb/Host/FileSystem.h
@@ -31,16 +31,13 @@ class FileSystem {
   static const char *DEV_NULL;
   static const char *PATH_CONVERSION_ERROR;
 
-  FileSystem()
-      : m_fs(llvm::vfs::getRealFileSystem()), m_collector(nullptr),
-        m_home_directory() {}
+  FileSystem() : m_fs(llvm::vfs::getRealFileSystem()), m_collector(nullptr) {}
   FileSystem(std::shared_ptr<llvm::FileCollectorBase> collector)
       : m_fs(llvm::vfs::getRealFileSystem()), m_collector(std::move(collector)),
-        m_home_directory(), m_mapped(false) {}
+        m_mapped(false) {}
   FileSystem(llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem> fs,
              bool mapped = false)
-      : m_fs(std::move(fs)), m_collector(nullptr), m_home_directory(),
-        m_mapped(mapped) {}
+      : m_fs(std::move(fs)), m_collector(nullptr), m_mapped(mapped) {}
 
   FileSystem(const FileSystem &fs) = delete;
   FileSystem &operator=(const FileSystem &fs) = delete;

diff  --git a/lldb/include/lldb/Interpreter/OptionValueArray.h b/lldb/include/lldb/Interpreter/OptionValueArray.h
index 011eefc342516..af43887635e9b 100644
--- a/lldb/include/lldb/Interpreter/OptionValueArray.h
+++ b/lldb/include/lldb/Interpreter/OptionValueArray.h
@@ -18,7 +18,7 @@ namespace lldb_private {
 class OptionValueArray : public Cloneable<OptionValueArray, OptionValue> {
 public:
   OptionValueArray(uint32_t type_mask = UINT32_MAX, bool raw_value_dump = false)
-      : m_type_mask(type_mask), m_values(), m_raw_value_dump(raw_value_dump) {}
+      : m_type_mask(type_mask), m_raw_value_dump(raw_value_dump) {}
 
   ~OptionValueArray() override = default;
 

diff  --git a/lldb/include/lldb/Symbol/CompactUnwindInfo.h b/lldb/include/lldb/Symbol/CompactUnwindInfo.h
index ceb501e1c05fb..402155cbe08da 100644
--- a/lldb/include/lldb/Symbol/CompactUnwindInfo.h
+++ b/lldb/include/lldb/Symbol/CompactUnwindInfo.h
@@ -86,7 +86,7 @@ class CompactUnwindInfo {
                                            // valid for (start of the function)
     uint32_t valid_range_offset_end =
         0; // the offset of the start of the next function
-    FunctionInfo() : lsda_address(), personality_ptr_address() {}
+    FunctionInfo() {}
   };
 
   struct UnwindHeader {

diff  --git a/lldb/include/lldb/Symbol/DWARFCallFrameInfo.h b/lldb/include/lldb/Symbol/DWARFCallFrameInfo.h
index f85bc7e844a0b..43baf4dd39a1d 100644
--- a/lldb/include/lldb/Symbol/DWARFCallFrameInfo.h
+++ b/lldb/include/lldb/Symbol/DWARFCallFrameInfo.h
@@ -107,7 +107,7 @@ class DWARFCallFrameInfo {
         : cie_offset(offset), version(-1), code_align(0), data_align(0),
           return_addr_reg_num(LLDB_INVALID_REGNUM), inst_offset(0),
           inst_length(0), ptr_encoding(0), lsda_addr_encoding(DW_EH_PE_omit),
-          personality_loc(LLDB_INVALID_ADDRESS), initial_row() {}
+          personality_loc(LLDB_INVALID_ADDRESS) {}
   };
 
   typedef std::shared_ptr<CIE> CIESP;

diff  --git a/lldb/include/lldb/Symbol/ObjectContainer.h b/lldb/include/lldb/Symbol/ObjectContainer.h
index 1e01e93da9d26..4f0c73693295e 100644
--- a/lldb/include/lldb/Symbol/ObjectContainer.h
+++ b/lldb/include/lldb/Symbol/ObjectContainer.h
@@ -39,7 +39,7 @@ class ObjectContainer : public PluginInterface, public ModuleChild {
                   lldb::DataBufferSP &data_sp, lldb::offset_t data_offset)
       : ModuleChild(module_sp),
         m_file(), // This file can be 
diff erent than the module's file spec
-        m_offset(file_offset), m_length(length), m_data() {
+        m_offset(file_offset), m_length(length) {
     if (file)
       m_file = *file;
     if (data_sp)

diff  --git a/lldb/include/lldb/Symbol/Type.h b/lldb/include/lldb/Symbol/Type.h
index 7754e02990964..24b94921df947 100644
--- a/lldb/include/lldb/Symbol/Type.h
+++ b/lldb/include/lldb/Symbol/Type.h
@@ -314,7 +314,7 @@ class TypeImpl {
 
 class TypeListImpl {
 public:
-  TypeListImpl() : m_content() {}
+  TypeListImpl() {}
 
   void Append(const lldb::TypeImplSP &type) { m_content.push_back(type); }
 
@@ -345,10 +345,7 @@ class TypeListImpl {
 
 class TypeMemberImpl {
 public:
-  TypeMemberImpl()
-      : m_type_impl_sp(), m_name()
-
-  {}
+  TypeMemberImpl() {}
 
   TypeMemberImpl(const lldb::TypeImplSP &type_impl_sp, uint64_t bit_offset,
                  ConstString name, uint32_t bitfield_bit_size = 0,
@@ -357,7 +354,7 @@ class TypeMemberImpl {
         m_bitfield_bit_size(bitfield_bit_size), m_is_bitfield(is_bitfield) {}
 
   TypeMemberImpl(const lldb::TypeImplSP &type_impl_sp, uint64_t bit_offset)
-      : m_type_impl_sp(type_impl_sp), m_bit_offset(bit_offset), m_name(),
+      : m_type_impl_sp(type_impl_sp), m_bit_offset(bit_offset),
         m_bitfield_bit_size(0), m_is_bitfield(false) {
     if (m_type_impl_sp)
       m_name = m_type_impl_sp->GetName();
@@ -440,7 +437,7 @@ class TypeAndOrName {
 
 class TypeMemberFunctionImpl {
 public:
-  TypeMemberFunctionImpl() : m_type(), m_decl(), m_name() {}
+  TypeMemberFunctionImpl() {}
 
   TypeMemberFunctionImpl(const CompilerType &type, const CompilerDecl &decl,
                          const std::string &name,
@@ -477,7 +474,7 @@ class TypeMemberFunctionImpl {
 
 class TypeEnumMemberImpl {
 public:
-  TypeEnumMemberImpl() : m_integer_type_sp(), m_name("<invalid>"), m_value() {}
+  TypeEnumMemberImpl() : m_name("<invalid>") {}
 
   TypeEnumMemberImpl(const lldb::TypeImplSP &integer_type_sp, ConstString name,
                      const llvm::APSInt &value);
@@ -505,7 +502,7 @@ class TypeEnumMemberImpl {
 
 class TypeEnumMemberListImpl {
 public:
-  TypeEnumMemberListImpl() : m_content() {}
+  TypeEnumMemberListImpl() {}
 
   void Append(const lldb::TypeEnumMemberImplSP &type) {
     m_content.push_back(type);

diff  --git a/lldb/include/lldb/Symbol/UnwindPlan.h b/lldb/include/lldb/Symbol/UnwindPlan.h
index 7b0fbe87315c5..ebb0ec421da72 100644
--- a/lldb/include/lldb/Symbol/UnwindPlan.h
+++ b/lldb/include/lldb/Symbol/UnwindPlan.h
@@ -395,12 +395,10 @@ class UnwindPlan {
   typedef std::shared_ptr<Row> RowSP;
 
   UnwindPlan(lldb::RegisterKind reg_kind)
-      : m_row_list(), m_plan_valid_address_range(), m_register_kind(reg_kind),
-        m_return_addr_register(LLDB_INVALID_REGNUM), m_source_name(),
+      : m_register_kind(reg_kind), m_return_addr_register(LLDB_INVALID_REGNUM),
         m_plan_is_sourced_from_compiler(eLazyBoolCalculate),
         m_plan_is_valid_at_all_instruction_locations(eLazyBoolCalculate),
-        m_plan_is_for_signal_trap(eLazyBoolCalculate),
-        m_lsda_address(), m_personality_func_addr() {}
+        m_plan_is_for_signal_trap(eLazyBoolCalculate) {}
 
   // Performs a deep copy of the plan, including all the rows (expensive).
   UnwindPlan(const UnwindPlan &rhs)

diff  --git a/lldb/include/lldb/Target/InstrumentationRuntime.h b/lldb/include/lldb/Target/InstrumentationRuntime.h
index eeec91f36af4f..a6121c24b9560 100644
--- a/lldb/include/lldb/Target/InstrumentationRuntime.h
+++ b/lldb/include/lldb/Target/InstrumentationRuntime.h
@@ -42,8 +42,7 @@ class InstrumentationRuntime
 
 protected:
   InstrumentationRuntime(const lldb::ProcessSP &process_sp)
-      : m_process_wp(), m_runtime_module(), m_breakpoint_id(0),
-        m_is_active(false) {
+      : m_breakpoint_id(0), m_is_active(false) {
     if (process_sp)
       m_process_wp = process_sp;
   }

diff  --git a/lldb/include/lldb/Target/Language.h b/lldb/include/lldb/Target/Language.h
index 0b0891c14029e..ce2d273a82770 100644
--- a/lldb/include/lldb/Target/Language.h
+++ b/lldb/include/lldb/Target/Language.h
@@ -57,8 +57,7 @@ class Language : public PluginInterface {
   class ImageListTypeScavenger : public TypeScavenger {
     class Result : public Language::TypeScavenger::Result {
     public:
-      Result(CompilerType type)
-          : Language::TypeScavenger::Result(), m_compiler_type(type) {}
+      Result(CompilerType type) : m_compiler_type(type) {}
 
       bool IsValid() override { return m_compiler_type.IsValid(); }
 
@@ -95,7 +94,7 @@ class Language : public PluginInterface {
   template <typename... ScavengerTypes>
   class EitherTypeScavenger : public TypeScavenger {
   public:
-    EitherTypeScavenger() : TypeScavenger(), m_scavengers() {
+    EitherTypeScavenger() : TypeScavenger() {
       for (std::shared_ptr<TypeScavenger> scavenger : { std::shared_ptr<TypeScavenger>(new ScavengerTypes())... }) {
         if (scavenger)
           m_scavengers.push_back(scavenger);
@@ -118,7 +117,7 @@ class Language : public PluginInterface {
   template <typename... ScavengerTypes>
   class UnionTypeScavenger : public TypeScavenger {
   public:
-    UnionTypeScavenger() : TypeScavenger(), m_scavengers() {
+    UnionTypeScavenger() : TypeScavenger() {
       for (std::shared_ptr<TypeScavenger> scavenger : { std::shared_ptr<TypeScavenger>(new ScavengerTypes())... }) {
         if (scavenger)
           m_scavengers.push_back(scavenger);

diff  --git a/lldb/include/lldb/Target/Platform.h b/lldb/include/lldb/Target/Platform.h
index 26127359a3224..d50badb1e6878 100644
--- a/lldb/include/lldb/Target/Platform.h
+++ b/lldb/include/lldb/Target/Platform.h
@@ -958,7 +958,7 @@ class Platform : public PluginInterface {
 
 class PlatformList {
 public:
-  PlatformList() : m_mutex(), m_platforms(), m_selected_platform_sp() {}
+  PlatformList() {}
 
   ~PlatformList() = default;
 

diff  --git a/lldb/include/lldb/Target/Process.h b/lldb/include/lldb/Target/Process.h
index e27cb8cbf2aa4..255a8b4baaca6 100644
--- a/lldb/include/lldb/Target/Process.h
+++ b/lldb/include/lldb/Target/Process.h
@@ -112,15 +112,12 @@ class ProcessProperties : public Properties {
 
 class ProcessAttachInfo : public ProcessInstanceInfo {
 public:
-  ProcessAttachInfo()
-      : ProcessInstanceInfo(), m_listener_sp(), m_hijack_listener_sp(),
-        m_plugin_name() {}
+  ProcessAttachInfo() {}
 
   ProcessAttachInfo(const ProcessLaunchInfo &launch_info)
-      : ProcessInstanceInfo(), m_listener_sp(), m_hijack_listener_sp(),
-        m_plugin_name(), m_resume_count(0), m_wait_for_launch(false),
-        m_ignore_existing(true), m_continue_once_attached(false),
-        m_detach_on_error(true), m_async(false) {
+      : m_resume_count(0), m_wait_for_launch(false), m_ignore_existing(true),
+        m_continue_once_attached(false), m_detach_on_error(true),
+        m_async(false) {
     ProcessInfo::operator=(launch_info);
     SetProcessPluginName(launch_info.GetProcessPluginName());
     SetResumeCount(launch_info.GetResumeCount());

diff  --git a/lldb/include/lldb/Target/RegisterCheckpoint.h b/lldb/include/lldb/Target/RegisterCheckpoint.h
index daf20db999b32..8681fb9628018 100644
--- a/lldb/include/lldb/Target/RegisterCheckpoint.h
+++ b/lldb/include/lldb/Target/RegisterCheckpoint.h
@@ -31,8 +31,7 @@ class RegisterCheckpoint : public UserID {
     eDataBackup
   };
 
-  RegisterCheckpoint(Reason reason)
-      : UserID(0), m_data_sp(), m_reason(reason) {}
+  RegisterCheckpoint(Reason reason) : UserID(0), m_reason(reason) {}
 
   ~RegisterCheckpoint() = default;
 

diff  --git a/lldb/include/lldb/Target/SectionLoadHistory.h b/lldb/include/lldb/Target/SectionLoadHistory.h
index dd024301d0cf7..0240cebda85f2 100644
--- a/lldb/include/lldb/Target/SectionLoadHistory.h
+++ b/lldb/include/lldb/Target/SectionLoadHistory.h
@@ -24,7 +24,7 @@ class SectionLoadHistory {
     eStopIDNow = UINT32_MAX
   };
   // Constructors and Destructors
-  SectionLoadHistory() : m_stop_id_to_section_load_list(), m_mutex() {}
+  SectionLoadHistory() {}
 
   ~SectionLoadHistory() {
     // Call clear since this takes a lock and clears the section load list in

diff  --git a/lldb/include/lldb/Target/SectionLoadList.h b/lldb/include/lldb/Target/SectionLoadList.h
index e8535e7ac51ac..548d44a181a70 100644
--- a/lldb/include/lldb/Target/SectionLoadList.h
+++ b/lldb/include/lldb/Target/SectionLoadList.h
@@ -22,7 +22,7 @@ namespace lldb_private {
 class SectionLoadList {
 public:
   // Constructors and Destructors
-  SectionLoadList() : m_addr_to_sect(), m_sect_to_addr(), m_mutex() {}
+  SectionLoadList() {}
 
   SectionLoadList(const SectionLoadList &rhs);
 

diff  --git a/lldb/include/lldb/Target/Unwind.h b/lldb/include/lldb/Target/Unwind.h
index 3faef139b00a0..105383ddae8a6 100644
--- a/lldb/include/lldb/Target/Unwind.h
+++ b/lldb/include/lldb/Target/Unwind.h
@@ -18,7 +18,7 @@ namespace lldb_private {
 class Unwind {
 protected:
   // Classes that inherit from Unwind can see and modify these
-  Unwind(Thread &thread) : m_thread(thread), m_unwind_mutex() {}
+  Unwind(Thread &thread) : m_thread(thread) {}
 
 public:
   virtual ~Unwind() = default;

diff  --git a/lldb/include/lldb/Target/UnwindLLDB.h b/lldb/include/lldb/Target/UnwindLLDB.h
index f6750171c54a6..939226c8c5b94 100644
--- a/lldb/include/lldb/Target/UnwindLLDB.h
+++ b/lldb/include/lldb/Target/UnwindLLDB.h
@@ -119,7 +119,7 @@ class UnwindLLDB : public lldb_private::Unwind {
     RegisterContextLLDBSP
         reg_ctx_lldb_sp; // These are all RegisterContextUnwind's
 
-    Cursor() : sctx(), reg_ctx_lldb_sp() {}
+    Cursor() {}
 
   private:
     Cursor(const Cursor &) = delete;

diff  --git a/lldb/include/lldb/Utility/Environment.h b/lldb/include/lldb/Utility/Environment.h
index 24cbee246f83f..c1549a3d60a64 100644
--- a/lldb/include/lldb/Utility/Environment.h
+++ b/lldb/include/lldb/Utility/Environment.h
@@ -56,7 +56,7 @@ class Environment : private llvm::StringMap<std::string> {
   using Base::try_emplace;
   using Base::operator[];
 
-  Environment() : Base() {}
+  Environment() {}
   Environment(const Environment &RHS) : Base(RHS) {}
   Environment(Environment &&RHS) : Base(std::move(RHS)) {}
   Environment(char *const *Env)

diff  --git a/lldb/include/lldb/Utility/Event.h b/lldb/include/lldb/Utility/Event.h
index 4e38f98a02f35..d3176216115a6 100644
--- a/lldb/include/lldb/Utility/Event.h
+++ b/lldb/include/lldb/Utility/Event.h
@@ -99,7 +99,7 @@ class EventDataBytes : public EventData {
 
 class EventDataReceipt : public EventData {
 public:
-  EventDataReceipt() : EventData(), m_predicate(false) {}
+  EventDataReceipt() : m_predicate(false) {}
 
   ~EventDataReceipt() override = default;
 

diff  --git a/lldb/include/lldb/Utility/GDBRemote.h b/lldb/include/lldb/Utility/GDBRemote.h
index f658818de8062..451181624c87e 100644
--- a/lldb/include/lldb/Utility/GDBRemote.h
+++ b/lldb/include/lldb/Utility/GDBRemote.h
@@ -55,7 +55,7 @@ struct GDBRemotePacket {
 
   enum Type { ePacketTypeInvalid = 0, ePacketTypeSend, ePacketTypeRecv };
 
-  GDBRemotePacket() : packet() {}
+  GDBRemotePacket() {}
 
   void Clear() {
     packet.data.clear();

diff  --git a/lldb/include/lldb/Utility/Predicate.h b/lldb/include/lldb/Utility/Predicate.h
index af16abc1a1d30..e5d80acb11bca 100644
--- a/lldb/include/lldb/Utility/Predicate.h
+++ b/lldb/include/lldb/Utility/Predicate.h
@@ -44,7 +44,7 @@ template <class T> class Predicate {
   ///
   /// Initializes the mutex, condition and value with their default
   /// constructors.
-  Predicate() : m_value(), m_mutex(), m_condition() {}
+  Predicate() : m_value() {}
 
   /// Construct with initial T value \a initial_value.
   ///
@@ -53,8 +53,7 @@ template <class T> class Predicate {
   ///
   /// \param[in] initial_value
   ///     The initial value for our T object.
-  Predicate(T initial_value)
-      : m_value(initial_value), m_mutex(), m_condition() {}
+  Predicate(T initial_value) : m_value(initial_value) {}
 
   /// Destructor.
   ///

diff  --git a/lldb/include/lldb/Utility/ProcessInfo.h b/lldb/include/lldb/Utility/ProcessInfo.h
index 3c59569263912..fc8b127689999 100644
--- a/lldb/include/lldb/Utility/ProcessInfo.h
+++ b/lldb/include/lldb/Utility/ProcessInfo.h
@@ -107,7 +107,7 @@ class ProcessInfo {
 // to that process.
 class ProcessInstanceInfo : public ProcessInfo {
 public:
-  ProcessInstanceInfo() : ProcessInfo() {}
+  ProcessInstanceInfo() {}
 
   ProcessInstanceInfo(const char *name, const ArchSpec &arch, lldb::pid_t pid)
       : ProcessInfo(name, arch, pid), m_euid(UINT32_MAX), m_egid(UINT32_MAX),
@@ -162,12 +162,11 @@ typedef std::vector<ProcessInstanceInfo> ProcessInstanceInfoList;
 
 class ProcessInstanceInfoMatch {
 public:
-  ProcessInstanceInfoMatch() : m_match_info() {}
+  ProcessInstanceInfoMatch() {}
 
   ProcessInstanceInfoMatch(const char *process_name,
                            NameMatch process_name_match_type)
-      : m_match_info(), m_name_match_type(process_name_match_type),
-        m_match_all_users(false) {
+      : m_name_match_type(process_name_match_type), m_match_all_users(false) {
     m_match_info.GetExecutableFile().SetFile(process_name,
                                              FileSpec::Style::native);
   }

diff  --git a/lldb/include/lldb/Utility/ReproducerProvider.h b/lldb/include/lldb/Utility/ReproducerProvider.h
index db7378069a879..56aadf92369e2 100644
--- a/lldb/include/lldb/Utility/ReproducerProvider.h
+++ b/lldb/include/lldb/Utility/ReproducerProvider.h
@@ -222,8 +222,7 @@ class HomeDirectoryProvider : public DirectoryProvider<HomeDirectoryProvider> {
 /// Provider for mapping UUIDs to symbol and executable files.
 class SymbolFileProvider : public Provider<SymbolFileProvider> {
 public:
-  SymbolFileProvider(const FileSpec &directory)
-      : Provider(directory), m_symbol_files() {}
+  SymbolFileProvider(const FileSpec &directory) : Provider(directory) {}
 
   void AddSymbolFile(const UUID *uuid, const FileSpec &module_path,
                      const FileSpec &symbol_path);

diff  --git a/lldb/include/lldb/Utility/SharedCluster.h b/lldb/include/lldb/Utility/SharedCluster.h
index 375c1c131a092..b3f41dbaa64b0 100644
--- a/lldb/include/lldb/Utility/SharedCluster.h
+++ b/lldb/include/lldb/Utility/SharedCluster.h
@@ -48,7 +48,7 @@ class ClusterManager : public std::enable_shared_from_this<ClusterManager<T>> {
   }
 
 private:
-  ClusterManager() : m_objects(), m_mutex() {}
+  ClusterManager() : m_objects() {}
 
   llvm::SmallVector<T *, 16> m_objects;
   std::mutex m_mutex;

diff  --git a/lldb/include/lldb/Utility/StreamTee.h b/lldb/include/lldb/Utility/StreamTee.h
index b5d3b9679e910..5695586171f35 100644
--- a/lldb/include/lldb/Utility/StreamTee.h
+++ b/lldb/include/lldb/Utility/StreamTee.h
@@ -19,18 +19,15 @@ namespace lldb_private {
 
 class StreamTee : public Stream {
 public:
-  StreamTee(bool colors = false)
-      : Stream(colors), m_streams_mutex(), m_streams() {}
+  StreamTee(bool colors = false) : Stream(colors) {}
 
-  StreamTee(lldb::StreamSP &stream_sp)
-      : Stream(), m_streams_mutex(), m_streams() {
+  StreamTee(lldb::StreamSP &stream_sp) {
     // No need to lock mutex during construction
     if (stream_sp)
       m_streams.push_back(stream_sp);
   }
 
-  StreamTee(lldb::StreamSP &stream_sp, lldb::StreamSP &stream_2_sp)
-      : Stream(), m_streams_mutex(), m_streams() {
+  StreamTee(lldb::StreamSP &stream_sp, lldb::StreamSP &stream_2_sp) {
     // No need to lock mutex during construction
     if (stream_sp)
       m_streams.push_back(stream_sp);
@@ -38,8 +35,7 @@ class StreamTee : public Stream {
       m_streams.push_back(stream_2_sp);
   }
 
-  StreamTee(const StreamTee &rhs)
-      : Stream(rhs), m_streams_mutex(), m_streams() {
+  StreamTee(const StreamTee &rhs) : Stream(rhs) {
     // Don't copy until we lock down "rhs"
     std::lock_guard<std::recursive_mutex> guard(rhs.m_streams_mutex);
     m_streams = rhs.m_streams;

diff  --git a/lldb/include/lldb/Utility/StringExtractorGDBRemote.h b/lldb/include/lldb/Utility/StringExtractorGDBRemote.h
index 1712c113d396b..459adae044526 100644
--- a/lldb/include/lldb/Utility/StringExtractorGDBRemote.h
+++ b/lldb/include/lldb/Utility/StringExtractorGDBRemote.h
@@ -23,7 +23,7 @@ class StringExtractorGDBRemote : public StringExtractor {
   typedef bool (*ResponseValidatorCallback)(
       void *baton, const StringExtractorGDBRemote &response);
 
-  StringExtractorGDBRemote() : StringExtractor() {}
+  StringExtractorGDBRemote() {}
 
   StringExtractorGDBRemote(llvm::StringRef str)
       : StringExtractor(str), m_validator(nullptr) {}

diff  --git a/lldb/include/lldb/Utility/StructuredData.h b/lldb/include/lldb/Utility/StructuredData.h
index c1d136db1c2ef..11eee92f8c3b8 100644
--- a/lldb/include/lldb/Utility/StructuredData.h
+++ b/lldb/include/lldb/Utility/StructuredData.h
@@ -351,10 +351,9 @@ class StructuredData {
 
   class Dictionary : public Object {
   public:
-    Dictionary() : Object(lldb::eStructuredDataTypeDictionary), m_dict() {}
+    Dictionary() : Object(lldb::eStructuredDataTypeDictionary) {}
 
-    Dictionary(ObjectSP obj_sp)
-        : Object(lldb::eStructuredDataTypeDictionary), m_dict() {
+    Dictionary(ObjectSP obj_sp) : Object(lldb::eStructuredDataTypeDictionary) {
       if (!obj_sp || obj_sp->GetType() != lldb::eStructuredDataTypeDictionary) {
         SetType(lldb::eStructuredDataTypeInvalid);
         return;


        


More information about the lldb-commits mailing list