mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-29 23:07:48 +02:00
Warnings fixes (#538)
Warnings fixes * Suppress `missing-braces` for Clang * Fixed many C4275 warnings * Fixed almost all Clang/GCC warnings * Silence most frequent MSVC warning. * Fixed some pessimizing-move warnings * Fixed some unused capture warnings
This commit is contained in:
committed by
GitHub
parent
419fee1fb2
commit
b00e935e4d
@@ -756,7 +756,7 @@ CVisitInfo CGBonusingObject::getVisitInfo(int index, const CGHeroInstance *h) co
|
||||
vi.message.addTxt(MetaString::ADVOB_TXT, 138);
|
||||
vi.reward.extraComponents.push_back(Component(
|
||||
Component::CREATURE, CreatureID::CHAMPION, 0, 1));
|
||||
return std::move(vi);
|
||||
return vi;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -103,7 +103,7 @@ void CHeroInstanceConstructor::afterLoadFinalization()
|
||||
{
|
||||
for (auto entry : filtersJson.Struct())
|
||||
{
|
||||
filters[entry.first] = LogicalExpression<HeroTypeID>(entry.second, [this](const JsonNode & node)
|
||||
filters[entry.first] = LogicalExpression<HeroTypeID>(entry.second, [](const JsonNode & node)
|
||||
{
|
||||
return HeroTypeID(VLC->modh->identifiers.getIdentifier("hero", node.Vector()[0]).get());
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user