Switch atmosphere's build target to C++20. (#952)

* ams: update to build with gcc10/c++20

* remove mno-outline-atomics

* ams: take care of most TODO C++20s

* fusee/sept: update for gcc10

* whoosh, your code now uses pre-compiled headers

* make: dependency fixes
This commit is contained in:
SciresM
2020-05-11 15:02:10 -07:00
committed by GitHub
parent 17b6bcfd37
commit 3a1ccdd919
258 changed files with 723 additions and 804 deletions

View File

@@ -30,7 +30,7 @@ namespace ams::fssystem {
class PageList;
struct PageEntry { PageEntry *next; };
static_assert(std::is_pod<PageEntry>::value);
static_assert(util::is_pod<PageEntry>::value);
static_assert(sizeof(PageEntry) <= BlockSizeMin);
class PageList : public ::ams::fs::impl::Newable {

View File

@@ -35,7 +35,7 @@ namespace ams::fssystem {
Position next_dir;
Position next_file;
};
static_assert(std::is_pod<FindPosition>::value);
static_assert(util::is_pod<FindPosition>::value);
using DirectoryInfo = RomDirectoryInfo;
using FileInfo = RomFileInfo;
@@ -63,13 +63,13 @@ namespace ams::fssystem {
Position dir;
Position file;
};
static_assert(std::is_pod<RomDirectoryEntry>::value);
static_assert(util::is_pod<RomDirectoryEntry>::value);
struct RomFileEntry {
Position next;
FileInfo info;
};
static_assert(std::is_pod<RomFileEntry>::value);
static_assert(util::is_pod<RomFileEntry>::value);
static constexpr inline u32 MaxKeyLength = RomPathTool::MaxPathLength;
@@ -115,7 +115,7 @@ namespace ams::fssystem {
return RomPathTool::IsEqualPath(reinterpret_cast<const RomPathChar *>(aux_lhs), reinterpret_cast<const RomPathChar *>(aux_rhs), aux_lhs_size / sizeof(RomPathChar));
}
};
static_assert(std::is_pod<RomEntryKey>::value);
static_assert(util::is_pod<RomEntryKey>::value);
struct EntryKey {
RomEntryKey key;
@@ -132,7 +132,7 @@ namespace ams::fssystem {
return hash;
}
};
static_assert(std::is_pod<EntryKey>::value);
static_assert(util::is_pod<EntryKey>::value);
using DirectoryEntryMapTable = EntryMapTable<DirectoryBucketStorage, DirectoryEntryStorage, RomEntryKey, EntryKey, RomDirectoryEntry>;
using FileEntryMapTable = EntryMapTable<FileBucketStorage, FileEntryStorage, RomEntryKey, EntryKey, RomFileEntry>;

View File

@@ -37,7 +37,7 @@ namespace ams::fssystem {
BucketIndex ind;
Position pos;
};
static_assert(std::is_pod<FindIndex>::value);
static_assert(util::is_pod<FindIndex>::value);
private:
static constexpr inline Position InvalidPosition = ~Position();
@@ -47,7 +47,7 @@ namespace ams::fssystem {
Position next;
u32 size;
};
static_assert(std::is_pod<Element>::value);
static_assert(util::is_pod<Element>::value);
private:
s64 bucket_offset;
u32 bucket_count;

View File

@@ -26,7 +26,7 @@ namespace ams::fssystem {
size_t length;
const RomPathChar *path;
};
static_assert(std::is_pod<RomEntryName>::value);
static_assert(util::is_pod<RomEntryName>::value);
constexpr void InitializeRomEntryName(RomEntryName *entry) {
entry->length = 0;

View File

@@ -34,19 +34,19 @@ namespace ams::fssystem {
s64 file_entry_size;
s64 body_offset;
};
static_assert(std::is_pod<RomFileSystemInformation>::value);
static_assert(util::is_pod<RomFileSystemInformation>::value);
static_assert(sizeof(RomFileSystemInformation) == 0x50);
struct RomDirectoryInfo {
/* ... */
};
static_assert(std::is_pod<RomDirectoryInfo>::value);
static_assert(util::is_pod<RomDirectoryInfo>::value);
struct RomFileInfo {
fs::Int64 offset;
fs::Int64 size;
};
static_assert(std::is_pod<RomFileInfo>::value);
static_assert(util::is_pod<RomFileInfo>::value);
namespace RomStringTraits {

View File

@@ -29,7 +29,7 @@ namespace ams::fssystem {
u32 name_offset;
u32 reserved;
};
static_assert(std::is_pod<PartitionEntry>::value);
static_assert(util::is_pod<PartitionEntry>::value);
#pragma pack(pop)
static constexpr const char VersionSignature[] = { 'P', 'F', 'S', '0' };
@@ -52,7 +52,7 @@ namespace ams::fssystem {
u64 hash_target_offset;
char hash[HashSize];
};
static_assert(std::is_pod<PartitionEntry>::value);
static_assert(util::is_pod<PartitionEntry>::value);
#pragma pack(pop)
static constexpr const char VersionSignature[] = { 'H', 'F', 'S', '0' };