mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-24 19:14:40 +00:00
Apply suggestions from code review
Co-authored-by: GPUCode <47210458+GPUCode@users.noreply.github.com>
This commit is contained in:
parent
eb1a632c64
commit
b40fd50d64
@ -2,8 +2,8 @@
|
|||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <Zydis/Zydis.h>
|
#include <Zydis/Zydis.h>
|
||||||
#include <common/config.h>
|
#include "common/config.h"
|
||||||
#include <common/path_util.h>
|
#include "common/path_util.h"
|
||||||
#include "common/logging/log.h"
|
#include "common/logging/log.h"
|
||||||
#include "common/string_util.h"
|
#include "common/string_util.h"
|
||||||
#include "core/aerolib/aerolib.h"
|
#include "core/aerolib/aerolib.h"
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <common/string_util.h>
|
#include "common/string_util.h"
|
||||||
#include "common/io_file.h"
|
#include "common/io_file.h"
|
||||||
#include "common/logging/log.h"
|
#include "common/logging/log.h"
|
||||||
#include "common/types.h"
|
#include "common/types.h"
|
||||||
@ -35,8 +35,7 @@ const SymbolRecord* SymbolsResolver::FindSymbol(const SymbolResolver& s) const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void SymbolsResolver::DebugDump(const std::filesystem::path& file_name) {
|
void SymbolsResolver::DebugDump(const std::filesystem::path& file_name) {
|
||||||
Common::FS::IOFile f;
|
Common::FS::IOFile f{file_name, Common::FS::FileAccessMode::Write, Common::FS::FileType::TextFile};
|
||||||
f.Open(file_name, Common::FS::FileAccessMode::Write, Common::FS::FileType::TextFile);
|
|
||||||
for (const auto& symbol : m_symbols) {
|
for (const auto& symbol : m_symbols) {
|
||||||
const auto ids = Common::SplitString(symbol.name, '#');
|
const auto ids = Common::SplitString(symbol.name, '#');
|
||||||
std::string nidName = "";
|
std::string nidName = "";
|
||||||
@ -50,7 +49,6 @@ void SymbolsResolver::DebugDump(const std::filesystem::path& file_name) {
|
|||||||
symbol.virtual_address, ids.at(0), nidName, ids.at(1), ids.at(2),
|
symbol.virtual_address, ids.at(0), nidName, ids.at(1), ids.at(2),
|
||||||
ids.at(3), ids.at(4), ids.at(5), ids.at(6)));
|
ids.at(3), ids.at(4), ids.at(5), ids.at(6)));
|
||||||
}
|
}
|
||||||
f.Close();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace Core::Loader
|
} // namespace Core::Loader
|
||||||
|
@ -44,7 +44,7 @@ public:
|
|||||||
|
|
||||||
static std::string GenerateName(const SymbolResolver& s);
|
static std::string GenerateName(const SymbolResolver& s);
|
||||||
|
|
||||||
static std::string SymbolTypeToS(SymbolType sym_type) {
|
static std::string_view SymbolTypeToS(SymbolType sym_type) {
|
||||||
switch (sym_type) {
|
switch (sym_type) {
|
||||||
case SymbolType::Unknown:
|
case SymbolType::Unknown:
|
||||||
return "Unknown";
|
return "Unknown";
|
||||||
|
Loading…
Reference in New Issue
Block a user