Better semantic of sharing columns: development [#CLICKHOUSE-2].

This commit is contained in:
Alexey Milovidov 2017-12-16 09:33:54 +03:00
parent 62f7c25522
commit 5f4a536f75

View File

@ -88,10 +88,9 @@ Block ColumnGathererStream::readImpl()
if (!source_to_fully_copy && row_sources_buf.eof())
return Block();
MutableColumns output_columns(1);
output_columns[0] = column.column->cloneEmpty();
output_columns[0]->gather(*this);
return output_block.cloneWithColumns(std::move(output_columns));
MutableColumnPtr output_column = column.column->cloneEmpty();
output_column->gather(*this);
return { ColumnWithTypeAndName(std::move(output_column), column.type, column.name) };
}