diff --git a/src/blackmisc/aviation/aircraftenginelist.cpp b/src/blackmisc/aviation/aircraftenginelist.cpp index d75622ed7..ffe3ddf02 100644 --- a/src/blackmisc/aviation/aircraftenginelist.cpp +++ b/src/blackmisc/aviation/aircraftenginelist.cpp @@ -69,6 +69,7 @@ namespace BlackMisc CAircraftEngine engine; int number = e.toInt(); CJsonScope scope(e); + Q_UNUSED(scope); engine.convertFromJson(json.value(e).toObject()); engine.setNumber(number); push_back(engine); diff --git a/src/blackmisc/containerbase.h b/src/blackmisc/containerbase.h index 799d34d57..38a57ea22 100644 --- a/src/blackmisc/containerbase.h +++ b/src/blackmisc/containerbase.h @@ -129,6 +129,7 @@ namespace BlackMisc for (auto i = array.begin(); i != array.end(); ++i) { CJsonScope scope("containerbase", index++); + Q_UNUSED(scope); QJsonValueRef ref = (*i); T val; ref >> val; diff --git a/src/blackmisc/dictionary.h b/src/blackmisc/dictionary.h index 7a059b50e..15a727df4 100644 --- a/src/blackmisc/dictionary.h +++ b/src/blackmisc/dictionary.h @@ -273,10 +273,12 @@ namespace BlackMisc Value val; { CJsonScope scope("associativecontainerbase", 2 * index); + Q_UNUSED(scope); jsonKey >> key; } { CJsonScope scope("associativecontainerbase", 2 * index++ + 1); + Q_UNUSED(scope); jsonValue >> val; } m_impl.insert(std::move(key), std::move(val)); diff --git a/src/blackmisc/json.h b/src/blackmisc/json.h index c3b6b0e63..1f7d42948 100644 --- a/src/blackmisc/json.h +++ b/src/blackmisc/json.h @@ -379,6 +379,7 @@ namespace BlackMisc else { CJsonScope scope(member.latin1Name()); + Q_UNUSED(scope); value >> member.in(*this->derived()); } }); diff --git a/src/blackmisc/simulation/aircraftmodellist.cpp b/src/blackmisc/simulation/aircraftmodellist.cpp index 515847052..518f8f965 100644 --- a/src/blackmisc/simulation/aircraftmodellist.cpp +++ b/src/blackmisc/simulation/aircraftmodellist.cpp @@ -749,14 +749,17 @@ namespace BlackMisc if (distributors.isUndefined()) { throw CJsonException("Missing 'distributors'"); } { CJsonScope scope("aircraftIcaos"); + Q_UNUSED(scope); helper.getTable().convertFromJson(aircraftIcaos.toObject()); } { CJsonScope scope("liveries"); + Q_UNUSED(scope); helper.getTable().convertFromJson(liveries.toObject()); } { CJsonScope scope("distributors"); + Q_UNUSED(scope); helper.getTable().convertFromJson(distributors.toObject()); } @@ -764,6 +767,7 @@ namespace BlackMisc for (auto i = array.begin(); i != array.end(); ++i) { CJsonScope scope("containerbase", index++); + Q_UNUSED(scope); CAircraftModel value; value.convertFromMemoizedJson(i->toObject(), helper); insert(value); diff --git a/src/blackmisc/simulation/simulatorplugininfo.cpp b/src/blackmisc/simulation/simulatorplugininfo.cpp index 0c068993b..209e087ea 100644 --- a/src/blackmisc/simulation/simulatorplugininfo.cpp +++ b/src/blackmisc/simulation/simulatorplugininfo.cpp @@ -29,8 +29,8 @@ namespace BlackMisc if (! json.contains("MetaData")) { throw CJsonException("Missing 'MetaData'"); } // json data is already validated by CPluginManagerSimulator - //! \todo for RW See T107, remove, change code? - // CJsonScope scope("MetaData"); + CJsonScope scope("MetaData"); + Q_UNUSED(scope); CValueObject::convertFromJson(json["MetaData"].toObject()); m_valid = true; } diff --git a/src/blackmisc/variantmap.cpp b/src/blackmisc/variantmap.cpp index fed1abd5e..15c001901 100644 --- a/src/blackmisc/variantmap.cpp +++ b/src/blackmisc/variantmap.cpp @@ -39,6 +39,7 @@ namespace BlackMisc { const QString key = it.key(); CJsonScope scope(key); + Q_UNUSED(scope); CVariant value; value.convertFromJson(it.value().toObject()); implementationOf(*this).insert(cend(), key, value); @@ -53,6 +54,7 @@ namespace BlackMisc auto value = json.value(key); if (value.isUndefined()) { continue; } CJsonScope scope(key); + Q_UNUSED(scope); CVariant var; var.convertFromJson(value.toObject()); insert(key, var); @@ -82,6 +84,7 @@ namespace BlackMisc { const QString key = it.key(); CJsonScope scope(key); + Q_UNUSED(scope); CVariant value; value.convertFromMemoizedJson(it.value().toObject()); implementationOf(*this).insert(cend(), key, value); @@ -96,6 +99,7 @@ namespace BlackMisc auto value = json.value(key); if (value.isUndefined()) { continue; } CJsonScope scope(key); + Q_UNUSED(scope); CVariant var; var.convertFromMemoizedJson(value.toObject()); insert(key, var); @@ -110,6 +114,7 @@ namespace BlackMisc { const QString key = it.key(); CJsonScope scope(key); + Q_UNUSED(scope); CVariant value; auto message = value.convertFromJsonNoThrow(it.value().toObject(), categories, prefix); if (message.isSuccess()) { implementationOf(*this).insert(cend(), key, value); } @@ -127,6 +132,7 @@ namespace BlackMisc auto value = json.value(key); if (value.isUndefined()) { continue; } CJsonScope scope(key); + Q_UNUSED(scope); CVariant var; auto message = var.convertFromJsonNoThrow(value.toObject(), categories, prefix); if (message.isSuccess()) { insert(key, var); } @@ -143,6 +149,7 @@ namespace BlackMisc { const QString key = it.key(); CJsonScope scope(key); + Q_UNUSED(scope); CVariant value; auto message = value.convertFromMemoizedJsonNoThrow(it.value().toObject(), categories, prefix); if (message.isSuccess()) { implementationOf(*this).insert(cend(), key, value); } @@ -160,6 +167,7 @@ namespace BlackMisc auto value = json.value(key); if (value.isUndefined()) { continue; } CJsonScope scope(key); + Q_UNUSED(scope); CVariant var; auto message = var.convertFromMemoizedJsonNoThrow(value.toObject(), categories, prefix); if (message.isSuccess()) { insert(key, var); } diff --git a/src/blackmisc/weather/weatherdataplugininfo.cpp b/src/blackmisc/weather/weatherdataplugininfo.cpp index fc29f0137..da4c8827c 100644 --- a/src/blackmisc/weather/weatherdataplugininfo.cpp +++ b/src/blackmisc/weather/weatherdataplugininfo.cpp @@ -29,7 +29,8 @@ namespace BlackMisc if (! json.contains("MetaData")) { throw CJsonException("Missing 'MetaData'"); } // json data is already validated by CPluginManagerWeatherData - CJsonScope scope("MetaData"); + CJsonScope scope("MetaData"); // for stack trace + Q_UNUSED(scope); CValueObject::convertFromJson(json["MetaData"].toObject()); m_valid = true; }