diff options
author | Lioncash <mathew1800@gmail.com> | 2018-10-09 13:42:34 -0400 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2018-10-09 14:10:22 -0400 |
commit | 9ff743bc0acb63a176cd7c823aa63f5602c41299 (patch) | |
tree | 205ae8a773cd7a8ec304c42a2c6e3ecc0e95e929 /src | |
parent | f7d2889fb46bf5589b53952c656fdc090334b9de (diff) |
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.cpp | 18 |
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 { Error, }; -constexpr std::array<std::pair<const char*, const char*>, 11> ESCAPE_CHARACTER_MAP{ - std::pair{"\\a", "\a"}, {"\\b", "\b"}, {"\\f", "\f"}, {"\\n", "\n"}, - {"\\r", "\r"}, {"\\t", "\t"}, {"\\v", "\v"}, {"\\\\", "\\"}, - {"\\\'", "\'"}, {"\\\"", "\""}, {"\\\?", "\?"}, -}; +constexpr std::array<std::pair<const char*, const char*>, 11> ESCAPE_CHARACTER_MAP{{ + {"\\a", "\a"}, + {"\\b", "\b"}, + {"\\f", "\f"}, + {"\\n", "\n"}, + {"\\r", "\r"}, + {"\\t", "\t"}, + {"\\v", "\v"}, + {"\\\\", "\\"}, + {"\\\'", "\'"}, + {"\\\"", "\""}, + {"\\\?", "\?"}, +}}; static IPSFileType IdentifyMagic(const std::vector<u8>& magic) { if (magic.size() != 5) |