mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-07-04 05:51:19 +12:00
Fixed some issues.
This commit is contained in:
parent
9402789146
commit
97a74a32da
2 changed files with 16 additions and 6 deletions
|
@ -1,10 +1,16 @@
|
||||||
#include "FSPath.h"
|
#include "FSPath.h"
|
||||||
|
|
||||||
#ifdef BOOST_OS_UNIX
|
#ifdef BOOST_OS_UNIX
|
||||||
|
FSPath operator/ (const FSPath& lhs, const FSPath& rhs)
|
||||||
FSPath& FSPath::operator/ (const FSPath & other)
|
|
||||||
{
|
{
|
||||||
*this /= other;
|
FSPath res{lhs};
|
||||||
|
res /= FSPath{rhs};
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
|
||||||
|
FSPath& FSPath::operator/ (const FSPath & rhs)
|
||||||
|
{
|
||||||
|
*this /= rhs;
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -17,7 +23,7 @@ FSPath& FSPath::operator/= (const FSPath & other)
|
||||||
fs::path correctedPath = empty() ? other.root_path() : *this;
|
fs::path correctedPath = empty() ? other.root_path() : *this;
|
||||||
|
|
||||||
// helper function to convert a path's alphabet characters to lowercase.
|
// helper function to convert a path's alphabet characters to lowercase.
|
||||||
auto static lowercase_path = [](FSPath const & path)
|
auto static lowercase_path = [](fs::path const & path)
|
||||||
{
|
{
|
||||||
std::string string = path.string();
|
std::string string = path.string();
|
||||||
for (auto& i : string)
|
for (auto& i : string)
|
||||||
|
|
|
@ -15,6 +15,10 @@ class FSPath : public fs::path {
|
||||||
return FSPath{} / FSPath{input};
|
return FSPath{} / FSPath{input};
|
||||||
}
|
}
|
||||||
FSPath& operator/= (const FSPath & other);
|
FSPath& operator/= (const FSPath & other);
|
||||||
FSPath& operator/ (const FSPath & other);
|
FSPath& operator/ (const FSPath & rhs);
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef BOOST_OS_UNIX
|
||||||
|
FSPath operator/ (const FSPath& lhs, const FSPath& rhs);
|
||||||
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue