[Lldb-commits] [lldb] a3436f7 - [API] Remove redundant member initialization (NFC)

Kazu Hirata via lldb-commits lldb-commits at lists.llvm.org
Sun Jan 2 22:44:27 PST 2022


Author: Kazu Hirata
Date: 2022-01-02T22:44:16-08:00
New Revision: a3436f7340cb5bdb9dddf2b6b3e72ca6cf9f7e22

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

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

Identified with readability-redundant-member-init.

Added: 
    

Modified: 
    lldb/source/API/SBBreakpoint.cpp
    lldb/source/API/SBBroadcaster.cpp
    lldb/source/API/SBCommandInterpreterRunOptions.cpp
    lldb/source/API/SBCommandReturnObject.cpp
    lldb/source/API/SBDeclaration.cpp
    lldb/source/API/SBError.cpp
    lldb/source/API/SBEvent.cpp
    lldb/source/API/SBExecutionContext.cpp
    lldb/source/API/SBExpressionOptions.cpp
    lldb/source/API/SBFileSpec.cpp
    lldb/source/API/SBFileSpecList.cpp
    lldb/source/API/SBFrame.cpp
    lldb/source/API/SBInstruction.cpp
    lldb/source/API/SBInstructionList.cpp
    lldb/source/API/SBLaunchInfo.cpp
    lldb/source/API/SBLineEntry.cpp
    lldb/source/API/SBListener.cpp
    lldb/source/API/SBMemoryRegionInfo.cpp
    lldb/source/API/SBModule.cpp
    lldb/source/API/SBModuleSpec.cpp
    lldb/source/API/SBPlatform.cpp
    lldb/source/API/SBProcess.cpp
    lldb/source/API/SBProcessInfo.cpp
    lldb/source/API/SBQueue.cpp
    lldb/source/API/SBQueueItem.cpp
    lldb/source/API/SBReproducerPrivate.h
    lldb/source/API/SBSection.cpp
    lldb/source/API/SBSourceManager.cpp
    lldb/source/API/SBStringList.cpp
    lldb/source/API/SBSymbolContext.cpp
    lldb/source/API/SBSymbolContextList.cpp
    lldb/source/API/SBTarget.cpp
    lldb/source/API/SBThread.cpp
    lldb/source/API/SBThreadCollection.cpp
    lldb/source/API/SBType.cpp
    lldb/source/API/SBTypeCategory.cpp
    lldb/source/API/SBTypeEnumMember.cpp
    lldb/source/API/SBTypeFilter.cpp
    lldb/source/API/SBTypeFormat.cpp
    lldb/source/API/SBTypeNameSpecifier.cpp
    lldb/source/API/SBTypeSummary.cpp
    lldb/source/API/SBTypeSynthetic.cpp
    lldb/source/API/SBValue.cpp
    lldb/source/API/SBValueList.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/API/SBBreakpoint.cpp b/lldb/source/API/SBBreakpoint.cpp
index 0f0a93519993d..031ad7b627886 100644
--- a/lldb/source/API/SBBreakpoint.cpp
+++ b/lldb/source/API/SBBreakpoint.cpp
@@ -821,7 +821,7 @@ BreakpointSP SBBreakpoint::GetSP() const { return m_opaque_wp.lock(); }
 // This is simple collection of breakpoint id's and their target.
 class SBBreakpointListImpl {
 public:
-  SBBreakpointListImpl(lldb::TargetSP target_sp) : m_target_wp() {
+  SBBreakpointListImpl(lldb::TargetSP target_sp) {
     if (target_sp && target_sp->IsValid())
       m_target_wp = target_sp;
   }

diff  --git a/lldb/source/API/SBBroadcaster.cpp b/lldb/source/API/SBBroadcaster.cpp
index 2e6d837f102b1..46558480aa1ad 100644
--- a/lldb/source/API/SBBroadcaster.cpp
+++ b/lldb/source/API/SBBroadcaster.cpp
@@ -16,7 +16,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBBroadcaster::SBBroadcaster() : m_opaque_sp() {
+SBBroadcaster::SBBroadcaster() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBBroadcaster);
 }
 

diff  --git a/lldb/source/API/SBCommandInterpreterRunOptions.cpp b/lldb/source/API/SBCommandInterpreterRunOptions.cpp
index 317ec6d371272..4d72926137cf9 100644
--- a/lldb/source/API/SBCommandInterpreterRunOptions.cpp
+++ b/lldb/source/API/SBCommandInterpreterRunOptions.cpp
@@ -25,8 +25,7 @@ SBCommandInterpreterRunOptions::SBCommandInterpreterRunOptions() {
 }
 
 SBCommandInterpreterRunOptions::SBCommandInterpreterRunOptions(
-    const SBCommandInterpreterRunOptions &rhs)
-    : m_opaque_up() {
+    const SBCommandInterpreterRunOptions &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBCommandInterpreterRunOptions,
                           (const lldb::SBCommandInterpreterRunOptions &), rhs);
 
@@ -215,8 +214,7 @@ SBCommandInterpreterRunResult::SBCommandInterpreterRunResult(
 }
 
 SBCommandInterpreterRunResult::SBCommandInterpreterRunResult(
-    const CommandInterpreterRunResult &rhs)
-    : m_opaque_up() {
+    const CommandInterpreterRunResult &rhs) {
   m_opaque_up = std::make_unique<CommandInterpreterRunResult>(rhs);
 }
 

diff  --git a/lldb/source/API/SBCommandReturnObject.cpp b/lldb/source/API/SBCommandReturnObject.cpp
index 00150d198fca5..d66580f33ad64 100644
--- a/lldb/source/API/SBCommandReturnObject.cpp
+++ b/lldb/source/API/SBCommandReturnObject.cpp
@@ -55,8 +55,7 @@ SBCommandReturnObject::SBCommandReturnObject(CommandReturnObject &ref)
                           (lldb_private::CommandReturnObject &), ref);
 }
 
-SBCommandReturnObject::SBCommandReturnObject(const SBCommandReturnObject &rhs)
-    : m_opaque_up() {
+SBCommandReturnObject::SBCommandReturnObject(const SBCommandReturnObject &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBCommandReturnObject,
                           (const lldb::SBCommandReturnObject &), rhs);
 

diff  --git a/lldb/source/API/SBDeclaration.cpp b/lldb/source/API/SBDeclaration.cpp
index 1496096e46d1e..f44e55af331ab 100644
--- a/lldb/source/API/SBDeclaration.cpp
+++ b/lldb/source/API/SBDeclaration.cpp
@@ -19,18 +19,17 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBDeclaration::SBDeclaration() : m_opaque_up() {
+SBDeclaration::SBDeclaration() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBDeclaration);
 }
 
-SBDeclaration::SBDeclaration(const SBDeclaration &rhs) : m_opaque_up() {
+SBDeclaration::SBDeclaration(const SBDeclaration &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBDeclaration, (const lldb::SBDeclaration &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);
 }
 
-SBDeclaration::SBDeclaration(const lldb_private::Declaration *lldb_object_ptr)
-    : m_opaque_up() {
+SBDeclaration::SBDeclaration(const lldb_private::Declaration *lldb_object_ptr) {
   if (lldb_object_ptr)
     m_opaque_up = std::make_unique<Declaration>(*lldb_object_ptr);
 }

diff  --git a/lldb/source/API/SBError.cpp b/lldb/source/API/SBError.cpp
index 89b5f26fd80cb..d80183c4200af 100644
--- a/lldb/source/API/SBError.cpp
+++ b/lldb/source/API/SBError.cpp
@@ -17,9 +17,9 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBError::SBError() : m_opaque_up() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBError); }
+SBError::SBError() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBError); }
 
-SBError::SBError(const SBError &rhs) : m_opaque_up() {
+SBError::SBError(const SBError &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBError, (const lldb::SBError &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBEvent.cpp b/lldb/source/API/SBEvent.cpp
index a0b606e3812ef..f34dd17d6c9e8 100644
--- a/lldb/source/API/SBEvent.cpp
+++ b/lldb/source/API/SBEvent.cpp
@@ -22,7 +22,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBEvent::SBEvent() : m_event_sp() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBEvent); }
+SBEvent::SBEvent() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBEvent); }
 
 SBEvent::SBEvent(uint32_t event_type, const char *cstr, uint32_t cstr_len)
     : m_event_sp(new Event(event_type, new EventDataBytes(cstr, cstr_len))),
@@ -36,7 +36,7 @@ SBEvent::SBEvent(EventSP &event_sp)
   LLDB_RECORD_CONSTRUCTOR(SBEvent, (lldb::EventSP &), event_sp);
 }
 
-SBEvent::SBEvent(Event *event_ptr) : m_event_sp(), m_opaque_ptr(event_ptr) {
+SBEvent::SBEvent(Event *event_ptr) : m_opaque_ptr(event_ptr) {
   LLDB_RECORD_CONSTRUCTOR(SBEvent, (lldb_private::Event *), event_ptr);
 }
 

diff  --git a/lldb/source/API/SBExecutionContext.cpp b/lldb/source/API/SBExecutionContext.cpp
index caf02b4164ea0..8ebb152b7063a 100644
--- a/lldb/source/API/SBExecutionContext.cpp
+++ b/lldb/source/API/SBExecutionContext.cpp
@@ -19,7 +19,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBExecutionContext::SBExecutionContext() : m_exe_ctx_sp() {
+SBExecutionContext::SBExecutionContext() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBExecutionContext);
 }
 

diff  --git a/lldb/source/API/SBExpressionOptions.cpp b/lldb/source/API/SBExpressionOptions.cpp
index 217e8ad5c21b3..2c966b2ca4869 100644
--- a/lldb/source/API/SBExpressionOptions.cpp
+++ b/lldb/source/API/SBExpressionOptions.cpp
@@ -20,8 +20,7 @@ SBExpressionOptions::SBExpressionOptions()
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBExpressionOptions);
 }
 
-SBExpressionOptions::SBExpressionOptions(const SBExpressionOptions &rhs)
-    : m_opaque_up() {
+SBExpressionOptions::SBExpressionOptions(const SBExpressionOptions &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBExpressionOptions,
                           (const lldb::SBExpressionOptions &), rhs);
 

diff  --git a/lldb/source/API/SBFileSpec.cpp b/lldb/source/API/SBFileSpec.cpp
index 0a6b63bb460c7..2b9e2d002eddd 100644
--- a/lldb/source/API/SBFileSpec.cpp
+++ b/lldb/source/API/SBFileSpec.cpp
@@ -27,7 +27,7 @@ SBFileSpec::SBFileSpec() : m_opaque_up(new lldb_private::FileSpec()) {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBFileSpec);
 }
 
-SBFileSpec::SBFileSpec(const SBFileSpec &rhs) : m_opaque_up() {
+SBFileSpec::SBFileSpec(const SBFileSpec &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBFileSpec, (const lldb::SBFileSpec &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBFileSpecList.cpp b/lldb/source/API/SBFileSpecList.cpp
index 768ff0affd15a..8f20aed7e8510 100644
--- a/lldb/source/API/SBFileSpecList.cpp
+++ b/lldb/source/API/SBFileSpecList.cpp
@@ -25,10 +25,9 @@ SBFileSpecList::SBFileSpecList() : m_opaque_up(new FileSpecList()) {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBFileSpecList);
 }
 
-SBFileSpecList::SBFileSpecList(const SBFileSpecList &rhs) : m_opaque_up() {
+SBFileSpecList::SBFileSpecList(const SBFileSpecList &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBFileSpecList, (const lldb::SBFileSpecList &), rhs);
 
-
   m_opaque_up = clone(rhs.m_opaque_up);
 }
 

diff  --git a/lldb/source/API/SBFrame.cpp b/lldb/source/API/SBFrame.cpp
index c6bc3288c4b2f..ba9b268be83f4 100644
--- a/lldb/source/API/SBFrame.cpp
+++ b/lldb/source/API/SBFrame.cpp
@@ -64,7 +64,7 @@ SBFrame::SBFrame(const StackFrameSP &lldb_object_sp)
                           lldb_object_sp);
 }
 
-SBFrame::SBFrame(const SBFrame &rhs) : m_opaque_sp() {
+SBFrame::SBFrame(const SBFrame &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBFrame, (const lldb::SBFrame &), rhs);
 
   m_opaque_sp = clone(rhs.m_opaque_sp);

diff  --git a/lldb/source/API/SBInstruction.cpp b/lldb/source/API/SBInstruction.cpp
index 579ddf84cf451..b845d3c50c440 100644
--- a/lldb/source/API/SBInstruction.cpp
+++ b/lldb/source/API/SBInstruction.cpp
@@ -66,7 +66,7 @@ class InstructionImpl {
 using namespace lldb;
 using namespace lldb_private;
 
-SBInstruction::SBInstruction() : m_opaque_sp() {
+SBInstruction::SBInstruction() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBInstruction);
 }
 

diff  --git a/lldb/source/API/SBInstructionList.cpp b/lldb/source/API/SBInstructionList.cpp
index a0c6fbe7e3387..859f5212c355c 100644
--- a/lldb/source/API/SBInstructionList.cpp
+++ b/lldb/source/API/SBInstructionList.cpp
@@ -21,7 +21,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBInstructionList::SBInstructionList() : m_opaque_sp() {
+SBInstructionList::SBInstructionList() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBInstructionList);
 }
 

diff  --git a/lldb/source/API/SBLaunchInfo.cpp b/lldb/source/API/SBLaunchInfo.cpp
index 0735e62a16cfd..95d9a1d935cc8 100644
--- a/lldb/source/API/SBLaunchInfo.cpp
+++ b/lldb/source/API/SBLaunchInfo.cpp
@@ -23,8 +23,7 @@ using namespace lldb_private;
 
 class lldb_private::SBLaunchInfoImpl : public ProcessLaunchInfo {
 public:
-  SBLaunchInfoImpl()
-      : ProcessLaunchInfo(), m_envp(GetEnvironment().getEnvp()) {}
+  SBLaunchInfoImpl() : m_envp(GetEnvironment().getEnvp()) {}
 
   const char *const *GetEnvp() const { return m_envp; }
   void RegenerateEnvp() { m_envp = GetEnvironment().getEnvp(); }

diff  --git a/lldb/source/API/SBLineEntry.cpp b/lldb/source/API/SBLineEntry.cpp
index 29ffda9b04719..0221b19f5bdfa 100644
--- a/lldb/source/API/SBLineEntry.cpp
+++ b/lldb/source/API/SBLineEntry.cpp
@@ -19,18 +19,15 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBLineEntry::SBLineEntry() : m_opaque_up() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBLineEntry);
-}
+SBLineEntry::SBLineEntry() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBLineEntry); }
 
-SBLineEntry::SBLineEntry(const SBLineEntry &rhs) : m_opaque_up() {
+SBLineEntry::SBLineEntry(const SBLineEntry &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBLineEntry, (const lldb::SBLineEntry &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);
 }
 
-SBLineEntry::SBLineEntry(const lldb_private::LineEntry *lldb_object_ptr)
-    : m_opaque_up() {
+SBLineEntry::SBLineEntry(const lldb_private::LineEntry *lldb_object_ptr) {
   if (lldb_object_ptr)
     m_opaque_up = std::make_unique<LineEntry>(*lldb_object_ptr);
 }

diff  --git a/lldb/source/API/SBListener.cpp b/lldb/source/API/SBListener.cpp
index 6e5e15de7b3d4..da5c010befcf2 100644
--- a/lldb/source/API/SBListener.cpp
+++ b/lldb/source/API/SBListener.cpp
@@ -20,9 +20,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBListener::SBListener() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBListener);
-}
+SBListener::SBListener() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBListener); }
 
 SBListener::SBListener(const char *name)
     : m_opaque_sp(Listener::MakeListener(name)), m_unused_ptr(nullptr) {

diff  --git a/lldb/source/API/SBMemoryRegionInfo.cpp b/lldb/source/API/SBMemoryRegionInfo.cpp
index 9cf7874b54a3b..9a01faf3daa37 100644
--- a/lldb/source/API/SBMemoryRegionInfo.cpp
+++ b/lldb/source/API/SBMemoryRegionInfo.cpp
@@ -46,8 +46,7 @@ SBMemoryRegionInfo::SBMemoryRegionInfo(const MemoryRegionInfo *lldb_object_ptr)
     ref() = *lldb_object_ptr;
 }
 
-SBMemoryRegionInfo::SBMemoryRegionInfo(const SBMemoryRegionInfo &rhs)
-    : m_opaque_up() {
+SBMemoryRegionInfo::SBMemoryRegionInfo(const SBMemoryRegionInfo &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBMemoryRegionInfo,
                           (const lldb::SBMemoryRegionInfo &), rhs);
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBModule.cpp b/lldb/source/API/SBModule.cpp
index 710ee8551bd62..ed17e8fdc9c35 100644
--- a/lldb/source/API/SBModule.cpp
+++ b/lldb/source/API/SBModule.cpp
@@ -29,13 +29,11 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBModule::SBModule() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBModule);
-}
+SBModule::SBModule() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBModule); }
 
 SBModule::SBModule(const lldb::ModuleSP &module_sp) : m_opaque_sp(module_sp) {}
 
-SBModule::SBModule(const SBModuleSpec &module_spec) : m_opaque_sp() {
+SBModule::SBModule(const SBModuleSpec &module_spec) {
   LLDB_RECORD_CONSTRUCTOR(SBModule, (const lldb::SBModuleSpec &), module_spec);
 
   ModuleSP module_sp;
@@ -49,8 +47,7 @@ SBModule::SBModule(const SBModule &rhs) : m_opaque_sp(rhs.m_opaque_sp) {
   LLDB_RECORD_CONSTRUCTOR(SBModule, (const lldb::SBModule &), rhs);
 }
 
-SBModule::SBModule(lldb::SBProcess &process, lldb::addr_t header_addr)
-    : m_opaque_sp() {
+SBModule::SBModule(lldb::SBProcess &process, lldb::addr_t header_addr) {
   LLDB_RECORD_CONSTRUCTOR(SBModule, (lldb::SBProcess &, lldb::addr_t), process,
                           header_addr);
 

diff  --git a/lldb/source/API/SBModuleSpec.cpp b/lldb/source/API/SBModuleSpec.cpp
index 5d88272a399b6..d8154bea8a1ab 100644
--- a/lldb/source/API/SBModuleSpec.cpp
+++ b/lldb/source/API/SBModuleSpec.cpp
@@ -23,7 +23,7 @@ SBModuleSpec::SBModuleSpec() : m_opaque_up(new lldb_private::ModuleSpec()) {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBModuleSpec);
 }
 
-SBModuleSpec::SBModuleSpec(const SBModuleSpec &rhs) : m_opaque_up() {
+SBModuleSpec::SBModuleSpec(const SBModuleSpec &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBModuleSpec, (const lldb::SBModuleSpec &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBPlatform.cpp b/lldb/source/API/SBPlatform.cpp
index d7a86f0ad1ddc..a6769428a2115 100644
--- a/lldb/source/API/SBPlatform.cpp
+++ b/lldb/source/API/SBPlatform.cpp
@@ -30,10 +30,7 @@ using namespace lldb_private;
 
 // PlatformConnectOptions
 struct PlatformConnectOptions {
-  PlatformConnectOptions(const char *url = nullptr)
-      : m_url(), m_rsync_options(), m_rsync_remote_path_prefix(),
-
-        m_local_cache_directory() {
+  PlatformConnectOptions(const char *url = nullptr) {
     if (url && url[0])
       m_url = url;
   }
@@ -52,7 +49,7 @@ struct PlatformConnectOptions {
 struct PlatformShellCommand {
   PlatformShellCommand(llvm::StringRef shell_interpreter,
                        llvm::StringRef shell_command)
-      : m_command(), m_working_dir(), m_status(0), m_signo(0) {
+      : m_status(0), m_signo(0) {
     if (!shell_interpreter.empty())
       m_shell = shell_interpreter.str();
 
@@ -60,8 +57,7 @@ struct PlatformShellCommand {
       m_command = shell_command.str();
   }
 
-  PlatformShellCommand(llvm::StringRef shell_command = llvm::StringRef())
-      : m_shell(), m_command(), m_working_dir() {
+  PlatformShellCommand(llvm::StringRef shell_command = llvm::StringRef()) {
     if (!shell_command.empty())
       m_command = shell_command.str();
   }
@@ -313,11 +309,9 @@ const char *SBPlatformShellCommand::GetOutput() {
 }
 
 // SBPlatform
-SBPlatform::SBPlatform() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBPlatform);
-}
+SBPlatform::SBPlatform() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBPlatform); }
 
-SBPlatform::SBPlatform(const char *platform_name) : m_opaque_sp() {
+SBPlatform::SBPlatform(const char *platform_name) {
   LLDB_RECORD_CONSTRUCTOR(SBPlatform, (const char *), platform_name);
 
   Status error;

diff  --git a/lldb/source/API/SBProcess.cpp b/lldb/source/API/SBProcess.cpp
index 797e19462800c..3da96d3466bf4 100644
--- a/lldb/source/API/SBProcess.cpp
+++ b/lldb/source/API/SBProcess.cpp
@@ -49,9 +49,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBProcess::SBProcess() : m_opaque_wp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBProcess);
-}
+SBProcess::SBProcess() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBProcess); }
 
 // SBProcess constructor
 

diff  --git a/lldb/source/API/SBProcessInfo.cpp b/lldb/source/API/SBProcessInfo.cpp
index cba3bdc179f30..10a149f90c34b 100644
--- a/lldb/source/API/SBProcessInfo.cpp
+++ b/lldb/source/API/SBProcessInfo.cpp
@@ -15,11 +15,11 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBProcessInfo::SBProcessInfo() : m_opaque_up() {
+SBProcessInfo::SBProcessInfo() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBProcessInfo);
 }
 
-SBProcessInfo::SBProcessInfo(const SBProcessInfo &rhs) : m_opaque_up() {
+SBProcessInfo::SBProcessInfo(const SBProcessInfo &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBProcessInfo, (const lldb::SBProcessInfo &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBQueue.cpp b/lldb/source/API/SBQueue.cpp
index 746df9e79d61b..7981d956061e0 100644
--- a/lldb/source/API/SBQueue.cpp
+++ b/lldb/source/API/SBQueue.cpp
@@ -27,11 +27,10 @@ namespace lldb_private {
 
 class QueueImpl {
 public:
-  QueueImpl() : m_queue_wp(), m_threads(), m_pending_items() {}
+  QueueImpl() {}
 
   QueueImpl(const lldb::QueueSP &queue_sp)
-      : m_queue_wp(), m_threads(), m_thread_list_fetched(false),
-        m_pending_items(), m_pending_items_fetched(false) {
+      : m_thread_list_fetched(false), m_pending_items_fetched(false) {
     m_queue_wp = queue_sp;
   }
 

diff  --git a/lldb/source/API/SBQueueItem.cpp b/lldb/source/API/SBQueueItem.cpp
index 6cd9e4514caf5..94981e34e070c 100644
--- a/lldb/source/API/SBQueueItem.cpp
+++ b/lldb/source/API/SBQueueItem.cpp
@@ -21,9 +21,7 @@ using namespace lldb;
 using namespace lldb_private;
 
 // Constructors
-SBQueueItem::SBQueueItem() : m_queue_item_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBQueueItem);
-}
+SBQueueItem::SBQueueItem() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBQueueItem); }
 
 SBQueueItem::SBQueueItem(const QueueItemSP &queue_item_sp)
     : m_queue_item_sp(queue_item_sp) {

diff  --git a/lldb/source/API/SBReproducerPrivate.h b/lldb/source/API/SBReproducerPrivate.h
index 02ac31c2ad89d..7d51beec4e94c 100644
--- a/lldb/source/API/SBReproducerPrivate.h
+++ b/lldb/source/API/SBReproducerPrivate.h
@@ -59,7 +59,7 @@ class SBProvider : public Provider<SBProvider> {
 class ReplayData {
 public:
   ReplayData(std::unique_ptr<llvm::MemoryBuffer> memory_buffer)
-      : m_memory_buffer(std::move(memory_buffer)), m_registry(),
+      : m_memory_buffer(std::move(memory_buffer)),
         m_deserializer(m_memory_buffer->getBuffer()) {}
   Deserializer &GetDeserializer() { return m_deserializer; }
   Registry &GetRegistry() { return m_registry; }

diff  --git a/lldb/source/API/SBSection.cpp b/lldb/source/API/SBSection.cpp
index bb56fa18d9cab..71e80e04a0e23 100644
--- a/lldb/source/API/SBSection.cpp
+++ b/lldb/source/API/SBSection.cpp
@@ -20,18 +20,15 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBSection::SBSection() : m_opaque_wp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBSection);
-}
+SBSection::SBSection() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBSection); }
 
 SBSection::SBSection(const SBSection &rhs) : m_opaque_wp(rhs.m_opaque_wp) {
   LLDB_RECORD_CONSTRUCTOR(SBSection, (const lldb::SBSection &), rhs);
 }
 
-SBSection::SBSection(const lldb::SectionSP &section_sp)
-    : m_opaque_wp() // Don't init with section_sp otherwise this will throw if
-                    // section_sp doesn't contain a valid Section *
-{
+SBSection::SBSection(const lldb::SectionSP &section_sp) {
+  // Don't init with section_sp otherwise this will throw if
+  // section_sp doesn't contain a valid Section *
   if (section_sp)
     m_opaque_wp = section_sp;
 }

diff  --git a/lldb/source/API/SBSourceManager.cpp b/lldb/source/API/SBSourceManager.cpp
index 43c3443672f73..5241d054e274c 100644
--- a/lldb/source/API/SBSourceManager.cpp
+++ b/lldb/source/API/SBSourceManager.cpp
@@ -24,10 +24,9 @@ namespace lldb_private {
 class SourceManagerImpl {
 public:
   SourceManagerImpl(const lldb::DebuggerSP &debugger_sp)
-      : m_debugger_wp(debugger_sp), m_target_wp() {}
+      : m_debugger_wp(debugger_sp) {}
 
-  SourceManagerImpl(const lldb::TargetSP &target_sp)
-      : m_debugger_wp(), m_target_wp(target_sp) {}
+  SourceManagerImpl(const lldb::TargetSP &target_sp) : m_target_wp(target_sp) {}
 
   SourceManagerImpl(const SourceManagerImpl &rhs) {
     if (&rhs == this)

diff  --git a/lldb/source/API/SBStringList.cpp b/lldb/source/API/SBStringList.cpp
index d9b03692ec0e4..a199957e1501d 100644
--- a/lldb/source/API/SBStringList.cpp
+++ b/lldb/source/API/SBStringList.cpp
@@ -14,17 +14,14 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBStringList::SBStringList() : m_opaque_up() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBStringList);
-}
+SBStringList::SBStringList() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBStringList); }
 
-SBStringList::SBStringList(const lldb_private::StringList *lldb_strings_ptr)
-    : m_opaque_up() {
+SBStringList::SBStringList(const lldb_private::StringList *lldb_strings_ptr) {
   if (lldb_strings_ptr)
     m_opaque_up = std::make_unique<StringList>(*lldb_strings_ptr);
 }
 
-SBStringList::SBStringList(const SBStringList &rhs) : m_opaque_up() {
+SBStringList::SBStringList(const SBStringList &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBStringList, (const lldb::SBStringList &), rhs);
 
   m_opaque_up = clone(rhs.m_opaque_up);

diff  --git a/lldb/source/API/SBSymbolContext.cpp b/lldb/source/API/SBSymbolContext.cpp
index 89fe051658ffa..9b67d5fd3396b 100644
--- a/lldb/source/API/SBSymbolContext.cpp
+++ b/lldb/source/API/SBSymbolContext.cpp
@@ -18,7 +18,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBSymbolContext::SBSymbolContext() : m_opaque_up() {
+SBSymbolContext::SBSymbolContext() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBSymbolContext);
 }
 
@@ -28,7 +28,7 @@ SBSymbolContext::SBSymbolContext(const SymbolContext &sc)
                           (const lldb_private::SymbolContext &), sc);
 }
 
-SBSymbolContext::SBSymbolContext(const SBSymbolContext &rhs) : m_opaque_up() {
+SBSymbolContext::SBSymbolContext(const SBSymbolContext &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBSymbolContext, (const lldb::SBSymbolContext &),
                           rhs);
 

diff  --git a/lldb/source/API/SBSymbolContextList.cpp b/lldb/source/API/SBSymbolContextList.cpp
index 70a8bbe6694c9..3f36ba4569c35 100644
--- a/lldb/source/API/SBSymbolContextList.cpp
+++ b/lldb/source/API/SBSymbolContextList.cpp
@@ -20,8 +20,7 @@ SBSymbolContextList::SBSymbolContextList()
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBSymbolContextList);
 }
 
-SBSymbolContextList::SBSymbolContextList(const SBSymbolContextList &rhs)
-    : m_opaque_up() {
+SBSymbolContextList::SBSymbolContextList(const SBSymbolContextList &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBSymbolContextList,
                           (const lldb::SBSymbolContextList &), rhs);
 

diff  --git a/lldb/source/API/SBTarget.cpp b/lldb/source/API/SBTarget.cpp
index dc79c77fee9ed..7049c90b9fc15 100644
--- a/lldb/source/API/SBTarget.cpp
+++ b/lldb/source/API/SBTarget.cpp
@@ -93,9 +93,7 @@ static Status AttachToProcess(ProcessAttachInfo &attach_info, Target &target) {
 }
 
 // SBTarget constructor
-SBTarget::SBTarget() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTarget);
-}
+SBTarget::SBTarget() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTarget); }
 
 SBTarget::SBTarget(const SBTarget &rhs) : m_opaque_sp(rhs.m_opaque_sp) {
   LLDB_RECORD_CONSTRUCTOR(SBTarget, (const lldb::SBTarget &), rhs);

diff  --git a/lldb/source/API/SBThread.cpp b/lldb/source/API/SBThread.cpp
index 8d5b6f2a54234..f12826b31008d 100644
--- a/lldb/source/API/SBThread.cpp
+++ b/lldb/source/API/SBThread.cpp
@@ -67,7 +67,7 @@ SBThread::SBThread(const ThreadSP &lldb_object_sp)
   LLDB_RECORD_CONSTRUCTOR(SBThread, (const lldb::ThreadSP &), lldb_object_sp);
 }
 
-SBThread::SBThread(const SBThread &rhs) : m_opaque_sp() {
+SBThread::SBThread(const SBThread &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBThread, (const lldb::SBThread &), rhs);
 
   m_opaque_sp = clone(rhs.m_opaque_sp);

diff  --git a/lldb/source/API/SBThreadCollection.cpp b/lldb/source/API/SBThreadCollection.cpp
index bfca864d6bcdb..cbcf20d9dd669 100644
--- a/lldb/source/API/SBThreadCollection.cpp
+++ b/lldb/source/API/SBThreadCollection.cpp
@@ -14,7 +14,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBThreadCollection::SBThreadCollection() : m_opaque_sp() {
+SBThreadCollection::SBThreadCollection() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBThreadCollection);
 }
 

diff  --git a/lldb/source/API/SBType.cpp b/lldb/source/API/SBType.cpp
index 550c4b065914a..b95edc62d56ba 100644
--- a/lldb/source/API/SBType.cpp
+++ b/lldb/source/API/SBType.cpp
@@ -26,7 +26,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBType::SBType() : m_opaque_sp() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBType); }
+SBType::SBType() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBType); }
 
 SBType::SBType(const CompilerType &type)
     : m_opaque_sp(new TypeImpl(
@@ -38,7 +38,7 @@ SBType::SBType(const lldb::TypeSP &type_sp)
 SBType::SBType(const lldb::TypeImplSP &type_impl_sp)
     : m_opaque_sp(type_impl_sp) {}
 
-SBType::SBType(const SBType &rhs) : m_opaque_sp() {
+SBType::SBType(const SBType &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBType, (const lldb::SBType &), rhs);
 
   if (this != &rhs) {
@@ -649,13 +649,11 @@ uint32_t SBTypeList::GetSize() {
 
 SBTypeList::~SBTypeList() = default;
 
-SBTypeMember::SBTypeMember() : m_opaque_up() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeMember);
-}
+SBTypeMember::SBTypeMember() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeMember); }
 
 SBTypeMember::~SBTypeMember() = default;
 
-SBTypeMember::SBTypeMember(const SBTypeMember &rhs) : m_opaque_up() {
+SBTypeMember::SBTypeMember(const SBTypeMember &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBTypeMember, (const lldb::SBTypeMember &), rhs);
 
   if (this != &rhs) {
@@ -780,7 +778,7 @@ TypeMemberImpl &SBTypeMember::ref() {
 
 const TypeMemberImpl &SBTypeMember::ref() const { return *m_opaque_up; }
 
-SBTypeMemberFunction::SBTypeMemberFunction() : m_opaque_sp() {
+SBTypeMemberFunction::SBTypeMemberFunction() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeMemberFunction);
 }
 

diff  --git a/lldb/source/API/SBTypeCategory.cpp b/lldb/source/API/SBTypeCategory.cpp
index e7432959b2600..75acb5a14c505 100644
--- a/lldb/source/API/SBTypeCategory.cpp
+++ b/lldb/source/API/SBTypeCategory.cpp
@@ -26,11 +26,11 @@ using namespace lldb_private;
 
 typedef std::pair<lldb::TypeCategoryImplSP, user_id_t> ImplType;
 
-SBTypeCategory::SBTypeCategory() : m_opaque_sp() {
+SBTypeCategory::SBTypeCategory() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeCategory);
 }
 
-SBTypeCategory::SBTypeCategory(const char *name) : m_opaque_sp() {
+SBTypeCategory::SBTypeCategory(const char *name) {
   DataVisualization::Categories::GetCategory(ConstString(name), m_opaque_sp);
 }
 

diff  --git a/lldb/source/API/SBTypeEnumMember.cpp b/lldb/source/API/SBTypeEnumMember.cpp
index 43a4891b54b10..036b3ce7d1de4 100644
--- a/lldb/source/API/SBTypeEnumMember.cpp
+++ b/lldb/source/API/SBTypeEnumMember.cpp
@@ -21,7 +21,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBTypeEnumMember::SBTypeEnumMember() : m_opaque_sp() {
+SBTypeEnumMember::SBTypeEnumMember() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeEnumMember);
 }
 
@@ -31,8 +31,7 @@ SBTypeEnumMember::SBTypeEnumMember(
     const lldb::TypeEnumMemberImplSP &enum_member_sp)
     : m_opaque_sp(enum_member_sp) {}
 
-SBTypeEnumMember::SBTypeEnumMember(const SBTypeEnumMember &rhs)
-    : m_opaque_sp() {
+SBTypeEnumMember::SBTypeEnumMember(const SBTypeEnumMember &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBTypeEnumMember, (const lldb::SBTypeEnumMember &),
                           rhs);
 

diff  --git a/lldb/source/API/SBTypeFilter.cpp b/lldb/source/API/SBTypeFilter.cpp
index 5f91a194f16bf..8b7fa4bc5b388 100644
--- a/lldb/source/API/SBTypeFilter.cpp
+++ b/lldb/source/API/SBTypeFilter.cpp
@@ -16,9 +16,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBTypeFilter::SBTypeFilter() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeFilter);
-}
+SBTypeFilter::SBTypeFilter() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeFilter); }
 
 SBTypeFilter::SBTypeFilter(uint32_t options)
     : m_opaque_sp(TypeFilterImplSP(new TypeFilterImpl(options))) {

diff  --git a/lldb/source/API/SBTypeFormat.cpp b/lldb/source/API/SBTypeFormat.cpp
index 70289bef8db5d..eeb2cbb4465f3 100644
--- a/lldb/source/API/SBTypeFormat.cpp
+++ b/lldb/source/API/SBTypeFormat.cpp
@@ -16,9 +16,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBTypeFormat::SBTypeFormat() : m_opaque_sp() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeFormat);
-}
+SBTypeFormat::SBTypeFormat() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeFormat); }
 
 SBTypeFormat::SBTypeFormat(lldb::Format format, uint32_t options)
     : m_opaque_sp(

diff  --git a/lldb/source/API/SBTypeNameSpecifier.cpp b/lldb/source/API/SBTypeNameSpecifier.cpp
index 3673a50245304..b84c42eff9e34 100644
--- a/lldb/source/API/SBTypeNameSpecifier.cpp
+++ b/lldb/source/API/SBTypeNameSpecifier.cpp
@@ -17,7 +17,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBTypeNameSpecifier::SBTypeNameSpecifier() : m_opaque_sp() {
+SBTypeNameSpecifier::SBTypeNameSpecifier() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeNameSpecifier);
 }
 
@@ -30,7 +30,7 @@ SBTypeNameSpecifier::SBTypeNameSpecifier(const char *name, bool is_regex)
     m_opaque_sp.reset();
 }
 
-SBTypeNameSpecifier::SBTypeNameSpecifier(SBType type) : m_opaque_sp() {
+SBTypeNameSpecifier::SBTypeNameSpecifier(SBType type) {
   LLDB_RECORD_CONSTRUCTOR(SBTypeNameSpecifier, (lldb::SBType), type);
 
   if (type.IsValid())

diff  --git a/lldb/source/API/SBTypeSummary.cpp b/lldb/source/API/SBTypeSummary.cpp
index 2d7f8ef340c9b..1072baf4fd9c2 100644
--- a/lldb/source/API/SBTypeSummary.cpp
+++ b/lldb/source/API/SBTypeSummary.cpp
@@ -107,7 +107,7 @@ SBTypeSummaryOptions::SBTypeSummaryOptions(
                           lldb_object);
 }
 
-SBTypeSummary::SBTypeSummary() : m_opaque_sp() {
+SBTypeSummary::SBTypeSummary() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeSummary);
 }
 

diff  --git a/lldb/source/API/SBTypeSynthetic.cpp b/lldb/source/API/SBTypeSynthetic.cpp
index af5e167b9c247..502feb40120b2 100644
--- a/lldb/source/API/SBTypeSynthetic.cpp
+++ b/lldb/source/API/SBTypeSynthetic.cpp
@@ -16,7 +16,7 @@
 using namespace lldb;
 using namespace lldb_private;
 
-SBTypeSynthetic::SBTypeSynthetic() : m_opaque_sp() {
+SBTypeSynthetic::SBTypeSynthetic() {
   LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBTypeSynthetic);
 }
 

diff  --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp
index e3325b8d36fa9..d61f11bb807d6 100644
--- a/lldb/source/API/SBValue.cpp
+++ b/lldb/source/API/SBValue.cpp
@@ -58,8 +58,8 @@ class ValueImpl {
   ValueImpl(lldb::ValueObjectSP in_valobj_sp,
             lldb::DynamicValueType use_dynamic, bool use_synthetic,
             const char *name = nullptr)
-      : m_valobj_sp(), m_use_dynamic(use_dynamic),
-        m_use_synthetic(use_synthetic), m_name(name) {
+      : m_use_dynamic(use_dynamic), m_use_synthetic(use_synthetic),
+        m_name(name) {
     if (in_valobj_sp) {
       if ((m_valobj_sp = in_valobj_sp->GetQualifiedRepresentationIfAvailable(
                lldb::eNoDynamicValues, false))) {
@@ -215,7 +215,7 @@ class ValueLocker {
   Status m_lock_error;
 };
 
-SBValue::SBValue() : m_opaque_sp() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBValue); }
+SBValue::SBValue() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBValue); }
 
 SBValue::SBValue(const lldb::ValueObjectSP &value_sp) {
   LLDB_RECORD_CONSTRUCTOR(SBValue, (const lldb::ValueObjectSP &), value_sp);

diff  --git a/lldb/source/API/SBValueList.cpp b/lldb/source/API/SBValueList.cpp
index 0fd2a591c321c..7e797d2b7801f 100644
--- a/lldb/source/API/SBValueList.cpp
+++ b/lldb/source/API/SBValueList.cpp
@@ -19,7 +19,7 @@ using namespace lldb_private;
 
 class ValueListImpl {
 public:
-  ValueListImpl() : m_values() {}
+  ValueListImpl() {}
 
   ValueListImpl(const ValueListImpl &rhs) : m_values(rhs.m_values) {}
 
@@ -67,18 +67,16 @@ class ValueListImpl {
   std::vector<lldb::SBValue> m_values;
 };
 
-SBValueList::SBValueList() : m_opaque_up() {
-  LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBValueList);
-}
+SBValueList::SBValueList() { LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBValueList); }
 
-SBValueList::SBValueList(const SBValueList &rhs) : m_opaque_up() {
+SBValueList::SBValueList(const SBValueList &rhs) {
   LLDB_RECORD_CONSTRUCTOR(SBValueList, (const lldb::SBValueList &), rhs);
 
   if (rhs.IsValid())
     m_opaque_up = std::make_unique<ValueListImpl>(*rhs);
 }
 
-SBValueList::SBValueList(const ValueListImpl *lldb_object_ptr) : m_opaque_up() {
+SBValueList::SBValueList(const ValueListImpl *lldb_object_ptr) {
   if (lldb_object_ptr)
     m_opaque_up = std::make_unique<ValueListImpl>(*lldb_object_ptr);
 }


        


More information about the lldb-commits mailing list