mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
Fix ugly ugliness
This commit is contained in:
parent
abf1e015b3
commit
34e67b521a
@ -50,11 +50,11 @@ struct ArrayFillImpl
|
||||
|
||||
for (auto in_offset : in_offsets)
|
||||
{
|
||||
array_end = in_offset - 1;
|
||||
array_end = in_offset;
|
||||
|
||||
for (; end <= array_end; ++end)
|
||||
for (; end < array_end; ++end)
|
||||
{
|
||||
if (end == array_end || fill[end + 1] != fill[begin])
|
||||
if (end + 1 == array_end || fill[end + 1] != fill[begin])
|
||||
{
|
||||
if (fill[begin])
|
||||
out_data.insertRangeFrom(in_data, begin, end + 1 - begin);
|
||||
@ -62,8 +62,8 @@ struct ArrayFillImpl
|
||||
{
|
||||
if constexpr (reverse)
|
||||
{
|
||||
if (end == array_end)
|
||||
out_data.insertManyFrom(in_data, array_end, end + 1 - begin);
|
||||
if (end + 1 == array_end)
|
||||
out_data.insertManyFrom(in_data, end, end + 1 - begin);
|
||||
else
|
||||
out_data.insertManyFrom(in_data, end + 1, end + 1 - begin);
|
||||
}
|
||||
@ -80,7 +80,7 @@ struct ArrayFillImpl
|
||||
}
|
||||
}
|
||||
|
||||
array_begin = array_end + 1;
|
||||
array_begin = array_end;
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -93,8 +93,7 @@ struct ArrayFillImpl
|
||||
if (column_fill_const->getValue<UInt8>())
|
||||
return ColumnArray::create(
|
||||
array.getDataPtr(),
|
||||
array.getOffsetsPtr()
|
||||
);
|
||||
array.getOffsetsPtr());
|
||||
|
||||
size_t array_begin = 0;
|
||||
size_t array_end = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user