Skip to content

Commit

Permalink
clang-tidy: add the last remaining functions
Browse files Browse the repository at this point in the history
Found with: cppcoreguidelines-special-member-functions

Mostly adding deleted functions. Added a using declaration in one case
for simplicity.

Signed-off-by: Rosen Penev <[email protected]>
  • Loading branch information
neheb committed Feb 2, 2024
1 parent 62acbcd commit 4a1a8c4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
10 changes: 7 additions & 3 deletions matroska/KaxBlock.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ class MATROSKA_DLL_API SimpleDataBuffer : public DataBuffer {
{}
~SimpleDataBuffer() override = default;

SimpleDataBuffer& operator=(const SimpleDataBuffer &) = delete;

DataBuffer * Clone() override {return new SimpleDataBuffer(*this);}

protected:
Expand Down Expand Up @@ -179,10 +181,9 @@ DECLARE_MKX_MASTER(KaxBlockGroup)

class MATROSKA_DLL_API KaxInternalBlock : public libebml::EbmlBinary {
public:
KaxInternalBlock(const libebml::EbmlCallbacks & classInfo)
:libebml::EbmlBinary(classInfo)
{}
using EbmlBinary::EbmlBinary;
KaxInternalBlock(const KaxInternalBlock & ElementToClone);
KaxInternalBlock& operator=(const KaxInternalBlock &) = delete;
~KaxInternalBlock() override;
bool SizeIsValid(std::uint64_t size) const override
{
Expand Down Expand Up @@ -311,6 +312,9 @@ class MATROSKA_DLL_API KaxBlockBlob {
delete Block.group;
}

KaxBlockBlob(const KaxBlockBlob&) = delete;
KaxBlockBlob& operator=(const KaxBlockBlob&) = delete;

operator KaxBlockGroup &() const;
operator KaxSimpleBlock &() const;
operator KaxInternalBlock &() const;
Expand Down
3 changes: 3 additions & 0 deletions matroska/KaxCues.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ DECLARE_MKX_MASTER(KaxCues)
public:
~KaxCues() override;

KaxCues(const KaxCues&) = default;
KaxCues& operator=(const KaxCues&) = delete;

//bool AddBlockGroup(const KaxBlockGroup & BlockReference); // deprecated
bool AddBlockBlob(const KaxBlockBlob & BlockReference);

Expand Down

0 comments on commit 4a1a8c4

Please sign in to comment.