Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core/StarJsonExtra.hpp
diff options
context:
space:
mode:
authorKai Blaschke <kai.blaschke@kb-dev.net>2024-02-19 16:55:19 +0100
committerKai Blaschke <kai.blaschke@kb-dev.net>2024-02-19 16:55:19 +0100
commit431a9c00a56cf4c603be1cf5f773b193621d8150 (patch)
tree95843aeea9fb6dc18279ee05ff6961f40b19798f /source/core/StarJsonExtra.hpp
parent30e1871d3f44629e00a1f66d8164e3e62c7f889f (diff)
Fixed a huge amount of Clang warnings
On Linux and macOS, using Clang to compile OpenStarbound produces about 400 MB worth of warnings during the build, making the compiler output unreadable and slowing the build down considerably. 99% of the warnings were unqualified uses of std::move and std::forward, which are now all properly qualified. Fixed a few other minor warnings about non-virtual destructors and some uses of std::move preventing copy elision on temporary objects. Most remaining warnings are now unused parameters.
Diffstat (limited to 'source/core/StarJsonExtra.hpp')
-rw-r--r--source/core/StarJsonExtra.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/core/StarJsonExtra.hpp b/source/core/StarJsonExtra.hpp
index 66d89d6..98de98b 100644
--- a/source/core/StarJsonExtra.hpp
+++ b/source/core/StarJsonExtra.hpp
@@ -262,7 +262,7 @@ MapType jsonToMapK(Json const& v, KeyConverter&& keyConvert) {
template <typename MapType, typename ValueConverter>
MapType jsonToMapV(Json const& v, ValueConverter&& valueConvert) {
- return jsonToMapKV<MapType>(v, construct<typename MapType::key_type>(), forward<ValueConverter>(valueConvert));
+ return jsonToMapKV<MapType>(v, construct<typename MapType::key_type>(), std::forward<ValueConverter>(valueConvert));
}
template <typename MapType>
@@ -281,12 +281,12 @@ Json jsonFromMapKV(MapType const& map, KeyConverter&& keyConvert, ValueConverter
template <typename MapType, typename KeyConverter>
Json jsonFromMapK(MapType const& map, KeyConverter&& keyConvert) {
- return jsonFromMapKV<MapType>(map, forward<KeyConverter>(keyConvert), construct<Json>());
+ return jsonFromMapKV<MapType>(map, std::forward<KeyConverter>(keyConvert), construct<Json>());
}
template <typename MapType, typename ValueConverter>
Json jsonFromMapV(MapType const& map, ValueConverter&& valueConvert) {
- return jsonFromMapKV<MapType>(map, construct<String>(), forward<ValueConverter>(valueConvert));
+ return jsonFromMapKV<MapType>(map, construct<String>(), std::forward<ValueConverter>(valueConvert));
}
template <typename MapType>