diff --git a/lldb/source/API/SBMemoryRegionInfoList.cpp b/lldb/source/API/SBMemoryRegionInfoList.cpp --- a/lldb/source/API/SBMemoryRegionInfoList.cpp +++ b/lldb/source/API/SBMemoryRegionInfoList.cpp @@ -21,8 +21,7 @@ public: MemoryRegionInfoListImpl() : m_regions() {} - MemoryRegionInfoListImpl(const MemoryRegionInfoListImpl &rhs) - : m_regions(rhs.m_regions) {} + MemoryRegionInfoListImpl(const MemoryRegionInfoListImpl &rhs) = default; MemoryRegionInfoListImpl &operator=(const MemoryRegionInfoListImpl &rhs) { if (this == &rhs) diff --git a/lldb/source/API/SBQueue.cpp b/lldb/source/API/SBQueue.cpp --- a/lldb/source/API/SBQueue.cpp +++ b/lldb/source/API/SBQueue.cpp @@ -27,7 +27,7 @@ class QueueImpl { public: - QueueImpl() {} + QueueImpl() = default; QueueImpl(const lldb::QueueSP &queue_sp) { m_queue_wp = queue_sp; } diff --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp --- a/lldb/source/API/SBValue.cpp +++ b/lldb/source/API/SBValue.cpp @@ -69,9 +69,7 @@ } } - ValueImpl(const ValueImpl &rhs) - : m_valobj_sp(rhs.m_valobj_sp), m_use_dynamic(rhs.m_use_dynamic), - m_use_synthetic(rhs.m_use_synthetic), m_name(rhs.m_name) {} + ValueImpl(const ValueImpl &rhs) = default; ValueImpl &operator=(const ValueImpl &rhs) { if (this != &rhs) { diff --git a/lldb/source/API/SBValueList.cpp b/lldb/source/API/SBValueList.cpp --- a/lldb/source/API/SBValueList.cpp +++ b/lldb/source/API/SBValueList.cpp @@ -19,9 +19,9 @@ class ValueListImpl { public: - ValueListImpl() {} + ValueListImpl() = default; - ValueListImpl(const ValueListImpl &rhs) : m_values(rhs.m_values) {} + ValueListImpl(const ValueListImpl &rhs) = default; ValueListImpl &operator=(const ValueListImpl &rhs) { if (this == &rhs) diff --git a/lldb/source/Commands/CommandObjectBreakpoint.cpp b/lldb/source/Commands/CommandObjectBreakpoint.cpp --- a/lldb/source/Commands/CommandObjectBreakpoint.cpp +++ b/lldb/source/Commands/CommandObjectBreakpoint.cpp @@ -179,7 +179,7 @@ class BreakpointDummyOptionGroup : public OptionGroup { public: - BreakpointDummyOptionGroup() {} + BreakpointDummyOptionGroup() = default; ~BreakpointDummyOptionGroup() override = default; @@ -252,7 +252,7 @@ class CommandOptions : public OptionGroup { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1118,7 +1118,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1249,7 +1249,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1401,7 +1401,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1618,7 +1618,7 @@ class BreakpointAccessOptionGroup : public OptionGroup { public: - BreakpointAccessOptionGroup() {} + BreakpointAccessOptionGroup() = default; ~BreakpointAccessOptionGroup() override = default; @@ -2059,7 +2059,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -2255,7 +2255,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectBreakpointCommand.cpp b/lldb/source/Commands/CommandObjectBreakpointCommand.cpp --- a/lldb/source/Commands/CommandObjectBreakpointCommand.cpp +++ b/lldb/source/Commands/CommandObjectBreakpointCommand.cpp @@ -281,7 +281,7 @@ class CommandOptions : public OptionGroup { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -501,7 +501,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectCommands.cpp b/lldb/source/Commands/CommandObjectCommands.cpp --- a/lldb/source/Commands/CommandObjectCommands.cpp +++ b/lldb/source/Commands/CommandObjectCommands.cpp @@ -206,7 +206,7 @@ protected: class CommandOptions : public OptionGroup { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1022,7 +1022,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1267,7 +1267,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1422,7 +1422,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1880,7 +1880,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectExpression.cpp b/lldb/source/Commands/CommandObjectExpression.cpp --- a/lldb/source/Commands/CommandObjectExpression.cpp +++ b/lldb/source/Commands/CommandObjectExpression.cpp @@ -24,7 +24,7 @@ using namespace lldb; using namespace lldb_private; -CommandObjectExpression::CommandOptions::CommandOptions() {} +CommandObjectExpression::CommandOptions::CommandOptions() = default; CommandObjectExpression::CommandOptions::~CommandOptions() = default; diff --git a/lldb/source/Commands/CommandObjectFrame.cpp b/lldb/source/Commands/CommandObjectFrame.cpp --- a/lldb/source/Commands/CommandObjectFrame.cpp +++ b/lldb/source/Commands/CommandObjectFrame.cpp @@ -726,7 +726,7 @@ private: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, diff --git a/lldb/source/Commands/CommandObjectLog.cpp b/lldb/source/Commands/CommandObjectLog.cpp --- a/lldb/source/Commands/CommandObjectLog.cpp +++ b/lldb/source/Commands/CommandObjectLog.cpp @@ -75,7 +75,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectMemory.cpp b/lldb/source/Commands/CommandObjectMemory.cpp --- a/lldb/source/Commands/CommandObjectMemory.cpp +++ b/lldb/source/Commands/CommandObjectMemory.cpp @@ -1186,7 +1186,7 @@ public: class OptionGroupWriteMemory : public OptionGroup { public: - OptionGroupWriteMemory() {} + OptionGroupWriteMemory() = default; ~OptionGroupWriteMemory() override = default; diff --git a/lldb/source/Commands/CommandObjectMemoryTag.cpp b/lldb/source/Commands/CommandObjectMemoryTag.cpp --- a/lldb/source/Commands/CommandObjectMemoryTag.cpp +++ b/lldb/source/Commands/CommandObjectMemoryTag.cpp @@ -138,7 +138,7 @@ public: class OptionGroupTagWrite : public OptionGroup { public: - OptionGroupTagWrite() {} + OptionGroupTagWrite() = default; ~OptionGroupTagWrite() override = default; diff --git a/lldb/source/Commands/CommandObjectPlatform.cpp b/lldb/source/Commands/CommandObjectPlatform.cpp --- a/lldb/source/Commands/CommandObjectPlatform.cpp +++ b/lldb/source/Commands/CommandObjectPlatform.cpp @@ -600,7 +600,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -692,7 +692,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1315,7 +1315,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1679,7 +1679,7 @@ public: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectProcess.cpp b/lldb/source/Commands/CommandObjectProcess.cpp --- a/lldb/source/Commands/CommandObjectProcess.cpp +++ b/lldb/source/Commands/CommandObjectProcess.cpp @@ -1214,7 +1214,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1317,7 +1317,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectReproducer.cpp b/lldb/source/Commands/CommandObjectReproducer.cpp --- a/lldb/source/Commands/CommandObjectReproducer.cpp +++ b/lldb/source/Commands/CommandObjectReproducer.cpp @@ -223,7 +223,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -351,7 +351,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectSettings.cpp b/lldb/source/Commands/CommandObjectSettings.cpp --- a/lldb/source/Commands/CommandObjectSettings.cpp +++ b/lldb/source/Commands/CommandObjectSettings.cpp @@ -86,7 +86,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -329,7 +329,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -427,7 +427,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectSource.cpp b/lldb/source/Commands/CommandObjectSource.cpp --- a/lldb/source/Commands/CommandObjectSource.cpp +++ b/lldb/source/Commands/CommandObjectSource.cpp @@ -36,7 +36,7 @@ class CommandObjectSourceInfo : public CommandObjectParsed { class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -623,7 +623,7 @@ class CommandObjectSourceList : public CommandObjectParsed { class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -755,7 +755,7 @@ SourceInfo(ConstString name, const LineEntry &line_entry) : function(name), line_entry(line_entry) {} - SourceInfo() {} + SourceInfo() = default; bool IsValid() const { return (bool)function && line_entry.IsValid(); } diff --git a/lldb/source/Commands/CommandObjectTarget.cpp b/lldb/source/Commands/CommandObjectTarget.cpp --- a/lldb/source/Commands/CommandObjectTarget.cpp +++ b/lldb/source/Commands/CommandObjectTarget.cpp @@ -1936,7 +1936,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -2841,7 +2841,7 @@ public: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -3183,7 +3183,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectType.cpp b/lldb/source/Commands/CommandObjectType.cpp --- a/lldb/source/Commands/CommandObjectType.cpp +++ b/lldb/source/Commands/CommandObjectType.cpp @@ -286,7 +286,7 @@ private: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -498,7 +498,7 @@ private: class CommandOptions : public OptionGroup { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -707,7 +707,7 @@ protected: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -872,7 +872,7 @@ private: class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1815,7 +1815,7 @@ class CommandObjectTypeCategoryEnable : public CommandObjectParsed { class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -1992,7 +1992,7 @@ class CommandObjectTypeCategoryDisable : public CommandObjectParsed { class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -2405,7 +2405,7 @@ typedef std::vector option_vector; public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -2661,7 +2661,7 @@ class CommandOptions : public OptionGroup { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectWatchpoint.cpp b/lldb/source/Commands/CommandObjectWatchpoint.cpp --- a/lldb/source/Commands/CommandObjectWatchpoint.cpp +++ b/lldb/source/Commands/CommandObjectWatchpoint.cpp @@ -164,7 +164,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -454,7 +454,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -577,7 +577,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; @@ -702,7 +702,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Commands/CommandObjectWatchpointCommand.cpp b/lldb/source/Commands/CommandObjectWatchpointCommand.cpp --- a/lldb/source/Commands/CommandObjectWatchpointCommand.cpp +++ b/lldb/source/Commands/CommandObjectWatchpointCommand.cpp @@ -313,7 +313,7 @@ class CommandOptions : public Options { public: - CommandOptions() {} + CommandOptions() = default; ~CommandOptions() override = default; diff --git a/lldb/source/Core/IOHandlerCursesGUI.cpp b/lldb/source/Core/IOHandlerCursesGUI.cpp --- a/lldb/source/Core/IOHandlerCursesGUI.cpp +++ b/lldb/source/Core/IOHandlerCursesGUI.cpp @@ -2282,7 +2282,7 @@ class FormDelegate { public: - FormDelegate() {} + FormDelegate() = default; virtual ~FormDelegate() = default; @@ -3644,7 +3644,7 @@ class SearcherDelegate { public: - SearcherDelegate() {} + SearcherDelegate() = default; virtual ~SearcherDelegate() = default; diff --git a/lldb/source/Host/macosx/cfcpp/CFCData.cpp b/lldb/source/Host/macosx/cfcpp/CFCData.cpp --- a/lldb/source/Host/macosx/cfcpp/CFCData.cpp +++ b/lldb/source/Host/macosx/cfcpp/CFCData.cpp @@ -12,7 +12,7 @@ CFCData::CFCData(CFDataRef data) : CFCReleaser(data) {} // CFCData copy constructor -CFCData::CFCData(const CFCData &rhs) : CFCReleaser(rhs) {} +CFCData::CFCData(const CFCData &rhs) = default; // CFCData copy constructor CFCData &CFCData::operator=(const CFCData &rhs) diff --git a/lldb/source/Host/macosx/cfcpp/CFCMutableArray.cpp b/lldb/source/Host/macosx/cfcpp/CFCMutableArray.cpp --- a/lldb/source/Host/macosx/cfcpp/CFCMutableArray.cpp +++ b/lldb/source/Host/macosx/cfcpp/CFCMutableArray.cpp @@ -14,11 +14,10 @@ : CFCReleaser(s) {} // CFCMutableArray copy constructor -CFCMutableArray::CFCMutableArray(const CFCMutableArray &rhs) - : CFCReleaser(rhs) // NOTE: this won't make a copy of the - // array, just add a new reference to - // it -{} +CFCMutableArray::CFCMutableArray(const CFCMutableArray &rhs) = + default; // NOTE: this won't make a copy of the + // array, just add a new reference to + // it // CFCMutableArray copy constructor CFCMutableArray &CFCMutableArray::operator=(const CFCMutableArray &rhs) { diff --git a/lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.cpp b/lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.cpp --- a/lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.cpp +++ b/lldb/source/Host/macosx/cfcpp/CFCMutableDictionary.cpp @@ -13,8 +13,8 @@ : CFCReleaser(s) {} // CFCMutableDictionary copy constructor -CFCMutableDictionary::CFCMutableDictionary(const CFCMutableDictionary &rhs) - : CFCReleaser(rhs) {} +CFCMutableDictionary::CFCMutableDictionary(const CFCMutableDictionary &rhs) = + default; // CFCMutableDictionary copy constructor const CFCMutableDictionary &CFCMutableDictionary:: diff --git a/lldb/source/Host/macosx/cfcpp/CFCMutableSet.cpp b/lldb/source/Host/macosx/cfcpp/CFCMutableSet.cpp --- a/lldb/source/Host/macosx/cfcpp/CFCMutableSet.cpp +++ b/lldb/source/Host/macosx/cfcpp/CFCMutableSet.cpp @@ -14,8 +14,7 @@ : CFCReleaser(s) {} // CFCMutableSet copy constructor -CFCMutableSet::CFCMutableSet(const CFCMutableSet &rhs) - : CFCReleaser(rhs) {} +CFCMutableSet::CFCMutableSet(const CFCMutableSet &rhs) = default; // CFCMutableSet copy constructor const CFCMutableSet &CFCMutableSet::operator=(const CFCMutableSet &rhs) { diff --git a/lldb/source/Host/macosx/cfcpp/CFCString.cpp b/lldb/source/Host/macosx/cfcpp/CFCString.cpp --- a/lldb/source/Host/macosx/cfcpp/CFCString.cpp +++ b/lldb/source/Host/macosx/cfcpp/CFCString.cpp @@ -14,7 +14,7 @@ CFCString::CFCString(CFStringRef s) : CFCReleaser(s) {} // CFCString copy constructor -CFCString::CFCString(const CFCString &rhs) : CFCReleaser(rhs) {} +CFCString::CFCString(const CFCString &rhs) = default; // CFCString copy constructor CFCString &CFCString::operator=(const CFCString &rhs) { diff --git a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp --- a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp +++ b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp @@ -806,7 +806,7 @@ md->removeOriginsWithContext(src_ast); } -ClangASTImporter::MapCompleter::~MapCompleter() {} +ClangASTImporter::MapCompleter::~MapCompleter() = default; llvm::Expected ClangASTImporter::ASTImporterDelegate::ImportImpl(Decl *From) { diff --git a/lldb/source/Plugins/REPL/Clang/ClangREPL.cpp b/lldb/source/Plugins/REPL/Clang/ClangREPL.cpp --- a/lldb/source/Plugins/REPL/Clang/ClangREPL.cpp +++ b/lldb/source/Plugins/REPL/Clang/ClangREPL.cpp @@ -19,7 +19,7 @@ : REPL(eKindClang, target), m_language(language), m_implicit_expr_result_regex("\\$[0-9]+") {} -ClangREPL::~ClangREPL() {} +ClangREPL::~ClangREPL() = default; void ClangREPL::Initialize() { LanguageSet languages; diff --git a/lldb/source/Target/ExecutionContext.cpp b/lldb/source/Target/ExecutionContext.cpp --- a/lldb/source/Target/ExecutionContext.cpp +++ b/lldb/source/Target/ExecutionContext.cpp @@ -19,9 +19,7 @@ ExecutionContext::ExecutionContext() : m_target_sp(), m_process_sp(), m_thread_sp(), m_frame_sp() {} -ExecutionContext::ExecutionContext(const ExecutionContext &rhs) - : m_target_sp(rhs.m_target_sp), m_process_sp(rhs.m_process_sp), - m_thread_sp(rhs.m_thread_sp), m_frame_sp(rhs.m_frame_sp) {} +ExecutionContext::ExecutionContext(const ExecutionContext &rhs) = default; ExecutionContext::ExecutionContext(const lldb::TargetSP &target_sp, bool get_process) @@ -414,9 +412,8 @@ } ExecutionContextRef::ExecutionContextRef(const ExecutionContextRef &rhs) - : m_target_wp(rhs.m_target_wp), m_process_wp(rhs.m_process_wp), - m_thread_wp(rhs.m_thread_wp), m_tid(rhs.m_tid), - m_stack_id(rhs.m_stack_id) {} + + = default; ExecutionContextRef &ExecutionContextRef:: operator=(const ExecutionContextRef &rhs) { diff --git a/lldb/source/Utility/XcodeSDK.cpp b/lldb/source/Utility/XcodeSDK.cpp --- a/lldb/source/Utility/XcodeSDK.cpp +++ b/lldb/source/Utility/XcodeSDK.cpp @@ -54,10 +54,7 @@ } } -XcodeSDK &XcodeSDK::operator=(const XcodeSDK &other) { - m_name = other.m_name; - return *this; -} +XcodeSDK &XcodeSDK::operator=(const XcodeSDK &other) = default; bool XcodeSDK::operator==(const XcodeSDK &other) { return m_name == other.m_name; diff --git a/lldb/tools/debugserver/source/DNBBreakpoint.cpp b/lldb/tools/debugserver/source/DNBBreakpoint.cpp --- a/lldb/tools/debugserver/source/DNBBreakpoint.cpp +++ b/lldb/tools/debugserver/source/DNBBreakpoint.cpp @@ -25,7 +25,7 @@ m_is_watchpoint(0), m_watch_read(0), m_watch_write(0), m_hw_index(INVALID_NUB_HW_INDEX) {} -DNBBreakpoint::~DNBBreakpoint() {} +DNBBreakpoint::~DNBBreakpoint() = default; void DNBBreakpoint::Dump() const { if (IsBreakpoint()) { @@ -45,9 +45,9 @@ #pragma mark-- DNBBreakpointList -DNBBreakpointList::DNBBreakpointList() {} +DNBBreakpointList::DNBBreakpointList() = default; -DNBBreakpointList::~DNBBreakpointList() {} +DNBBreakpointList::~DNBBreakpointList() = default; DNBBreakpoint *DNBBreakpointList::Add(nub_addr_t addr, nub_size_t length, bool hardware) { diff --git a/lldb/tools/debugserver/source/DNBDataRef.cpp b/lldb/tools/debugserver/source/DNBDataRef.cpp --- a/lldb/tools/debugserver/source/DNBDataRef.cpp +++ b/lldb/tools/debugserver/source/DNBDataRef.cpp @@ -32,7 +32,7 @@ // Destructor -DNBDataRef::~DNBDataRef() {} +DNBDataRef::~DNBDataRef() = default; // Get8 uint8_t DNBDataRef::Get8(offset_t *offset_ptr) const { diff --git a/lldb/tools/debugserver/source/MacOSX/CFBundle.cpp b/lldb/tools/debugserver/source/MacOSX/CFBundle.cpp --- a/lldb/tools/debugserver/source/MacOSX/CFBundle.cpp +++ b/lldb/tools/debugserver/source/MacOSX/CFBundle.cpp @@ -21,8 +21,7 @@ } // CFBundle copy constructor -CFBundle::CFBundle(const CFBundle &rhs) - : CFReleaser(rhs), m_bundle_url(rhs.m_bundle_url) {} +CFBundle::CFBundle(const CFBundle &rhs) = default; // CFBundle copy constructor CFBundle &CFBundle::operator=(const CFBundle &rhs) { @@ -32,7 +31,7 @@ } // Destructor -CFBundle::~CFBundle() {} +CFBundle::~CFBundle() = default; // Set the path for a bundle by supplying a bool CFBundle::SetPath(const char *path) { diff --git a/lldb/tools/debugserver/source/MacOSX/CFString.cpp b/lldb/tools/debugserver/source/MacOSX/CFString.cpp --- a/lldb/tools/debugserver/source/MacOSX/CFString.cpp +++ b/lldb/tools/debugserver/source/MacOSX/CFString.cpp @@ -18,7 +18,7 @@ CFString::CFString(CFStringRef s) : CFReleaser(s) {} // CFString copy constructor -CFString::CFString(const CFString &rhs) : CFReleaser(rhs) {} +CFString::CFString(const CFString &rhs) = default; // CFString copy constructor CFString &CFString::operator=(const CFString &rhs) { @@ -36,7 +36,7 @@ } // Destructor -CFString::~CFString() {} +CFString::~CFString() = default; const char *CFString::GetFileSystemRepresentation(std::string &s) { return CFString::FileSystemRepresentation(get(), s); diff --git a/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp b/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp --- a/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp +++ b/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp @@ -26,7 +26,7 @@ : m_threads(), m_threads_mutex(PTHREAD_MUTEX_RECURSIVE), m_is_64_bit(false) {} -MachThreadList::~MachThreadList() {} +MachThreadList::~MachThreadList() = default; nub_state_t MachThreadList::GetState(nub_thread_t tid) { MachThreadSP thread_sp(GetThreadByID(tid)); diff --git a/lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp b/lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp --- a/lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp +++ b/lldb/tools/debugserver/source/MacOSX/MachVMMemory.cpp @@ -28,7 +28,7 @@ MachVMMemory::MachVMMemory() : m_page_size(kInvalidPageSize), m_err(0) {} -MachVMMemory::~MachVMMemory() {} +MachVMMemory::~MachVMMemory() = default; nub_size_t MachVMMemory::PageSize(task_t task) { if (m_page_size == kInvalidPageSize) { diff --git a/lldb/tools/debugserver/source/StdStringExtractor.cpp b/lldb/tools/debugserver/source/StdStringExtractor.cpp --- a/lldb/tools/debugserver/source/StdStringExtractor.cpp +++ b/lldb/tools/debugserver/source/StdStringExtractor.cpp @@ -30,7 +30,7 @@ } // Destructor -StdStringExtractor::~StdStringExtractor() {} +StdStringExtractor::~StdStringExtractor() = default; char StdStringExtractor::GetChar(char fail_value) { if (m_index < m_packet.size()) { diff --git a/lldb/tools/debugserver/source/TTYState.cpp b/lldb/tools/debugserver/source/TTYState.cpp --- a/lldb/tools/debugserver/source/TTYState.cpp +++ b/lldb/tools/debugserver/source/TTYState.cpp @@ -18,7 +18,7 @@ TTYState::TTYState() : m_fd(-1), m_tflags(-1), m_ttystateErr(-1), m_processGroup(-1) {} -TTYState::~TTYState() {} +TTYState::~TTYState() = default; bool TTYState::GetTTYState(int fd, bool saveProcessGroup) { if (fd >= 0 && ::isatty(fd)) { @@ -62,7 +62,7 @@ TTYStateSwitcher::TTYStateSwitcher() : m_currentState(~0) {} -TTYStateSwitcher::~TTYStateSwitcher() {} +TTYStateSwitcher::~TTYStateSwitcher() = default; bool TTYStateSwitcher::GetState(uint32_t idx, int fd, bool saveProcessGroup) { if (ValidStateIndex(idx)) diff --git a/lldb/tools/lldb-vscode/IOStream.cpp b/lldb/tools/lldb-vscode/IOStream.cpp --- a/lldb/tools/lldb-vscode/IOStream.cpp +++ b/lldb/tools/lldb-vscode/IOStream.cpp @@ -22,7 +22,7 @@ using namespace lldb_vscode; -StreamDescriptor::StreamDescriptor() {} +StreamDescriptor::StreamDescriptor() = default; StreamDescriptor::StreamDescriptor(StreamDescriptor &&other) { *this = std::move(other); diff --git a/lldb/tools/lldb-vscode/VSCode.cpp b/lldb/tools/lldb-vscode/VSCode.cpp --- a/lldb/tools/lldb-vscode/VSCode.cpp +++ b/lldb/tools/lldb-vscode/VSCode.cpp @@ -58,7 +58,7 @@ log.reset(new std::ofstream(log_file_path)); } -VSCode::~VSCode() {} +VSCode::~VSCode() = default; int64_t VSCode::GetLineForPC(int64_t sourceReference, lldb::addr_t pc) const { auto pos = source_map.find(sourceReference);