From 87ea870f03e7d97292970c6fcf486ec87638f674 Mon Sep 17 00:00:00 2001 From: Super Genius <71915886+SuperGNUS@users.noreply.github.com> Date: Tue, 16 May 2023 02:13:59 -0700 Subject: [PATCH] Update modelbase-header.mustache (#15453) Fixes warning in ModelBase.h warning: loop variable 'jitem' creates a copy from type 'const web::json::value' [-Wrange-loop-construct] --- .../resources/cpp-rest-sdk-client/modelbase-header.mustache | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/openapi-generator/src/main/resources/cpp-rest-sdk-client/modelbase-header.mustache b/modules/openapi-generator/src/main/resources/cpp-rest-sdk-client/modelbase-header.mustache index 5fb44a81fae3..a108b96f5d9d 100644 --- a/modules/openapi-generator/src/main/resources/cpp-rest-sdk-client/modelbase-header.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-rest-sdk-client/modelbase-header.mustache @@ -233,7 +233,7 @@ bool ModelBase::fromJson( const web::json::value& val, std::vector &outVal ) bool ok = true; if (val.is_array()) { - for (const auto jitem : val.as_array()) + for (const web::json::value & jitem : val.as_array()) { T item; ok &= fromJson(jitem, item);