mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-03 21:41:26 +12:00
Fix fs::dir (const begin/end)
This commit is contained in:
parent
0d1cb8c878
commit
3792a85084
1 changed files with 7 additions and 7 deletions
|
@ -422,7 +422,7 @@ namespace fs
|
||||||
|
|
||||||
class iterator
|
class iterator
|
||||||
{
|
{
|
||||||
dir* m_parent;
|
const dir* m_parent;
|
||||||
dir_entry m_entry;
|
dir_entry m_entry;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -432,7 +432,7 @@ namespace fs
|
||||||
from_current
|
from_current
|
||||||
};
|
};
|
||||||
|
|
||||||
iterator(dir* parent, mode mode_ = mode::from_first)
|
iterator(const dir* parent, mode mode_ = mode::from_first)
|
||||||
: m_parent(parent)
|
: m_parent(parent)
|
||||||
{
|
{
|
||||||
if (!m_parent)
|
if (!m_parent)
|
||||||
|
@ -458,7 +458,7 @@ namespace fs
|
||||||
|
|
||||||
iterator& operator++()
|
iterator& operator++()
|
||||||
{
|
{
|
||||||
*this = { m_parent, mode::from_current };
|
*this = {m_parent, mode::from_current};
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -468,14 +468,14 @@ namespace fs
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
iterator begin()
|
iterator begin() const
|
||||||
{
|
{
|
||||||
return{ m_dir ? this : nullptr };
|
return {m_dir ? this : nullptr};
|
||||||
}
|
}
|
||||||
|
|
||||||
iterator end()
|
iterator end() const
|
||||||
{
|
{
|
||||||
return{ nullptr };
|
return {nullptr};
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue