Skip to content

Commit e70d35f

Browse files
Append changes.
2 parents eb969c8 + 44e8cf0 commit e70d35f

File tree

16,522 files changed

+1035471
-466017
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

16,522 files changed

+1035471
-466017
lines changed

.clang-format

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,13 +83,14 @@ NamespaceIndentation: None
8383
ObjCBlockIndentWidth: 4
8484
ObjCSpaceAfterProperty: true
8585
ObjCSpaceBeforeProtocolList: true
86+
PackConstructorInitializers: Never
8687
PenaltyBreakBeforeFirstCallParameter: 19
8788
PenaltyBreakComment: 300
8889
PenaltyBreakFirstLessLess: 120
8990
PenaltyBreakString: 1000
9091
PenaltyExcessCharacter: 1000000
9192
PenaltyReturnTypeOnItsOwnLine: 60
92-
RemoveBracesLLVM: true
93+
RemoveBracesLLVM: false
9394
SpaceAfterCStyleCast: false
9495
SpaceBeforeAssignmentOperators: true
9596
SpaceBeforeParens: ControlStatements

.clang-tidy

Lines changed: 22 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -10,36 +10,30 @@ HeaderFilterRegex: '^.*/(base|src|programs|utils)/.*(h|hpp)$'
1010
Checks: [
1111
'*',
1212

13-
'-abseil-*',
13+
'-abseil-string-find-str-contains', # disabled to avoid a misleading suggestion (obsolete absl::StrContains() instead of C++23 std::string::contains())
1414

1515
'-altera-*',
1616

1717
'-android-*',
1818

19+
'-boost-use-ranges',
20+
1921
'-bugprone-assignment-in-if-condition',
2022
'-bugprone-branch-clone',
2123
'-bugprone-easily-swappable-parameters',
2224
'-bugprone-exception-escape',
23-
'-bugprone-forward-declaration-namespace',
2425
'-bugprone-implicit-widening-of-multiplication-result',
26+
'-bugprone-multi-level-implicit-pointer-conversion',
2527
'-bugprone-narrowing-conversions',
26-
'-bugprone-not-null-terminated-result',
27-
'-bugprone-reserved-identifier', # useful but too slow, TODO retry when https://reviews.llvm.org/rG1c282052624f9d0bd273bde0b47b30c96699c6c7 is merged
2828
'-bugprone-unchecked-optional-access',
29+
'-bugprone-crtp-constructor-accessibility',
30+
'-bugprone-not-null-terminated-result',
2931

3032
'-cert-dcl16-c',
31-
'-cert-dcl37-c',
32-
'-cert-dcl51-cpp',
3333
'-cert-err58-cpp',
34-
'-cert-msc32-c',
35-
'-cert-msc51-cpp',
36-
'-cert-oop54-cpp',
37-
'-cert-oop57-cpp',
3834

3935
'-clang-analyzer-optin.performance.Padding',
4036

41-
'-clang-analyzer-unix.Malloc',
42-
4337
'-cppcoreguidelines-*', # impractical in a codebase as large as ClickHouse, also slow
4438

4539
'-darwin-*',
@@ -72,39 +66,39 @@ Checks: [
7266
'-hicpp-use-emplace',
7367
'-hicpp-vararg',
7468

75-
'-linuxkernel-*',
76-
7769
'-llvm-*',
7870

7971
'-llvmlibc-*',
8072

81-
'-openmp-*',
82-
8373
'-misc-const-correctness',
8474
'-misc-include-cleaner', # useful but far too many occurrences
8575
'-misc-no-recursion',
8676
'-misc-non-private-member-variables-in-classes',
87-
'-misc-confusable-identifiers', # useful but slooo
8877
'-misc-use-anonymous-namespace',
78+
'-misc-use-internal-linkage',
8979

9080
'-modernize-avoid-c-arrays',
9181
'-modernize-concat-nested-namespaces',
92-
'-modernize-macro-to-enum',
9382
'-modernize-pass-by-value',
9483
'-modernize-return-braced-init-list',
9584
'-modernize-use-auto',
9685
'-modernize-use-default-member-init',
9786
'-modernize-use-emplace',
9887
'-modernize-use-nodiscard',
88+
'-modernize-use-ranges',
9989
'-modernize-use-trailing-return-type',
90+
'-modernize-use-designated-initializers',
10091

92+
'-performance-avoid-endl',
93+
'-performance-enum-size',
10194
'-performance-inefficient-string-concatenation',
95+
'-performance-inefficient-vector-operation',
10296
'-performance-no-int-to-ptr',
103-
'-performance-avoid-endl',
10497
'-performance-unnecessary-value-param',
10598

10699
'-portability-simd-intrinsics',
107100

101+
'-readability-avoid-nested-conditional-operator',
108102
'-readability-avoid-unconditional-preprocessor-if',
109103
'-readability-braces-around-statements',
110104
'-readability-convert-member-functions-to-static',
@@ -114,30 +108,23 @@ Checks: [
114108
'-readability-identifier-length',
115109
'-readability-identifier-naming', # useful but too slow
116110
'-readability-implicit-bool-conversion',
117-
'-readability-isolate-declaration',
118111
'-readability-magic-numbers',
119112
'-readability-named-parameter',
120113
'-readability-redundant-declaration',
114+
'-readability-redundant-inline-specifier', # useful but incompatible with __attribute((always_inline))__ (aka. ALWAYS_INLINE, base/base/defines.h).
115+
# ALWAYS_INLINE only has an effect if combined with `inline`: https://godbolt.org/z/Eefd74qdM
116+
'-readability-redundant-member-init', # Useful but triggers another problem. Imagine a struct S with multiple String members. Structs are often instantiated via designated
117+
# initializer S s{.s1 = [...], .s2 = [...], [...]}. In this case, compiler warning `missing-field-initializers` requires to specify all members which are not in-struct
118+
# initialized (example: s1 in struct S { String s1; String s2{};}; is not in-struct initialized, therefore it must be specified at instantiation time). As explicitly
119+
# specifying all members is tedious for large structs, `missing-field-initializers` makes programmers initialize as many members as possible in-struct. Clang-tidy
120+
# warning `readability-redundant-member-init` does the opposite thing, both are not compatible with each other.
121121
'-readability-simplify-boolean-expr',
122122
'-readability-suspicious-call-argument',
123123
'-readability-uppercase-literal-suffix',
124124
'-readability-use-anyofallof',
125+
'-readability-math-missing-parentheses',
125126

126-
'-zircon-*',
127-
128-
# These are new in clang-18, and we have to sort them out:
129-
'-readability-avoid-nested-conditional-operator',
130-
'-modernize-use-designated-initializers',
131-
'-performance-enum-size',
132-
'-readability-redundant-inline-specifier',
133-
'-readability-redundant-member-init',
134-
'-bugprone-crtp-constructor-accessibility',
135-
'-bugprone-suspicious-stringview-data-usage',
136-
'-bugprone-multi-level-implicit-pointer-conversion',
137-
'-cert-err33-c',
138-
139-
# This is a good check, but clang-tidy crashes, see https://github.com/llvm/llvm-project/issues/91872
140-
'-modernize-use-constraints',
127+
'-zircon-*'
141128
]
142129

143130
WarningsAsErrors: '*'

.clangd

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,6 @@ Diagnostics:
1414
readability-identifier-naming,
1515
bugprone-reserved-identifier,
1616
]
17+
# Require LLVM 20 (https://github.com/llvm/llvm-project/pull/67749)
18+
Style:
19+
AngledHeaders: [".*"]

.editorconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,7 @@ charset = utf-8
1919
indent_style = space
2020
indent_size = 4
2121
trim_trailing_whitespace = true
22+
23+
# Some SQL results have trailing whitespace which is removed by IDEs
24+
[tests/queries/**.reference]
25+
trim_trailing_whitespace = false

.git-blame-ignore-revs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,9 @@
1313
# dbms/ → src/
1414
# (though it is unlikely that you will see it in blame)
1515
06446b4f08a142d6f1bc30664c47ded88ab51782
16+
17+
# Applied Black formatter for Python code
18+
e6f5a3f98b21ba99cf274a9833797889e020a2b3
19+
20+
# Enabling clang-tidy readability-else-no-return rule
21+
67c1e89d90ef576e62f8b1c68269742a3c6f9b1e

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ contrib/* linguist-vendored
22
*.h linguist-language=C++
33
tests/queries/0_stateless/data_json/* binary
44
tests/queries/0_stateless/*.reference -crlf
5+
src/Core/SettingsChangesHistory.cpp merge=union

.github/ISSUE_TEMPLATE/10_question.md

Lines changed: 0 additions & 12 deletions
This file was deleted.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Question
2+
description: Ask a question about ClickHouse
3+
labels: ["question"]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
> Make sure to check documentation https://clickhouse.com/docs/ first. If the question is concise and probably has a short answer, asking it in [community Slack](https://join.slack.com/t/clickhousedb/shared_invite/zt-1gh9ds7f4-PgDhJAaF8ad5RbWBAAjzFg) is probably the fastest way to find the answer. For more complicated questions, consider asking them on StackOverflow with "clickhouse" tag https://stackoverflow.com/questions/tagged/clickhouse
9+
- type: textarea
10+
attributes:
11+
label: Company or project name
12+
description: Put your company name or project description here.
13+
validations:
14+
required: false
15+
- type: textarea
16+
attributes:
17+
label: Question
18+
description: Please put your question here.
19+
validations:
20+
required: true

.github/ISSUE_TEMPLATE/20_feature-request.md

Lines changed: 0 additions & 26 deletions
This file was deleted.
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Feature request
2+
description: Suggest an idea for ClickHouse
3+
labels: ["feature"]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
> (you don't have to strictly follow this form)
9+
- type: textarea
10+
attributes:
11+
label: Company or project name
12+
description: Put your company name or project description here.
13+
validations:
14+
required: false
15+
- type: textarea
16+
attributes:
17+
label: Use case
18+
description: A clear and concise description of what the intended usage scenario is.
19+
validations:
20+
required: true
21+
- type: textarea
22+
attributes:
23+
label: Describe the solution you'd like
24+
description: A clear and concise description of what you want to happen.
25+
validations:
26+
required: true
27+
- type: textarea
28+
attributes:
29+
label: Describe alternatives you've considered
30+
description: A clear and concise description of any alternative solutions or features you've considered.
31+
validations:
32+
required: false
33+
- type: textarea
34+
attributes:
35+
label: Additional context
36+
description: Add any other context or screenshots about the feature request here.
37+
validations:
38+
required: false

0 commit comments

Comments
 (0)