diff options
Diffstat (limited to 'Utilities/std')
-rw-r--r-- | Utilities/std/cm/bits/fs_path.cxx | 2 | ||||
-rw-r--r-- | Utilities/std/cm/filesystem | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/Utilities/std/cm/bits/fs_path.cxx b/Utilities/std/cm/bits/fs_path.cxx index 8089998..1f52878 100644 --- a/Utilities/std/cm/bits/fs_path.cxx +++ b/Utilities/std/cm/bits/fs_path.cxx @@ -847,7 +847,7 @@ cm::string_view path::get_filename_fragment(filename_fragment fragment) const { auto file = this->get_filename(); - if (file == "." || file == ".." || file.empty()) { + if (file.empty() || file == "." || file == "..") { return fragment == filename_fragment::stem ? file : cm::string_view{}; } diff --git a/Utilities/std/cm/filesystem b/Utilities/std/cm/filesystem index cb05b22..6cbdea9 100644 --- a/Utilities/std/cm/filesystem +++ b/Utilities/std/cm/filesystem @@ -1150,6 +1150,8 @@ inline path::iterator path::end() const return iterator(this, true); } +// Non-member functions +// ==================== bool operator==(const path::iterator& lhs, const path::iterator& rhs); inline bool operator!=(const path::iterator& lhs, const path::iterator& rhs) @@ -1157,8 +1159,6 @@ inline bool operator!=(const path::iterator& lhs, const path::iterator& rhs) return !(lhs == rhs); } -// Non-member functions -// ==================== inline void swap(path& lhs, path& rhs) noexcept { lhs.swap(rhs); |