Skip to content

Commit 494a577

Browse files
committed
Use rapidjson::SizeType for RapidJSON methods
1 parent 81b5c37 commit 494a577

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

GraphQLService.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,7 @@ void ValueVisitor::visitEnumValue(const peg::ast_node& enumValue)
804804
void ValueVisitor::visitListValue(const peg::ast_node& listValue)
805805
{
806806
_value = rapidjson::Value(rapidjson::Type::kArrayType);
807-
_value.Reserve(listValue.children.size(), _allocator);
807+
_value.Reserve(static_cast<rapidjson::SizeType>(listValue.children.size()), _allocator);
808808

809809
ValueVisitor visitor(_allocator, _variables);
810810

GraphQLService.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ struct ModifiedResult
370370
{
371371
auto value = rapidjson::Value(rapidjson::Type::kArrayType);
372372

373-
value.Reserve(result.size(), params.allocator);
373+
value.Reserve(static_cast<rapidjson::SizeType>(result.size()), params.allocator);
374374

375375
for (auto& entry : result)
376376
{

SchemaGenerator.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -982,7 +982,7 @@ void Generator::DefaultValueVisitor::visitListValue(const peg::ast_node& listVal
982982

983983
auto& allocator = _value.GetAllocator();
984984

985-
_value.Reserve(listValue.children.size(), allocator);
985+
_value.Reserve(static_cast<rapidjson::SizeType>(listValue.children.size()), allocator);
986986
for (const auto& child : listValue.children)
987987
{
988988
rapidjson::Value value;

0 commit comments

Comments
 (0)