diff options
author | Ben Wiederhake <BenWiederhake.GitHub@gmx.de> | 2021-02-28 14:42:08 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-02-28 18:09:12 +0100 |
commit | 860a3bbce342067069d4c7d2e4396a667ff324fe (patch) | |
tree | 8110f5d9a7293a4371205ffffd7c8717b8a29471 /Kernel/Storage | |
parent | 2dea887e8fe43438cd5005820515fc21a1e4521c (diff) | |
download | serenity-860a3bbce342067069d4c7d2e4396a667ff324fe.zip |
Kernel: Use default con/de-structors
This may seem like a no-op change, however it shrinks down the Kernel by a bit:
.text -432
.unmap_after_init -60
.data -480
.debug_info -673
.debug_aranges 8
.debug_ranges -232
.debug_line -558
.debug_str -308
.debug_frame -40
With '= default', the compiler can do more inlining, hence the savings.
I intentionally omitted some opportunities for '= default', because they
would increase the Kernel size.
Diffstat (limited to 'Kernel/Storage')
-rw-r--r-- | Kernel/Storage/Partition/GUIDPartitionTable.h | 3 | ||||
-rw-r--r-- | Kernel/Storage/Partition/PartitionTable.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/Kernel/Storage/Partition/GUIDPartitionTable.h b/Kernel/Storage/Partition/GUIDPartitionTable.h index 3988324e04..5fbfe3d976 100644 --- a/Kernel/Storage/Partition/GUIDPartitionTable.h +++ b/Kernel/Storage/Partition/GUIDPartitionTable.h @@ -37,7 +37,8 @@ namespace Kernel { struct GUIDPartitionHeader; class GUIDPartitionTable final : public MBRPartitionTable { public: - virtual ~GUIDPartitionTable() {}; + virtual ~GUIDPartitionTable() = default; + ; static Result<NonnullOwnPtr<GUIDPartitionTable>, PartitionTable::Error> try_to_initialize(const StorageDevice&); explicit GUIDPartitionTable(const StorageDevice&); diff --git a/Kernel/Storage/Partition/PartitionTable.h b/Kernel/Storage/Partition/PartitionTable.h index 324284492e..8c7ece095b 100644 --- a/Kernel/Storage/Partition/PartitionTable.h +++ b/Kernel/Storage/Partition/PartitionTable.h @@ -52,7 +52,7 @@ public: Optional<DiskPartitionMetadata> partition(unsigned index); size_t partitions_count() const { return m_partitions.size(); } virtual Type type() const = 0; - virtual ~PartitionTable() { } + virtual ~PartitionTable() = default; virtual bool is_valid() const = 0; Vector<DiskPartitionMetadata> partitions() const { return m_partitions; } |