Skip to content
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

Fix clang17 build warning on SUSE Linux platform #561

Merged
merged 9 commits into from
Feb 19, 2024

Conversation

Shylock-Hg
Copy link
Contributor

@Shylock-Hg Shylock-Hg commented Feb 12, 2024

PR checklist:

  • Did you run ClangFormat ?
  • Did you separate headers to a different section in existing community code base ?
  • Did you surround proton: starts/ends for new code in existing community code base ?

Please write user-readable short description of the changes:
Fix some compile warning in clang17.
Close #540

@CLAassistant
Copy link

CLAassistant commented Feb 12, 2024

CLA assistant check
All committers have signed the CLA.

@jovezhong jovezhong changed the title Fix warning. Fix warning for SUSE Linux build Feb 12, 2024
@jovezhong
Copy link
Contributor

Thanks @Shylock-Hg for contributing the improvement for building process on SUSE Linux. I updated the title to make it clear. Since it's in Lunar New Year holiday, the code review could be a bit slower than usual.

@chenziliang
Copy link
Collaborator

Thanks so much for the PR : may you help do a diff with ClickHouse community code ? We like Proton's code base to be aligned with the ClickHouse OSS as much as we can. For example, in https://github.com/ClickHouse/ClickHouse/blob/master/src/Columns/ColumnDecimal.cpp, it used my_compressed=std::move(compressed)

@yokofly yokofly changed the title Fix warning for SUSE Linux build Fix clang17 build warning on SUSE Linux platform Feb 13, 2024
@Shylock-Hg
Copy link
Contributor Author

Thanks so much for the PR : may you help do a diff with ClickHouse community code ? We like Proton's code base to be aligned with the ClickHouse OSS as much as we can. For example, in https://github.com/ClickHouse/ClickHouse/blob/master/src/Columns/ColumnDecimal.cpp, it used my_compressed=std::move(compressed)

Is there a script to do diff? And I plan to rename with prefix my_, is it accepted?

@chenziliang
Copy link
Collaborator

Thanks so much for the PR : may you help do a diff with ClickHouse community code ? We like Proton's code base to be aligned with the ClickHouse OSS as much as we can. For example, in https://github.com/ClickHouse/ClickHouse/blob/master/src/Columns/ColumnDecimal.cpp, it used my_compressed=std::move(compressed)

Is there a script to do diff? And I plan to rename with prefix my_, is it accepted?

We don't have a script yet and it is a manual process. I did this by using vimdiff and carefully pick what we need. Yes rename the variable names same as CH community does is what we like to have here.

@yokofly
Copy link
Collaborator

yokofly commented Feb 14, 2024

Edit v1: add more context
Edit v2: add regex

thanks for continue working on this pr.

The rest part seems only need to replace all the changed prefix, I have a simple but still complex way. git patch will generate a file to log changed code. consider use regex for the git patch file with vim/vscode such editor, and then git apply under a new branch, finally directly force push a new commit.

Remember take a look about git reflog if u wanna back to previous status/commit.

@Shylock-Hg Shylock-Hg requested a review from yokofly February 15, 2024 10:04
@yokofly
Copy link
Collaborator

yokofly commented Feb 18, 2024

this pr is really clear.
I locally build with ubuntu 20.04 and clang17 on this feature branch works well, and the smoke test and unit test passed.
I will check detailed a bit later.

src/Access/AccessChangesNotifier.cpp Outdated Show resolved Hide resolved
src/Access/AccessChangesNotifier.cpp Outdated Show resolved Hide resolved
src/Access/EnabledRoles.cpp Outdated Show resolved Hide resolved
src/Client/Suggest.cpp Outdated Show resolved Hide resolved
@yokofly
Copy link
Collaborator

yokofly commented Feb 18, 2024

overall is good👍 will force merge this PR tomorrow.

@proton-robot proton-robot merged commit 639dfa7 into timeplus-io:develop Feb 19, 2024
8 of 9 checks passed
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.

SUSE Linux build error
6 participants