mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-31 00:32:53 +00:00
NANDContentLoader: Make CNANDContentData's Get function return by non-const value
const specifiers like this are practically pointless and can inhibit move construction.
This commit is contained in:
parent
4c004b6dc9
commit
b1ffa74043
@ -107,7 +107,7 @@ void CNANDContentDataFile::Open()
|
|||||||
{
|
{
|
||||||
EnsureOpen();
|
EnsureOpen();
|
||||||
}
|
}
|
||||||
const std::vector<u8> CNANDContentDataFile::Get()
|
std::vector<u8> CNANDContentDataFile::Get()
|
||||||
{
|
{
|
||||||
std::vector<u8> result;
|
std::vector<u8> result;
|
||||||
EnsureOpen();
|
EnsureOpen();
|
||||||
|
@ -27,7 +27,7 @@ class CNANDContentData
|
|||||||
public:
|
public:
|
||||||
virtual ~CNANDContentData() = 0;
|
virtual ~CNANDContentData() = 0;
|
||||||
virtual void Open(){};
|
virtual void Open(){};
|
||||||
virtual const std::vector<u8> Get() = 0;
|
virtual std::vector<u8> Get() = 0;
|
||||||
virtual bool GetRange(u32 start, u32 size, u8* buffer) = 0;
|
virtual bool GetRange(u32 start, u32 size, u8* buffer) = 0;
|
||||||
virtual void Close(){};
|
virtual void Close(){};
|
||||||
};
|
};
|
||||||
@ -38,7 +38,7 @@ public:
|
|||||||
CNANDContentDataFile(const std::string& filename) : m_filename(filename){};
|
CNANDContentDataFile(const std::string& filename) : m_filename(filename){};
|
||||||
|
|
||||||
void Open() override;
|
void Open() override;
|
||||||
const std::vector<u8> Get() override;
|
std::vector<u8> Get() override;
|
||||||
bool GetRange(u32 start, u32 size, u8* buffer) override;
|
bool GetRange(u32 start, u32 size, u8* buffer) override;
|
||||||
void Close() override;
|
void Close() override;
|
||||||
|
|
||||||
@ -53,7 +53,7 @@ class CNANDContentDataBuffer final : public CNANDContentData
|
|||||||
public:
|
public:
|
||||||
CNANDContentDataBuffer(const std::vector<u8>& buffer) : m_buffer(buffer){};
|
CNANDContentDataBuffer(const std::vector<u8>& buffer) : m_buffer(buffer){};
|
||||||
|
|
||||||
const std::vector<u8> Get() override { return m_buffer; };
|
std::vector<u8> Get() override { return m_buffer; };
|
||||||
bool GetRange(u32 start, u32 size, u8* buffer) override;
|
bool GetRange(u32 start, u32 size, u8* buffer) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user