diff options
author | FearlessTobi <thm.frey@gmail.com> | 2024-02-11 22:27:20 +0100 |
---|---|---|
committer | FearlessTobi <thm.frey@gmail.com> | 2024-02-19 19:20:46 +0100 |
commit | ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1 (patch) | |
tree | 82751935ffc1d9b1ab8a9f3fa0999762b1e6e9b2 /src/core/file_sys/fs_path_utility.h | |
parent | fs: Refactor to use cmif serialization (diff) | |
download | yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar.gz yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar.bz2 yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar.lz yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar.xz yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.tar.zst yuzu-ba70dc4c13ff84b51d2937f5c8ba873b061cb4c1.zip |
Diffstat (limited to 'src/core/file_sys/fs_path_utility.h')
-rw-r--r-- | src/core/file_sys/fs_path_utility.h | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/core/file_sys/fs_path_utility.h b/src/core/file_sys/fs_path_utility.h index 5643141f9..51418ee16 100644 --- a/src/core/file_sys/fs_path_utility.h +++ b/src/core/file_sys/fs_path_utility.h @@ -91,8 +91,12 @@ public: } #define DECLARE_PATH_FLAG_HANDLER(__WHICH__) \ - constexpr bool Is##__WHICH__##Allowed() const { return (m_value & __WHICH__##Flag) != 0; } \ - constexpr void Allow##__WHICH__() { m_value |= __WHICH__##Flag; } + constexpr bool Is##__WHICH__##Allowed() const { \ + return (m_value & __WHICH__##Flag) != 0; \ + } \ + constexpr void Allow##__WHICH__() { \ + m_value |= __WHICH__##Flag; \ + } DECLARE_PATH_FLAG_HANDLER(WindowsPath) DECLARE_PATH_FLAG_HANDLER(RelativePath) @@ -426,9 +430,10 @@ public: R_SUCCEED(); } - static Result Normalize(char* dst, size_t* out_len, const char* path, size_t max_out_size, - bool is_windows_path, bool is_drive_relative_path, - bool allow_all_characters = false) { + static constexpr Result Normalize(char* dst, size_t* out_len, const char* path, + size_t max_out_size, bool is_windows_path, + bool is_drive_relative_path, + bool allow_all_characters = false) { // Use StringTraits names for remainder of scope using namespace StringTraits; |