summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar Lioncash2018-10-09 13:42:34 -0400
committerGravatar Lioncash2018-10-09 14:10:22 -0400
commit9ff743bc0acb63a176cd7c823aa63f5602c41299 (patch)
tree205ae8a773cd7a8ec304c42a2c6e3ecc0e95e929 /src
parentips_layer: Add missing includes (diff)
downloadyuzu-9ff743bc0acb63a176cd7c823aa63f5602c41299.tar.gz
yuzu-9ff743bc0acb63a176cd7c823aa63f5602c41299.tar.xz
yuzu-9ff743bc0acb63a176cd7c823aa63f5602c41299.zip
ips_layer: Remove unnecessary explicit std::pair constructor in std::array
Makes the layout of the array consistent, by making all elements match, instead of special-casing the first one.
Diffstat (limited to 'src')
-rw-r--r--src/core/file_sys/ips_layer.cpp18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/core/file_sys/ips_layer.cpp b/src/core/file_sys/ips_layer.cpp
index f832bf8e6..90f91f230 100644
--- a/src/core/file_sys/ips_layer.cpp
+++ b/src/core/file_sys/ips_layer.cpp
@@ -22,11 +22,19 @@ enum class IPSFileType {
22 Error, 22 Error,
23}; 23};
24 24
25constexpr std::array<std::pair<const char*, const char*>, 11> ESCAPE_CHARACTER_MAP{ 25constexpr std::array<std::pair<const char*, const char*>, 11> ESCAPE_CHARACTER_MAP{{
26 std::pair{"\\a", "\a"}, {"\\b", "\b"}, {"\\f", "\f"}, {"\\n", "\n"}, 26 {"\\a", "\a"},
27 {"\\r", "\r"}, {"\\t", "\t"}, {"\\v", "\v"}, {"\\\\", "\\"}, 27 {"\\b", "\b"},
28 {"\\\'", "\'"}, {"\\\"", "\""}, {"\\\?", "\?"}, 28 {"\\f", "\f"},
29}; 29 {"\\n", "\n"},
30 {"\\r", "\r"},
31 {"\\t", "\t"},
32 {"\\v", "\v"},
33 {"\\\\", "\\"},
34 {"\\\'", "\'"},
35 {"\\\"", "\""},
36 {"\\\?", "\?"},
37}};
30 38
31static IPSFileType IdentifyMagic(const std::vector<u8>& magic) { 39static IPSFileType IdentifyMagic(const std::vector<u8>& magic) {
32 if (magic.size() != 5) 40 if (magic.size() != 5)