Commit 9ef1cf15 authored by Rosen Penev's avatar Rosen Penev

clang-tidy: default virtual destructors

Found with cppcoreguidelines-special-member-functions Signed-off-by: 's avatarRosen Penev <rosenp@gmail.com>
parent 679b3bc0
......@@ -35,7 +35,7 @@ class Encoder {
public:
explicit Encoder(bool _implements_tag) noexcept
:implements_tag(_implements_tag) {}
virtual ~Encoder() noexcept {}
virtual ~Encoder() noexcept = default;
bool ImplementsTag() const noexcept {
return implements_tag;
......@@ -111,7 +111,7 @@ public:
class PreparedEncoder {
public:
virtual ~PreparedEncoder() noexcept {}
virtual ~PreparedEncoder() noexcept = default;
/**
* Opens the object. You must call this prior to using it.
......
......@@ -36,7 +36,7 @@ protected:
}
public:
virtual ~Filter() noexcept {}
virtual ~Filter() noexcept = default;
/**
* Returns the #AudioFormat produced by FilterPCM().
......
......@@ -27,7 +27,7 @@ class Filter;
class PreparedFilter {
public:
virtual ~PreparedFilter() {}
virtual ~PreparedFilter() = default;
/**
* Opens the filter, preparing it for FilterPCM().
......
......@@ -57,7 +57,7 @@ public:
Mixer(const Mixer &) = delete;
virtual ~Mixer() {}
virtual ~Mixer() = default;
bool IsPlugin(const MixerPlugin &other) const noexcept {
return &plugin == &other;
......
......@@ -49,7 +49,7 @@ public:
/**
* Free instance data.
*/
virtual ~NeighborExplorer() noexcept {}
virtual ~NeighborExplorer() noexcept = default;
/**
* Start exploring the neighborhood.
......
......@@ -31,7 +31,7 @@ struct AudioFormat;
*/
class PcmResampler {
public:
virtual ~PcmResampler() {}
virtual ~PcmResampler() = default;
/**
* Opens the resampler, preparing it for Resample().
......
......@@ -30,7 +30,7 @@ class DetachedSong;
*/
class SongEnumerator {
public:
virtual ~SongEnumerator() noexcept {}
virtual ~SongEnumerator() noexcept = default;
/**
* Obtain the next song. Returns nullptr if there are no more
......
......@@ -31,7 +31,7 @@ using ISongFilterPtr = std::unique_ptr<ISongFilter>;
class ISongFilter {
public:
virtual ~ISongFilter() noexcept {}
virtual ~ISongFilter() noexcept = default;
virtual ISongFilterPtr Clone() const noexcept = 0;
......
......@@ -33,7 +33,7 @@ class StorageDirectoryReader {
public:
StorageDirectoryReader() = default;
StorageDirectoryReader(const StorageDirectoryReader &) = delete;
virtual ~StorageDirectoryReader() noexcept {}
virtual ~StorageDirectoryReader() noexcept = default;
virtual const char *Read() noexcept = 0;
......@@ -47,7 +47,7 @@ class Storage {
public:
Storage() = default;
Storage(const Storage &) = delete;
virtual ~Storage() noexcept {}
virtual ~Storage() noexcept = default;
/**
* Throws #std::runtime_error on error.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment