[Lldb-commits] [lldb] 54d03a4 - [lldb/Interpreter][NFC] Replace default constructors/destructors bodies with "=default"
Tatyana Krasnukha via lldb-commits
lldb-commits at lists.llvm.org
Sun Feb 28 08:24:21 PST 2021
Author: Tatyana Krasnukha
Date: 2021-02-28T19:23:16+03:00
New Revision: 54d03a4985bc9a0a84c4dff835ec6ed0f607582f
URL: https://github.com/llvm/llvm-project/commit/54d03a4985bc9a0a84c4dff835ec6ed0f607582f
DIFF: https://github.com/llvm/llvm-project/commit/54d03a4985bc9a0a84c4dff835ec6ed0f607582f.diff
LOG: [lldb/Interpreter][NFC] Replace default constructors/destructors bodies with "=default"
Added:
Modified:
lldb/include/lldb/Interpreter/CommandHistory.h
lldb/include/lldb/Interpreter/CommandObject.h
lldb/include/lldb/Interpreter/CommandReturnObject.h
lldb/include/lldb/Interpreter/OptionGroupArchitecture.h
lldb/include/lldb/Interpreter/OptionGroupBoolean.h
lldb/include/lldb/Interpreter/OptionGroupFile.h
lldb/include/lldb/Interpreter/OptionGroupFormat.h
lldb/include/lldb/Interpreter/OptionGroupOutputFile.h
lldb/include/lldb/Interpreter/OptionGroupPythonClassWithDict.h
lldb/include/lldb/Interpreter/OptionGroupString.h
lldb/include/lldb/Interpreter/OptionGroupUInt64.h
lldb/include/lldb/Interpreter/OptionGroupUUID.h
lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h
lldb/include/lldb/Interpreter/OptionGroupVariable.h
lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h
lldb/include/lldb/Interpreter/OptionValueArch.h
lldb/include/lldb/Interpreter/OptionValueArgs.h
lldb/include/lldb/Interpreter/OptionValueArray.h
lldb/include/lldb/Interpreter/OptionValueBoolean.h
lldb/include/lldb/Interpreter/OptionValueChar.h
lldb/include/lldb/Interpreter/OptionValueDictionary.h
lldb/include/lldb/Interpreter/OptionValueEnumeration.h
lldb/include/lldb/Interpreter/OptionValueFileColonLine.h
lldb/include/lldb/Interpreter/OptionValueFileSpec.h
lldb/include/lldb/Interpreter/OptionValueFileSpecList.h
lldb/include/lldb/Interpreter/OptionValueFormat.h
lldb/include/lldb/Interpreter/OptionValueFormatEntity.h
lldb/include/lldb/Interpreter/OptionValueLanguage.h
lldb/include/lldb/Interpreter/OptionValuePathMappings.h
lldb/include/lldb/Interpreter/OptionValueProperties.h
lldb/include/lldb/Interpreter/OptionValueSInt64.h
lldb/include/lldb/Interpreter/OptionValueString.h
lldb/include/lldb/Interpreter/OptionValueUInt64.h
lldb/include/lldb/Interpreter/OptionValueUUID.h
lldb/include/lldb/Interpreter/ScriptInterpreter.h
lldb/source/Interpreter/CommandHistory.cpp
lldb/source/Interpreter/CommandObject.cpp
lldb/source/Interpreter/CommandReturnObject.cpp
lldb/source/Interpreter/OptionGroupArchitecture.cpp
lldb/source/Interpreter/OptionGroupBoolean.cpp
lldb/source/Interpreter/OptionGroupFile.cpp
lldb/source/Interpreter/OptionGroupFormat.cpp
lldb/source/Interpreter/OptionGroupOutputFile.cpp
lldb/source/Interpreter/OptionGroupPythonClassWithDict.cpp
lldb/source/Interpreter/OptionGroupString.cpp
lldb/source/Interpreter/OptionGroupUInt64.cpp
lldb/source/Interpreter/OptionGroupUUID.cpp
lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp
lldb/source/Interpreter/OptionGroupVariable.cpp
lldb/source/Interpreter/OptionGroupWatchpoint.cpp
lldb/source/Interpreter/OptionValueEnumeration.cpp
lldb/source/Interpreter/Options.cpp
lldb/source/Interpreter/ScriptInterpreter.cpp
Removed:
################################################################################
diff --git a/lldb/include/lldb/Interpreter/CommandHistory.h b/lldb/include/lldb/Interpreter/CommandHistory.h
index fbb42247f11a..12c170ba5eeb 100644
--- a/lldb/include/lldb/Interpreter/CommandHistory.h
+++ b/lldb/include/lldb/Interpreter/CommandHistory.h
@@ -20,9 +20,9 @@ namespace lldb_private {
class CommandHistory {
public:
- CommandHistory();
+ CommandHistory() = default;
- ~CommandHistory();
+ ~CommandHistory() = default;
size_t GetSize() const;
diff --git a/lldb/include/lldb/Interpreter/CommandObject.h b/lldb/include/lldb/Interpreter/CommandObject.h
index d5ad969cda66..8bc5d3e22355 100644
--- a/lldb/include/lldb/Interpreter/CommandObject.h
+++ b/lldb/include/lldb/Interpreter/CommandObject.h
@@ -113,7 +113,7 @@ class CommandObject {
llvm::StringRef help = "", llvm::StringRef syntax = "",
uint32_t flags = 0);
- virtual ~CommandObject();
+ virtual ~CommandObject() = default;
static const char *
GetArgumentTypeAsCString(const lldb::CommandArgumentType arg_type);
diff --git a/lldb/include/lldb/Interpreter/CommandReturnObject.h b/lldb/include/lldb/Interpreter/CommandReturnObject.h
index 06b648517d13..c638b4bc70b2 100644
--- a/lldb/include/lldb/Interpreter/CommandReturnObject.h
+++ b/lldb/include/lldb/Interpreter/CommandReturnObject.h
@@ -26,7 +26,7 @@ class CommandReturnObject {
public:
CommandReturnObject(bool colors);
- ~CommandReturnObject();
+ ~CommandReturnObject() = default;
llvm::StringRef GetOutputData() {
lldb::StreamSP stream_sp(m_out_stream.GetStreamAtIndex(eStreamStringIndex));
diff --git a/lldb/include/lldb/Interpreter/OptionGroupArchitecture.h b/lldb/include/lldb/Interpreter/OptionGroupArchitecture.h
index 1eadf45bae47..4655a68f1e4a 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupArchitecture.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupArchitecture.h
@@ -18,9 +18,9 @@ namespace lldb_private {
class OptionGroupArchitecture : public OptionGroup {
public:
- OptionGroupArchitecture();
+ OptionGroupArchitecture() = default;
- ~OptionGroupArchitecture() override;
+ ~OptionGroupArchitecture() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupBoolean.h b/lldb/include/lldb/Interpreter/OptionGroupBoolean.h
index 5411e99148e6..9e2dad5d9c2a 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupBoolean.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupBoolean.h
@@ -25,7 +25,7 @@ class OptionGroupBoolean : public OptionGroup {
const char *usage_text, bool default_value,
bool no_argument_toggle_default);
- ~OptionGroupBoolean() override;
+ ~OptionGroupBoolean() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
return llvm::ArrayRef<OptionDefinition>(&m_option_definition, 1);
diff --git a/lldb/include/lldb/Interpreter/OptionGroupFile.h b/lldb/include/lldb/Interpreter/OptionGroupFile.h
index 22b0eb4a28fa..1e4eb35eade4 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupFile.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupFile.h
@@ -24,7 +24,7 @@ class OptionGroupFile : public OptionGroup {
lldb::CommandArgumentType argument_type,
const char *usage_text);
- ~OptionGroupFile() override;
+ ~OptionGroupFile() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
return llvm::ArrayRef<OptionDefinition>(&m_option_definition, 1);
diff --git a/lldb/include/lldb/Interpreter/OptionGroupFormat.h b/lldb/include/lldb/Interpreter/OptionGroupFormat.h
index 62c6f97c6214..2d445b8a6c20 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupFormat.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupFormat.h
@@ -32,13 +32,12 @@ class OptionGroupFormat : public OptionGroup {
uint64_t default_count =
UINT64_MAX); // Pass UINT64_MAX to disable the "--count" option
- ~OptionGroupFormat() override;
+ ~OptionGroupFormat() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_value,
ExecutionContext *execution_context) override;
- Status SetOptionValue(uint32_t, const char *, ExecutionContext *) = delete;
void OptionParsingStarting(ExecutionContext *execution_context) override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupOutputFile.h b/lldb/include/lldb/Interpreter/OptionGroupOutputFile.h
index a71998f3bc1a..3902247cfb3e 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupOutputFile.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupOutputFile.h
@@ -20,13 +20,12 @@ class OptionGroupOutputFile : public OptionGroup {
public:
OptionGroupOutputFile();
- ~OptionGroupOutputFile() override;
+ ~OptionGroupOutputFile() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_value,
ExecutionContext *execution_context) override;
- Status SetOptionValue(uint32_t, const char *, ExecutionContext *) = delete;
void OptionParsingStarting(ExecutionContext *execution_context) override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupPythonClassWithDict.h b/lldb/include/lldb/Interpreter/OptionGroupPythonClassWithDict.h
index 695a5b93c2ea..7ad4bc092678 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupPythonClassWithDict.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupPythonClassWithDict.h
@@ -29,7 +29,7 @@ class OptionGroupPythonClassWithDict : public OptionGroup {
int key_option = 'k',
int value_option = 'v');
- ~OptionGroupPythonClassWithDict() override;
+ ~OptionGroupPythonClassWithDict() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
return llvm::ArrayRef<OptionDefinition>(m_option_definition);
diff --git a/lldb/include/lldb/Interpreter/OptionGroupString.h b/lldb/include/lldb/Interpreter/OptionGroupString.h
index de1ef0b4bf3c..aa0225639035 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupString.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupString.h
@@ -22,7 +22,7 @@ class OptionGroupString : public OptionGroup {
lldb::CommandArgumentType argument_type,
const char *usage_text, const char *default_value);
- ~OptionGroupString() override;
+ ~OptionGroupString() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
return llvm::ArrayRef<OptionDefinition>(&m_option_definition, 1);
diff --git a/lldb/include/lldb/Interpreter/OptionGroupUInt64.h b/lldb/include/lldb/Interpreter/OptionGroupUInt64.h
index 1e21f56d4338..710591725409 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupUInt64.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupUInt64.h
@@ -23,7 +23,7 @@ class OptionGroupUInt64 : public OptionGroup {
lldb::CommandArgumentType argument_type,
const char *usage_text, uint64_t default_value);
- ~OptionGroupUInt64() override;
+ ~OptionGroupUInt64() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
return llvm::ArrayRef<OptionDefinition>(&m_option_definition, 1);
diff --git a/lldb/include/lldb/Interpreter/OptionGroupUUID.h b/lldb/include/lldb/Interpreter/OptionGroupUUID.h
index b93d99debf6e..4ca2a94b7fb3 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupUUID.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupUUID.h
@@ -18,9 +18,9 @@ namespace lldb_private {
class OptionGroupUUID : public OptionGroup {
public:
- OptionGroupUUID();
+ OptionGroupUUID() = default;
- ~OptionGroupUUID() override;
+ ~OptionGroupUUID() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h b/lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h
index 07879e5dac1f..56452f4956f2 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h
@@ -18,9 +18,9 @@ namespace lldb_private {
class OptionGroupValueObjectDisplay : public OptionGroup {
public:
- OptionGroupValueObjectDisplay();
+ OptionGroupValueObjectDisplay() = default;
- ~OptionGroupValueObjectDisplay() override;
+ ~OptionGroupValueObjectDisplay() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupVariable.h b/lldb/include/lldb/Interpreter/OptionGroupVariable.h
index 4ba1e09d840f..c9f1283d4de2 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupVariable.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupVariable.h
@@ -20,7 +20,7 @@ class OptionGroupVariable : public OptionGroup {
public:
OptionGroupVariable(bool show_frame_options);
- ~OptionGroupVariable() override;
+ ~OptionGroupVariable() override = default;
llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
diff --git a/lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h b/lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h
index 054af4f1ce07..33818043cf63 100644
--- a/lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h
+++ b/lldb/include/lldb/Interpreter/OptionGroupWatchpoint.h
@@ -17,9 +17,9 @@ namespace lldb_private {
class OptionGroupWatchpoint : public OptionGroup {
public:
- OptionGroupWatchpoint();
+ OptionGroupWatchpoint() = default;
- ~OptionGroupWatchpoint() override;
+ ~OptionGroupWatchpoint() override = default;
static bool IsWatchSizeSupported(uint32_t watch_size);
diff --git a/lldb/include/lldb/Interpreter/OptionValueArch.h b/lldb/include/lldb/Interpreter/OptionValueArch.h
index 5047db775fc2..d079b3896531 100644
--- a/lldb/include/lldb/Interpreter/OptionValueArch.h
+++ b/lldb/include/lldb/Interpreter/OptionValueArch.h
@@ -17,7 +17,7 @@ namespace lldb_private {
class OptionValueArch : public OptionValue {
public:
- OptionValueArch() : OptionValue(), m_current_value(), m_default_value() {}
+ OptionValueArch() = default;
OptionValueArch(const char *triple)
: OptionValue(), m_current_value(triple), m_default_value() {
@@ -31,7 +31,7 @@ class OptionValueArch : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueArch() override {}
+ ~OptionValueArch() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueArgs.h b/lldb/include/lldb/Interpreter/OptionValueArgs.h
index 25f7fdde0bf3..2ef6ca5573e9 100644
--- a/lldb/include/lldb/Interpreter/OptionValueArgs.h
+++ b/lldb/include/lldb/Interpreter/OptionValueArgs.h
@@ -19,7 +19,7 @@ class OptionValueArgs : public OptionValueArray {
: OptionValueArray(
OptionValue::ConvertTypeToMask(OptionValue::eTypeString)) {}
- ~OptionValueArgs() override {}
+ ~OptionValueArgs() override = default;
size_t GetArgs(Args &args);
diff --git a/lldb/include/lldb/Interpreter/OptionValueArray.h b/lldb/include/lldb/Interpreter/OptionValueArray.h
index 14bc28404ec3..44bde8ee8699 100644
--- a/lldb/include/lldb/Interpreter/OptionValueArray.h
+++ b/lldb/include/lldb/Interpreter/OptionValueArray.h
@@ -20,7 +20,7 @@ class OptionValueArray : public OptionValue {
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) {}
- ~OptionValueArray() override {}
+ ~OptionValueArray() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueBoolean.h b/lldb/include/lldb/Interpreter/OptionValueBoolean.h
index 6b58eb94b826..d0eb4362d466 100644
--- a/lldb/include/lldb/Interpreter/OptionValueBoolean.h
+++ b/lldb/include/lldb/Interpreter/OptionValueBoolean.h
@@ -21,7 +21,7 @@ class OptionValueBoolean : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueBoolean() override {}
+ ~OptionValueBoolean() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueChar.h b/lldb/include/lldb/Interpreter/OptionValueChar.h
index b5b39b77b9b7..f3fd28104067 100644
--- a/lldb/include/lldb/Interpreter/OptionValueChar.h
+++ b/lldb/include/lldb/Interpreter/OptionValueChar.h
@@ -22,7 +22,7 @@ class OptionValueChar : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueChar() override {}
+ ~OptionValueChar() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueDictionary.h b/lldb/include/lldb/Interpreter/OptionValueDictionary.h
index dab1c3ea0c1c..e645f32cb800 100644
--- a/lldb/include/lldb/Interpreter/OptionValueDictionary.h
+++ b/lldb/include/lldb/Interpreter/OptionValueDictionary.h
@@ -22,7 +22,7 @@ class OptionValueDictionary : public OptionValue {
: OptionValue(), m_type_mask(type_mask), m_values(),
m_raw_value_dump(raw_value_dump) {}
- ~OptionValueDictionary() override {}
+ ~OptionValueDictionary() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueEnumeration.h b/lldb/include/lldb/Interpreter/OptionValueEnumeration.h
index 5ef6fa54ab82..0fe70193dece 100644
--- a/lldb/include/lldb/Interpreter/OptionValueEnumeration.h
+++ b/lldb/include/lldb/Interpreter/OptionValueEnumeration.h
@@ -31,7 +31,7 @@ class OptionValueEnumeration : public OptionValue {
OptionValueEnumeration(const OptionEnumValues &enumerators, enum_type value);
- ~OptionValueEnumeration() override;
+ ~OptionValueEnumeration() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueFileColonLine.h b/lldb/include/lldb/Interpreter/OptionValueFileColonLine.h
index b3bb1f0e7ca2..86fd0d5aec2c 100644
--- a/lldb/include/lldb/Interpreter/OptionValueFileColonLine.h
+++ b/lldb/include/lldb/Interpreter/OptionValueFileColonLine.h
@@ -21,7 +21,7 @@ class OptionValueFileColonLine : public OptionValue {
OptionValueFileColonLine();
OptionValueFileColonLine(const llvm::StringRef input);
- ~OptionValueFileColonLine() override {}
+ ~OptionValueFileColonLine() override = default;
OptionValue::Type GetType() const override { return eTypeFileLineColumn; }
diff --git a/lldb/include/lldb/Interpreter/OptionValueFileSpec.h b/lldb/include/lldb/Interpreter/OptionValueFileSpec.h
index a71858674c0a..4168e4b1b542 100644
--- a/lldb/include/lldb/Interpreter/OptionValueFileSpec.h
+++ b/lldb/include/lldb/Interpreter/OptionValueFileSpec.h
@@ -25,7 +25,7 @@ class OptionValueFileSpec : public OptionValue {
OptionValueFileSpec(const FileSpec ¤t_value,
const FileSpec &default_value, bool resolve = true);
- ~OptionValueFileSpec() override {}
+ ~OptionValueFileSpec() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueFileSpecList.h b/lldb/include/lldb/Interpreter/OptionValueFileSpecList.h
index dcf926fca8d8..b2dc11b7745a 100644
--- a/lldb/include/lldb/Interpreter/OptionValueFileSpecList.h
+++ b/lldb/include/lldb/Interpreter/OptionValueFileSpecList.h
@@ -18,12 +18,12 @@ namespace lldb_private {
class OptionValueFileSpecList : public OptionValue {
public:
- OptionValueFileSpecList() : OptionValue(), m_current_value() {}
+ OptionValueFileSpecList() = default;
OptionValueFileSpecList(const FileSpecList ¤t_value)
: OptionValue(), m_current_value(current_value) {}
- ~OptionValueFileSpecList() override {}
+ ~OptionValueFileSpecList() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueFormat.h b/lldb/include/lldb/Interpreter/OptionValueFormat.h
index 9241ba6bb9a7..eb80f09bb092 100644
--- a/lldb/include/lldb/Interpreter/OptionValueFormat.h
+++ b/lldb/include/lldb/Interpreter/OptionValueFormat.h
@@ -22,7 +22,7 @@ class OptionValueFormat : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueFormat() override {}
+ ~OptionValueFormat() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueFormatEntity.h b/lldb/include/lldb/Interpreter/OptionValueFormatEntity.h
index a29b7f4044b4..4100ee2bc2ef 100644
--- a/lldb/include/lldb/Interpreter/OptionValueFormatEntity.h
+++ b/lldb/include/lldb/Interpreter/OptionValueFormatEntity.h
@@ -18,7 +18,7 @@ class OptionValueFormatEntity : public OptionValue {
public:
OptionValueFormatEntity(const char *default_format);
- ~OptionValueFormatEntity() override {}
+ ~OptionValueFormatEntity() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueLanguage.h b/lldb/include/lldb/Interpreter/OptionValueLanguage.h
index bf86f3c371cf..bfe953a53c98 100644
--- a/lldb/include/lldb/Interpreter/OptionValueLanguage.h
+++ b/lldb/include/lldb/Interpreter/OptionValueLanguage.h
@@ -25,7 +25,7 @@ class OptionValueLanguage : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueLanguage() override {}
+ ~OptionValueLanguage() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValuePathMappings.h b/lldb/include/lldb/Interpreter/OptionValuePathMappings.h
index 8f58d5d935e7..e8af4bb23535 100644
--- a/lldb/include/lldb/Interpreter/OptionValuePathMappings.h
+++ b/lldb/include/lldb/Interpreter/OptionValuePathMappings.h
@@ -19,7 +19,7 @@ class OptionValuePathMappings : public OptionValue {
OptionValuePathMappings(bool notify_changes)
: OptionValue(), m_path_mappings(), m_notify_changes(notify_changes) {}
- ~OptionValuePathMappings() override {}
+ ~OptionValuePathMappings() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/OptionValueProperties.h b/lldb/include/lldb/Interpreter/OptionValueProperties.h
index d60afdeb46fb..d17f123ce474 100644
--- a/lldb/include/lldb/Interpreter/OptionValueProperties.h
+++ b/lldb/include/lldb/Interpreter/OptionValueProperties.h
@@ -23,8 +23,7 @@ class OptionValueProperties
: public OptionValue,
public std::enable_shared_from_this<OptionValueProperties> {
public:
- OptionValueProperties()
- : OptionValue(), m_name(), m_properties(), m_name_to_index() {}
+ OptionValueProperties() = default;
OptionValueProperties(ConstString name);
diff --git a/lldb/include/lldb/Interpreter/OptionValueSInt64.h b/lldb/include/lldb/Interpreter/OptionValueSInt64.h
index 2faea04d07f9..625193f87583 100644
--- a/lldb/include/lldb/Interpreter/OptionValueSInt64.h
+++ b/lldb/include/lldb/Interpreter/OptionValueSInt64.h
@@ -16,9 +16,7 @@ namespace lldb_private {
class OptionValueSInt64 : public OptionValue {
public:
- OptionValueSInt64()
- : OptionValue(), m_current_value(0), m_default_value(0),
- m_min_value(INT64_MIN), m_max_value(INT64_MAX) {}
+ OptionValueSInt64() = default;
OptionValueSInt64(int64_t value)
: OptionValue(), m_current_value(value), m_default_value(value),
@@ -29,12 +27,9 @@ class OptionValueSInt64 : public OptionValue {
m_default_value(default_value), m_min_value(INT64_MIN),
m_max_value(INT64_MAX) {}
- OptionValueSInt64(const OptionValueSInt64 &rhs)
- : OptionValue(rhs), m_current_value(rhs.m_current_value),
- m_default_value(rhs.m_default_value), m_min_value(rhs.m_min_value),
- m_max_value(rhs.m_max_value) {}
+ OptionValueSInt64(const OptionValueSInt64 &rhs) = default;
- ~OptionValueSInt64() override {}
+ ~OptionValueSInt64() override = default;
// Virtual subclass pure virtual overrides
@@ -90,10 +85,10 @@ class OptionValueSInt64 : public OptionValue {
int64_t GetMaximumValue() const { return m_max_value; }
protected:
- int64_t m_current_value;
- int64_t m_default_value;
- int64_t m_min_value;
- int64_t m_max_value;
+ int64_t m_current_value = 0;
+ int64_t m_default_value = 0;
+ int64_t m_min_value = INT64_MIN;
+ int64_t m_max_value = INT64_MAX;
};
} // namespace lldb_private
diff --git a/lldb/include/lldb/Interpreter/OptionValueString.h b/lldb/include/lldb/Interpreter/OptionValueString.h
index c592ff1281eb..4d78cbb64e5a 100644
--- a/lldb/include/lldb/Interpreter/OptionValueString.h
+++ b/lldb/include/lldb/Interpreter/OptionValueString.h
@@ -23,9 +23,7 @@ class OptionValueString : public OptionValue {
enum Options { eOptionEncodeCharacterEscapeSequences = (1u << 0) };
- OptionValueString()
- : OptionValue(), m_current_value(), m_default_value(), m_options(),
- m_validator(), m_validator_baton() {}
+ OptionValueString() = default;
OptionValueString(ValidatorCallback validator, void *baton = nullptr)
: OptionValue(), m_current_value(), m_default_value(), m_options(),
@@ -125,8 +123,8 @@ class OptionValueString : public OptionValue {
std::string m_current_value;
std::string m_default_value;
Flags m_options;
- ValidatorCallback m_validator;
- void *m_validator_baton;
+ ValidatorCallback m_validator = nullptr;
+ void *m_validator_baton = nullptr;
};
} // namespace lldb_private
diff --git a/lldb/include/lldb/Interpreter/OptionValueUInt64.h b/lldb/include/lldb/Interpreter/OptionValueUInt64.h
index 47162334fb65..bee8ff5117a9 100644
--- a/lldb/include/lldb/Interpreter/OptionValueUInt64.h
+++ b/lldb/include/lldb/Interpreter/OptionValueUInt64.h
@@ -16,7 +16,7 @@ namespace lldb_private {
class OptionValueUInt64 : public OptionValue {
public:
- OptionValueUInt64() : OptionValue(), m_current_value(0), m_default_value(0) {}
+ OptionValueUInt64() = default;
OptionValueUInt64(uint64_t value)
: OptionValue(), m_current_value(value), m_default_value(value) {}
@@ -25,7 +25,7 @@ class OptionValueUInt64 : public OptionValue {
: OptionValue(), m_current_value(current_value),
m_default_value(default_value) {}
- ~OptionValueUInt64() override {}
+ ~OptionValueUInt64() override = default;
// Decode a uint64_t from "value_cstr" return a OptionValueUInt64 object
// inside of a lldb::OptionValueSP object if all goes well. If the string
@@ -68,8 +68,8 @@ class OptionValueUInt64 : public OptionValue {
void SetDefaultValue(uint64_t value) { m_default_value = value; }
protected:
- uint64_t m_current_value;
- uint64_t m_default_value;
+ uint64_t m_current_value = 0;
+ uint64_t m_default_value = 0;
};
} // namespace lldb_private
diff --git a/lldb/include/lldb/Interpreter/OptionValueUUID.h b/lldb/include/lldb/Interpreter/OptionValueUUID.h
index 822dc0019851..1673078344f5 100644
--- a/lldb/include/lldb/Interpreter/OptionValueUUID.h
+++ b/lldb/include/lldb/Interpreter/OptionValueUUID.h
@@ -16,11 +16,11 @@ namespace lldb_private {
class OptionValueUUID : public OptionValue {
public:
- OptionValueUUID() : OptionValue(), m_uuid() {}
+ OptionValueUUID() = default;
OptionValueUUID(const UUID &uuid) : OptionValue(), m_uuid(uuid) {}
- ~OptionValueUUID() override {}
+ ~OptionValueUUID() override = default;
// Virtual subclass pure virtual overrides
diff --git a/lldb/include/lldb/Interpreter/ScriptInterpreter.h b/lldb/include/lldb/Interpreter/ScriptInterpreter.h
index 4abd1ca68167..275d61a63f05 100644
--- a/lldb/include/lldb/Interpreter/ScriptInterpreter.h
+++ b/lldb/include/lldb/Interpreter/ScriptInterpreter.h
@@ -85,7 +85,7 @@ class ScriptInterpreter : public PluginInterface {
ScriptInterpreter(Debugger &debugger, lldb::ScriptLanguage script_lang);
- ~ScriptInterpreter() override;
+ ~ScriptInterpreter() override = default;
struct ExecuteScriptOptions {
public:
diff --git a/lldb/source/Interpreter/CommandHistory.cpp b/lldb/source/Interpreter/CommandHistory.cpp
index 9c7919ecc41f..ffdcbbfb4831 100644
--- a/lldb/source/Interpreter/CommandHistory.cpp
+++ b/lldb/source/Interpreter/CommandHistory.cpp
@@ -13,10 +13,6 @@
using namespace lldb;
using namespace lldb_private;
-CommandHistory::CommandHistory() : m_mutex(), m_history() {}
-
-CommandHistory::~CommandHistory() {}
-
size_t CommandHistory::GetSize() const {
std::lock_guard<std::recursive_mutex> guard(m_mutex);
return m_history.size();
diff --git a/lldb/source/Interpreter/CommandObject.cpp b/lldb/source/Interpreter/CommandObject.cpp
index 71adf8c39f1b..9d27de46e382 100644
--- a/lldb/source/Interpreter/CommandObject.cpp
+++ b/lldb/source/Interpreter/CommandObject.cpp
@@ -49,8 +49,6 @@ CommandObject::CommandObject(CommandInterpreter &interpreter,
m_cmd_syntax = std::string(syntax);
}
-CommandObject::~CommandObject() {}
-
Debugger &CommandObject::GetDebugger() { return m_interpreter.GetDebugger(); }
llvm::StringRef CommandObject::GetHelp() { return m_cmd_help_short; }
diff --git a/lldb/source/Interpreter/CommandReturnObject.cpp b/lldb/source/Interpreter/CommandReturnObject.cpp
index 441a8e08e6bc..77d94bd9389c 100644
--- a/lldb/source/Interpreter/CommandReturnObject.cpp
+++ b/lldb/source/Interpreter/CommandReturnObject.cpp
@@ -45,8 +45,6 @@ CommandReturnObject::CommandReturnObject(bool colors)
m_status(eReturnStatusStarted), m_did_change_process_state(false),
m_interactive(true) {}
-CommandReturnObject::~CommandReturnObject() {}
-
void CommandReturnObject::AppendErrorWithFormat(const char *format, ...) {
if (!format)
return;
diff --git a/lldb/source/Interpreter/OptionGroupArchitecture.cpp b/lldb/source/Interpreter/OptionGroupArchitecture.cpp
index baca1c6e8068..00541b7198d2 100644
--- a/lldb/source/Interpreter/OptionGroupArchitecture.cpp
+++ b/lldb/source/Interpreter/OptionGroupArchitecture.cpp
@@ -13,10 +13,6 @@
using namespace lldb;
using namespace lldb_private;
-OptionGroupArchitecture::OptionGroupArchitecture() : m_arch_str() {}
-
-OptionGroupArchitecture::~OptionGroupArchitecture() {}
-
static constexpr OptionDefinition g_option_table[] = {
{LLDB_OPT_SET_1, false, "arch", 'a', OptionParser::eRequiredArgument,
nullptr, {}, 0, eArgTypeArchitecture,
diff --git a/lldb/source/Interpreter/OptionGroupBoolean.cpp b/lldb/source/Interpreter/OptionGroupBoolean.cpp
index 3482e784ca0c..3f73893fca96 100644
--- a/lldb/source/Interpreter/OptionGroupBoolean.cpp
+++ b/lldb/source/Interpreter/OptionGroupBoolean.cpp
@@ -33,8 +33,6 @@ OptionGroupBoolean::OptionGroupBoolean(uint32_t usage_mask, bool required,
m_option_definition.usage_text = usage_text;
}
-OptionGroupBoolean::~OptionGroupBoolean() {}
-
Status OptionGroupBoolean::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_value,
ExecutionContext *execution_context) {
diff --git a/lldb/source/Interpreter/OptionGroupFile.cpp b/lldb/source/Interpreter/OptionGroupFile.cpp
index 9d9be5b6f178..8be4b18a2134 100644
--- a/lldb/source/Interpreter/OptionGroupFile.cpp
+++ b/lldb/source/Interpreter/OptionGroupFile.cpp
@@ -31,8 +31,6 @@ OptionGroupFile::OptionGroupFile(uint32_t usage_mask, bool required,
m_option_definition.usage_text = usage_text;
}
-OptionGroupFile::~OptionGroupFile() {}
-
Status OptionGroupFile::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_arg,
ExecutionContext *execution_context) {
diff --git a/lldb/source/Interpreter/OptionGroupFormat.cpp b/lldb/source/Interpreter/OptionGroupFormat.cpp
index 0052f72b0550..1cc5e70282c1 100644
--- a/lldb/source/Interpreter/OptionGroupFormat.cpp
+++ b/lldb/source/Interpreter/OptionGroupFormat.cpp
@@ -24,8 +24,6 @@ OptionGroupFormat::OptionGroupFormat(lldb::Format default_format,
m_count(default_count, default_count), m_prev_gdb_format('x'),
m_prev_gdb_size('w') {}
-OptionGroupFormat::~OptionGroupFormat() {}
-
static constexpr OptionDefinition g_option_table[] = {
{LLDB_OPT_SET_1, false, "format", 'f', OptionParser::eRequiredArgument,
nullptr, {}, 0, eArgTypeFormat,
diff --git a/lldb/source/Interpreter/OptionGroupOutputFile.cpp b/lldb/source/Interpreter/OptionGroupOutputFile.cpp
index 65105c3e0180..1f3050834ec3 100644
--- a/lldb/source/Interpreter/OptionGroupOutputFile.cpp
+++ b/lldb/source/Interpreter/OptionGroupOutputFile.cpp
@@ -16,8 +16,6 @@ using namespace lldb_private;
OptionGroupOutputFile::OptionGroupOutputFile()
: m_file(), m_append(false, false) {}
-OptionGroupOutputFile::~OptionGroupOutputFile() {}
-
static const uint32_t SHORT_OPTION_APND = 0x61706e64; // 'apnd'
static constexpr OptionDefinition g_option_table[] = {
diff --git a/lldb/source/Interpreter/OptionGroupPythonClassWithDict.cpp b/lldb/source/Interpreter/OptionGroupPythonClassWithDict.cpp
index 217dab2ef63b..e768febebb89 100644
--- a/lldb/source/Interpreter/OptionGroupPythonClassWithDict.cpp
+++ b/lldb/source/Interpreter/OptionGroupPythonClassWithDict.cpp
@@ -81,8 +81,6 @@ OptionGroupPythonClassWithDict::OptionGroupPythonClassWithDict
}
-OptionGroupPythonClassWithDict::~OptionGroupPythonClassWithDict() {}
-
Status OptionGroupPythonClassWithDict::SetOptionValue(
uint32_t option_idx,
llvm::StringRef option_arg,
diff --git a/lldb/source/Interpreter/OptionGroupString.cpp b/lldb/source/Interpreter/OptionGroupString.cpp
index c9f78eb953f4..75faaac9f6dd 100644
--- a/lldb/source/Interpreter/OptionGroupString.cpp
+++ b/lldb/source/Interpreter/OptionGroupString.cpp
@@ -32,8 +32,6 @@ OptionGroupString::OptionGroupString(uint32_t usage_mask, bool required,
m_option_definition.usage_text = usage_text;
}
-OptionGroupString::~OptionGroupString() {}
-
Status OptionGroupString::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_arg,
ExecutionContext *execution_context) {
diff --git a/lldb/source/Interpreter/OptionGroupUInt64.cpp b/lldb/source/Interpreter/OptionGroupUInt64.cpp
index 309855d4718c..486941a7555a 100644
--- a/lldb/source/Interpreter/OptionGroupUInt64.cpp
+++ b/lldb/source/Interpreter/OptionGroupUInt64.cpp
@@ -32,8 +32,6 @@ OptionGroupUInt64::OptionGroupUInt64(uint32_t usage_mask, bool required,
m_option_definition.usage_text = usage_text;
}
-OptionGroupUInt64::~OptionGroupUInt64() {}
-
Status OptionGroupUInt64::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_arg,
ExecutionContext *execution_context) {
diff --git a/lldb/source/Interpreter/OptionGroupUUID.cpp b/lldb/source/Interpreter/OptionGroupUUID.cpp
index dc6f4139896f..5b4c24a0a32b 100644
--- a/lldb/source/Interpreter/OptionGroupUUID.cpp
+++ b/lldb/source/Interpreter/OptionGroupUUID.cpp
@@ -13,10 +13,6 @@
using namespace lldb;
using namespace lldb_private;
-OptionGroupUUID::OptionGroupUUID() : m_uuid() {}
-
-OptionGroupUUID::~OptionGroupUUID() {}
-
static constexpr OptionDefinition g_option_table[] = {
{LLDB_OPT_SET_1, false, "uuid", 'u', OptionParser::eRequiredArgument,
nullptr, {}, 0, eArgTypeModuleUUID, "A module UUID value."},
diff --git a/lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp b/lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp
index e0401f8987ad..04861b539650 100644
--- a/lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp
+++ b/lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp
@@ -19,10 +19,6 @@
using namespace lldb;
using namespace lldb_private;
-OptionGroupValueObjectDisplay::OptionGroupValueObjectDisplay() {}
-
-OptionGroupValueObjectDisplay::~OptionGroupValueObjectDisplay() {}
-
static const OptionDefinition g_option_table[] = {
{LLDB_OPT_SET_1, false, "dynamic-type", 'd',
OptionParser::eRequiredArgument, nullptr, GetDynamicValueTypes(), 0,
diff --git a/lldb/source/Interpreter/OptionGroupVariable.cpp b/lldb/source/Interpreter/OptionGroupVariable.cpp
index 9f57dbbd073e..2451a3e96478 100644
--- a/lldb/source/Interpreter/OptionGroupVariable.cpp
+++ b/lldb/source/Interpreter/OptionGroupVariable.cpp
@@ -70,8 +70,6 @@ OptionGroupVariable::OptionGroupVariable(bool show_frame_options)
: OptionGroup(), include_frame_options(show_frame_options),
summary(ValidateNamedSummary), summary_string(ValidateSummaryString) {}
-OptionGroupVariable::~OptionGroupVariable() {}
-
Status
OptionGroupVariable::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_arg,
diff --git a/lldb/source/Interpreter/OptionGroupWatchpoint.cpp b/lldb/source/Interpreter/OptionGroupWatchpoint.cpp
index 07013b5b78fe..eb9842add28c 100644
--- a/lldb/source/Interpreter/OptionGroupWatchpoint.cpp
+++ b/lldb/source/Interpreter/OptionGroupWatchpoint.cpp
@@ -74,10 +74,6 @@ bool OptionGroupWatchpoint::IsWatchSizeSupported(uint32_t watch_size) {
return false;
}
-OptionGroupWatchpoint::OptionGroupWatchpoint() : OptionGroup() {}
-
-OptionGroupWatchpoint::~OptionGroupWatchpoint() {}
-
Status
OptionGroupWatchpoint::SetOptionValue(uint32_t option_idx,
llvm::StringRef option_arg,
diff --git a/lldb/source/Interpreter/OptionValueEnumeration.cpp b/lldb/source/Interpreter/OptionValueEnumeration.cpp
index 9a1e08d4fba0..8fcd8db1ee96 100644
--- a/lldb/source/Interpreter/OptionValueEnumeration.cpp
+++ b/lldb/source/Interpreter/OptionValueEnumeration.cpp
@@ -20,8 +20,6 @@ OptionValueEnumeration::OptionValueEnumeration(
SetEnumerations(enumerators);
}
-OptionValueEnumeration::~OptionValueEnumeration() {}
-
void OptionValueEnumeration::DumpValue(const ExecutionContext *exe_ctx,
Stream &strm, uint32_t dump_mask) {
if (dump_mask & eDumpOptionType)
diff --git a/lldb/source/Interpreter/Options.cpp b/lldb/source/Interpreter/Options.cpp
index 9ecc9e229e0e..5d3864dbfff3 100644
--- a/lldb/source/Interpreter/Options.cpp
+++ b/lldb/source/Interpreter/Options.cpp
@@ -27,7 +27,7 @@ using namespace lldb_private;
// Options
Options::Options() : m_getopt_table() { BuildValidOptionSets(); }
-Options::~Options() {}
+Options::~Options() = default;
void Options::NotifyOptionParsingStarting(ExecutionContext *execution_context) {
m_seen_options.clear();
diff --git a/lldb/source/Interpreter/ScriptInterpreter.cpp b/lldb/source/Interpreter/ScriptInterpreter.cpp
index 013ed6aecb80..2c55d08497ab 100644
--- a/lldb/source/Interpreter/ScriptInterpreter.cpp
+++ b/lldb/source/Interpreter/ScriptInterpreter.cpp
@@ -30,8 +30,6 @@ ScriptInterpreter::ScriptInterpreter(Debugger &debugger,
lldb::ScriptLanguage script_lang)
: m_debugger(debugger), m_script_lang(script_lang) {}
-ScriptInterpreter::~ScriptInterpreter() {}
-
void ScriptInterpreter::CollectDataForBreakpointCommandCallback(
std::vector<BreakpointOptions *> &bp_options_vec,
CommandReturnObject &result) {
More information about the lldb-commits
mailing list