ams: std::optional -> util::optional
This commit is contained in:
@@ -54,7 +54,7 @@ namespace ams::fssrv::impl {
|
||||
return m_list.size();
|
||||
}
|
||||
|
||||
std::optional<fs::ProgramIndexMapInfo> Get(const ncm::ProgramId &program_id) const {
|
||||
util::optional<fs::ProgramIndexMapInfo> Get(const ncm::ProgramId &program_id) const {
|
||||
/* Acquire exclusive access to the map. */
|
||||
std::scoped_lock lk(m_mutex);
|
||||
|
||||
@@ -134,9 +134,9 @@ namespace ams::fssrv::impl {
|
||||
}
|
||||
|
||||
template<typename F>
|
||||
std::optional<fs::ProgramIndexMapInfo> GetImpl(F f) const {
|
||||
util::optional<fs::ProgramIndexMapInfo> GetImpl(F f) const {
|
||||
/* Try to find an entry matching the predicate. */
|
||||
std::optional<fs::ProgramIndexMapInfo> match = std::nullopt;
|
||||
util::optional<fs::ProgramIndexMapInfo> match = util::nullopt;
|
||||
|
||||
for (const auto &entry : m_list) {
|
||||
/* If the predicate matches, we want to return the relevant info. */
|
||||
|
||||
@@ -92,7 +92,7 @@ namespace ams::fssrv::impl {
|
||||
public:
|
||||
bool IsDeepRetryEnabled() const;
|
||||
bool IsAccessFailureDetectionObserved() const;
|
||||
std::optional<std::shared_lock<os::ReadWriteLock>> AcquireCacheInvalidationReadLock();
|
||||
util::optional<std::shared_lock<os::ReadWriteLock>> AcquireCacheInvalidationReadLock();
|
||||
os::ReadWriteLock &GetReadWriteLockForCacheInvalidation();
|
||||
public:
|
||||
/* Command API. */
|
||||
|
||||
@@ -44,7 +44,7 @@ namespace ams::fssrv::impl {
|
||||
|
||||
~StorageInterfaceAdapter();
|
||||
private:
|
||||
std::optional<std::shared_lock<os::ReadWriteLock>> AcquireCacheInvalidationReadLock();
|
||||
util::optional<std::shared_lock<os::ReadWriteLock>> AcquireCacheInvalidationReadLock();
|
||||
public:
|
||||
/* Command API. */
|
||||
Result Read(s64 offset, const ams::sf::OutNonSecureBuffer &buffer, s64 size);
|
||||
|
||||
Reference in New Issue
Block a user