Skip to content

Fixed ColumnLowCardinality::Clear() #49

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 4, 2020

Conversation

Enmk
Copy link
Contributor

@Enmk Enmk commented Sep 1, 2020

Now ColumnLowCardinality-column can be safely reused after being cleared.
Added unit-tests and integration tests to validate fix.

@Enmk Enmk force-pushed the LowCardinality-Clear-fix branch from 162c150 to ef0e515 Compare September 2, 2020 07:30
@Enmk Enmk requested a review from traceon September 2, 2020 08:52
Copy link
Contributor

@traceon traceon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (+ 1 note for old code)

@@ -125,18 +127,19 @@ ColumnLowCardinality::ColumnLowCardinality(ColumnRef dictionary_column)
{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The prototype of ColumnLowCardinality::ColumnLowCardinality(ColumnRef dictionary_column) should accept ColumnRef && dictionary_column to denote that the original object pointed by the ColumnRef = shared_ptr<> is modified/consumed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Designed a better way to copy values from source column, without all those shenanigans, so this is fixed now

@Enmk Enmk force-pushed the LowCardinality-Clear-fix branch from c3bce56 to 7b3fcdc Compare September 3, 2020 19:33
@Enmk Enmk merged commit 4ceb5d1 into ClickHouse:master Sep 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants