Replace boost::optional with std::optional where possible
This commit is contained in:
@@ -7,10 +7,10 @@
|
||||
#include <algorithm>
|
||||
#include <initializer_list>
|
||||
#include <memory>
|
||||
#include <optional>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
#include <boost/optional.hpp>
|
||||
#include "common/common_types.h"
|
||||
#include "common/file_util.h"
|
||||
#include "core/file_sys/romfs_reader.h"
|
||||
@@ -107,7 +107,7 @@ public:
|
||||
* information.
|
||||
* @returns A pair with the optional system mode, and and the status.
|
||||
*/
|
||||
virtual std::pair<boost::optional<u32>, ResultStatus> LoadKernelSystemMode() {
|
||||
virtual std::pair<std::optional<u32>, ResultStatus> LoadKernelSystemMode() {
|
||||
// 96MB allocated to the application.
|
||||
return std::make_pair(2, ResultStatus::Success);
|
||||
}
|
||||
|
@@ -49,11 +49,11 @@ FileType AppLoader_NCCH::IdentifyType(FileUtil::IOFile& file) {
|
||||
return FileType::Error;
|
||||
}
|
||||
|
||||
std::pair<boost::optional<u32>, ResultStatus> AppLoader_NCCH::LoadKernelSystemMode() {
|
||||
std::pair<std::optional<u32>, ResultStatus> AppLoader_NCCH::LoadKernelSystemMode() {
|
||||
if (!is_loaded) {
|
||||
ResultStatus res = base_ncch.Load();
|
||||
if (res != ResultStatus::Success) {
|
||||
return std::make_pair(boost::none, res);
|
||||
return std::make_pair(std::optional<u32>{}, res);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -39,7 +39,7 @@ public:
|
||||
* Loads the Exheader and returns the system mode for this application.
|
||||
* @returns A pair with the optional system mode, and and the status.
|
||||
*/
|
||||
std::pair<boost::optional<u32>, ResultStatus> LoadKernelSystemMode() override;
|
||||
std::pair<std::optional<u32>, ResultStatus> LoadKernelSystemMode() override;
|
||||
|
||||
ResultStatus ReadCode(std::vector<u8>& buffer) override;
|
||||
|
||||
|
Reference in New Issue
Block a user