mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-01-15 16:33:15 -03:00
VolumeFileBlobReader: Define default destructor in source file
Fix an error generated by Clang from the destructor of `std::unique_ptr<FileInfo> m_file_info` when setting the standard version to c++23: `invalid application of 'sizeof' to an incomplete type 'DiscIO::FileInfo'`
This commit is contained in:
@@ -33,6 +33,11 @@ VolumeFileBlobReader::VolumeFileBlobReader(const Volume& volume, const Partition
|
||||
{
|
||||
}
|
||||
|
||||
// This is defined here instead of the header so that the definition of FileInfo is visible when
|
||||
// m_file_info is destroyed, preventing a compile error caused by calling unique_ptr's destructor
|
||||
// with an incomplete type.
|
||||
VolumeFileBlobReader::~VolumeFileBlobReader() = default;
|
||||
|
||||
std::unique_ptr<BlobReader> VolumeFileBlobReader::CopyReader() const
|
||||
{
|
||||
ASSERT_MSG(DISCIO, false, "Unimplemented");
|
||||
|
||||
@@ -20,6 +20,7 @@ class VolumeFileBlobReader final : public BlobReader
|
||||
public:
|
||||
static std::unique_ptr<VolumeFileBlobReader>
|
||||
Create(const Volume& volume, const Partition& partition, std::string_view file_path);
|
||||
~VolumeFileBlobReader();
|
||||
|
||||
BlobType GetBlobType() const override { return BlobType::PLAIN; }
|
||||
std::unique_ptr<BlobReader> CopyReader() const override;
|
||||
|
||||
Reference in New Issue
Block a user