From 9a07ed53ebe4e27ef1a14e0469037cab9fb7b1e7 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sun, 16 May 2021 01:46:30 -0400 Subject: core: Make variable shadowing a compile-time error Now that we have most of core free of shadowing, we can enable the warning as an error to catch anything that may be remaining and also eliminate this class of logic bug entirely. --- src/core/hle/service/mii/manager.h | 2 +- src/core/hle/service/mii/mii.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/core/hle/service/mii') diff --git a/src/core/hle/service/mii/manager.h b/src/core/hle/service/mii/manager.h index 2106a528a..ec7efa5f7 100644 --- a/src/core/hle/service/mii/manager.h +++ b/src/core/hle/service/mii/manager.h @@ -89,7 +89,7 @@ static_assert(std::has_unique_object_representations_v, #pragma pack(push, 4) struct MiiInfoElement { - MiiInfoElement(const MiiInfo& info, Source source) : info{info}, source{source} {} + MiiInfoElement(const MiiInfo& info_, Source source_) : info{info_}, source{source_} {} MiiInfo info{}; Source source{}; diff --git a/src/core/hle/service/mii/mii.cpp b/src/core/hle/service/mii/mii.cpp index 26be9e45b..81f150a88 100644 --- a/src/core/hle/service/mii/mii.cpp +++ b/src/core/hle/service/mii/mii.cpp @@ -253,8 +253,8 @@ private: class MiiDBModule final : public ServiceFramework { public: - explicit MiiDBModule(Core::System& system_, const char* name) - : ServiceFramework{system_, name} { + explicit MiiDBModule(Core::System& system_, const char* name_) + : ServiceFramework{system_, name_} { // clang-format off static const FunctionInfo functions[] = { {0, &MiiDBModule::GetDatabaseService, "GetDatabaseService"}, -- cgit v1.2.3