Common/Core: Minor rvalue reference related cleanups.
This commit is contained in:
1 parent
42c03c4dad
commit
732032cdb2
6 files changed
+12
-46
No files matched your search
@@ -79,11 +79,7 @@ bool operator!=(const Content& lhs, const Content& rhs)
|
||||
return !operator==(lhs, rhs);
|
||||
}
|
||||
|
||||
SignedBlobReader::SignedBlobReader(const std::vector<u8>& bytes) : m_bytes(bytes)
|
||||
{
|
||||
}
|
||||
|
||||
SignedBlobReader::SignedBlobReader(std::vector<u8>&& bytes) : m_bytes(std::move(bytes))
|
||||
SignedBlobReader::SignedBlobReader(std::vector<u8> bytes) : m_bytes(std::move(bytes))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -92,12 +88,7 @@ const std::vector<u8>& SignedBlobReader::GetBytes() const
|
||||
return m_bytes;
|
||||
}
|
||||
|
||||
void SignedBlobReader::SetBytes(const std::vector<u8>& bytes)
|
||||
{
|
||||
m_bytes = bytes;
|
||||
}
|
||||
|
||||
void SignedBlobReader::SetBytes(std::vector<u8>&& bytes)
|
||||
void SignedBlobReader::SetBytes(std::vector<u8> bytes)
|
||||
{
|
||||
m_bytes = std::move(bytes);
|
||||
}
|
||||
@@ -213,11 +204,7 @@ bool IsValidTMDSize(size_t size)
|
||||
return size <= 0x49e4;
|
||||
}
|
||||
|
||||
TMDReader::TMDReader(const std::vector<u8>& bytes) : SignedBlobReader(bytes)
|
||||
{
|
||||
}
|
||||
|
||||
TMDReader::TMDReader(std::vector<u8>&& bytes) : SignedBlobReader(std::move(bytes))
|
||||
TMDReader::TMDReader(std::vector<u8> bytes) : SignedBlobReader(std::move(bytes))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -376,11 +363,7 @@ bool TMDReader::FindContentById(u32 id, Content* content) const
|
||||
return false;
|
||||
}
|
||||
|
||||
TicketReader::TicketReader(const std::vector<u8>& bytes) : SignedBlobReader(bytes)
|
||||
{
|
||||
}
|
||||
|
||||
TicketReader::TicketReader(std::vector<u8>&& bytes) : SignedBlobReader(std::move(bytes))
|
||||
TicketReader::TicketReader(std::vector<u8> bytes) : SignedBlobReader(std::move(bytes))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -155,12 +155,10 @@ class SignedBlobReader
|
||||
{
|
||||
public:
|
||||
SignedBlobReader() = default;
|
||||
explicit SignedBlobReader(const std::vector<u8>& bytes);
|
||||
explicit SignedBlobReader(std::vector<u8>&& bytes);
|
||||
explicit SignedBlobReader(std::vector<u8> bytes);
|
||||
|
||||
const std::vector<u8>& GetBytes() const;
|
||||
void SetBytes(const std::vector<u8>& bytes);
|
||||
void SetBytes(std::vector<u8>&& bytes);
|
||||
void SetBytes(std::vector<u8> bytes);
|
||||
|
||||
/// Get the SHA1 hash for this signed blob (starting at the issuer).
|
||||
std::array<u8, 20> GetSha1() const;
|
||||
@@ -187,8 +185,7 @@ class TMDReader final : public SignedBlobReader
|
||||
{
|
||||
public:
|
||||
TMDReader() = default;
|
||||
explicit TMDReader(const std::vector<u8>& bytes);
|
||||
explicit TMDReader(std::vector<u8>&& bytes);
|
||||
explicit TMDReader(std::vector<u8> bytes);
|
||||
|
||||
bool IsValid() const;
|
||||
|
||||
@@ -224,8 +221,7 @@ class TicketReader final : public SignedBlobReader
|
||||
{
|
||||
public:
|
||||
TicketReader() = default;
|
||||
explicit TicketReader(const std::vector<u8>& bytes);
|
||||
explicit TicketReader(std::vector<u8>&& bytes);
|
||||
explicit TicketReader(std::vector<u8> bytes);
|
||||
|
||||
bool IsValid() const;
|
||||
|
||||
|
||||
Reference in new issue
Block a user