mirror of
https://github.com/nlohmann/json.git
synced 2026-10-21 05:28:12 +00:00
Declare the partner iterator in the loop initializer in diff_object_keys()
Signed-off-by: Niels Lohmann <mail@nlohmann.me>
This commit is contained in:
2 files changed
+2
-4
No files matched your search
@@ -7507,8 +7507,7 @@ public:
|
|||||||
target_values.reserve(source.size());
|
target_values.reserve(source.size());
|
||||||
std::size_t common = 0;
|
std::size_t common = 0;
|
||||||
bool together = source.size() == target.size();
|
bool together = source.size() == target.size();
|
||||||
auto partner = target.cbegin();
|
for (auto it = source.cbegin(), partner = target.cbegin(); it != source.cend(); ++it)
|
||||||
for (auto it = source.cbegin(); it != source.cend(); ++it)
|
|
||||||
{
|
{
|
||||||
if (together)
|
if (together)
|
||||||
{
|
{
|
||||||
|
|||||||
Generated
+1
-2
@@ -38217,8 +38217,7 @@ public:
|
|||||||
target_values.reserve(source.size());
|
target_values.reserve(source.size());
|
||||||
std::size_t common = 0;
|
std::size_t common = 0;
|
||||||
bool together = source.size() == target.size();
|
bool together = source.size() == target.size();
|
||||||
auto partner = target.cbegin();
|
for (auto it = source.cbegin(), partner = target.cbegin(); it != source.cend(); ++it)
|
||||||
for (auto it = source.cbegin(); it != source.cend(); ++it)
|
|
||||||
{
|
{
|
||||||
if (together)
|
if (together)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in new issue
Block a user