From beaf1e5a6db8467e4a8061cc9d40ef5218d3714d Mon Sep 17 00:00:00 2001 From: Vlad Buslov Date: Tue, 15 Jul 2025 17:08:05 +0200 Subject: [PATCH 1/3] clang-tidy: Add config to enforce naming style Signed-off-by: Vlad Buslov --- .clang-tidy | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 .clang-tidy diff --git a/.clang-tidy b/.clang-tidy new file mode 100644 index 000000000..563caf3c6 --- /dev/null +++ b/.clang-tidy @@ -0,0 +1,20 @@ +Checks: '-*,readability-identifier-naming' +CheckOptions: + # Local variables and function arguments + - { key: readability-identifier-naming.LocalVariableCase, value: lower_case } + - { key: readability-identifier-naming.ParameterCase, value: lower_case } + # Class, struct, union, and enum type names + - { key: readability-identifier-naming.ClassCase, value: camelBack } + - { key: readability-identifier-naming.StructCase, value: camelBack } + - { key: readability-identifier-naming.UnionCase, value: camelBack } + - { key: readability-identifier-naming.EnumCase, value: camelBack } + # Fields and methods for classes, structs, and unions + - { key: readability-identifier-naming.ClassMemberCase, value: camelBack } + - { key: readability-identifier-naming.StructMemberCase, value: camelBack } + - { key: readability-identifier-naming.UnionMemberCase, value: camelBack } + - { key: readability-identifier-naming.MethodCase, value: camelBack } + # Private class members (fields) + - { key: readability-identifier-naming.PrivateMemberCase, value: camelBack } + - { key: readability-identifier-naming.PrivateMemberSuffix, value: _ } + # Enum values (enumerators) + - { key: readability-identifier-naming.EnumConstantCase, value: UPPER_CASE } \ No newline at end of file From 040908785001300811cdd137d5b5d38c06e5528e Mon Sep 17 00:00:00 2001 From: Vlad Buslov Date: Wed, 16 Jul 2025 20:25:02 +0200 Subject: [PATCH 2/3] Update .clang-tidy Co-authored-by: Raul Akhmetshin <74596089+rakhmets@users.noreply.github.com> Signed-off-by: Vlad Buslov --- .clang-tidy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.clang-tidy b/.clang-tidy index 563caf3c6..bd86e26e6 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -7,7 +7,7 @@ CheckOptions: - { key: readability-identifier-naming.ClassCase, value: camelBack } - { key: readability-identifier-naming.StructCase, value: camelBack } - { key: readability-identifier-naming.UnionCase, value: camelBack } - - { key: readability-identifier-naming.EnumCase, value: camelBack } + - { key: readability-identifier-naming.EnumCase, value: lower_case } # Fields and methods for classes, structs, and unions - { key: readability-identifier-naming.ClassMemberCase, value: camelBack } - { key: readability-identifier-naming.StructMemberCase, value: camelBack } From c2b7a180ab38b45466a889ba06ba78aadc231c73 Mon Sep 17 00:00:00 2001 From: Vlad Buslov Date: Wed, 16 Jul 2025 20:33:16 +0200 Subject: [PATCH 3/3] clang-tidy: Update according to latest code style changes Signed-off-by: Vlad Buslov --- .clang-tidy | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.clang-tidy b/.clang-tidy index bd86e26e6..e7d8ef945 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -17,4 +17,10 @@ CheckOptions: - { key: readability-identifier-naming.PrivateMemberCase, value: camelBack } - { key: readability-identifier-naming.PrivateMemberSuffix, value: _ } # Enum values (enumerators) - - { key: readability-identifier-naming.EnumConstantCase, value: UPPER_CASE } \ No newline at end of file + - { key: readability-identifier-naming.EnumConstantCase, value: UPPER_CASE } + # For 'using' type aliases + - { key: readability-identifier-naming.TypeAliasCase, value: lower_case } + - { key: readability-identifier-naming.TypeAliasSuffix, value: _t } + # For 'typedef' type aliases + - { key: readability-identifier-naming.TypedefCase, value: lower_case } + - { key: readability-identifier-naming.TypedefSuffix, value: _t }