mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2024-12-30 22:14:09 +08:00
Merge pull request #365 from ya1gaurav/patch-29
Remove conditional check for isMultiLine
This commit is contained in:
commit
9942f6a1c7
@ -489,8 +489,7 @@ bool StyledWriter::isMultineArray(const Value& value) {
|
|||||||
childValues_.clear();
|
childValues_.clear();
|
||||||
for (int index = 0; index < size && !isMultiLine; ++index) {
|
for (int index = 0; index < size && !isMultiLine; ++index) {
|
||||||
const Value& childValue = value[index];
|
const Value& childValue = value[index];
|
||||||
isMultiLine =
|
isMultiLine = ((childValue.isArray() || childValue.isObject()) &&
|
||||||
isMultiLine || ((childValue.isArray() || childValue.isObject()) &&
|
|
||||||
childValue.size() > 0);
|
childValue.size() > 0);
|
||||||
}
|
}
|
||||||
if (!isMultiLine) // check if line length > max line length
|
if (!isMultiLine) // check if line length > max line length
|
||||||
@ -709,8 +708,7 @@ bool StyledStreamWriter::isMultineArray(const Value& value) {
|
|||||||
childValues_.clear();
|
childValues_.clear();
|
||||||
for (int index = 0; index < size && !isMultiLine; ++index) {
|
for (int index = 0; index < size && !isMultiLine; ++index) {
|
||||||
const Value& childValue = value[index];
|
const Value& childValue = value[index];
|
||||||
isMultiLine =
|
isMultiLine = ((childValue.isArray() || childValue.isObject()) &&
|
||||||
isMultiLine || ((childValue.isArray() || childValue.isObject()) &&
|
|
||||||
childValue.size() > 0);
|
childValue.size() > 0);
|
||||||
}
|
}
|
||||||
if (!isMultiLine) // check if line length > max line length
|
if (!isMultiLine) // check if line length > max line length
|
||||||
@ -989,8 +987,7 @@ bool BuiltStyledStreamWriter::isMultineArray(Value const& value) {
|
|||||||
childValues_.clear();
|
childValues_.clear();
|
||||||
for (int index = 0; index < size && !isMultiLine; ++index) {
|
for (int index = 0; index < size && !isMultiLine; ++index) {
|
||||||
Value const& childValue = value[index];
|
Value const& childValue = value[index];
|
||||||
isMultiLine =
|
isMultiLine = ((childValue.isArray() || childValue.isObject()) &&
|
||||||
isMultiLine || ((childValue.isArray() || childValue.isObject()) &&
|
|
||||||
childValue.size() > 0);
|
childValue.size() > 0);
|
||||||
}
|
}
|
||||||
if (!isMultiLine) // check if line length > max line length
|
if (!isMultiLine) // check if line length > max line length
|
||||||
|
Loading…
x
Reference in New Issue
Block a user