1 Star 0 Fork 70

Joseph/iEDA

forked from OSCC/iEDA 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.clang-tidy 4.83 KB
一键复制 编辑 原始数据 按行查看 历史
Harry 提交于 2023-05-08 14:02 . !1 update230508
# ***************************************************************************************
# Copyright (c) 2023-2025 Peng Cheng Laboratory
# Copyright (c) 2023-2025 Institute of Computing Technology, Chinese Academy of Sciences
# Copyright (c) 2023-2025 Beijing Institute of Open Source Chip
#
# iEDA is licensed under Mulan PSL v2.
# You can use this software according to the terms and conditions of the Mulan PSL v2.
# You may obtain a copy of Mulan PSL v2 at:
# http://license.coscl.org.cn/MulanPSL2
#
# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
# EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
# MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
#
# See the Mulan PSL v2 for more details.
# ***************************************************************************************
Checks: >
readability-identifier-naming
# readability-*
# -readability-braces-around-statements,
# -readability-identifier-length,
# -readability-magic-numbers,
# -readability-named-parameter,
# -readability-redundant-declaration,
# -readability-function-cognitive-complexity
# abseil-*,
# boost-*,
# bugprone-*,
# google-*,
# misc-*,
# modernize-*,
# performance-*,
# portability-*,
# -google-readability-braces-around-statements,
# -google-readability-namespace-comments,
# -google-runtime-references,
# -misc-non-private-member-variables-in-classes,
# -misc-const-correctness,
# -modernize-return-braced-init-list,
# -modernize-use-trailing-return-type,
# -modernize-avoid-c-arrays,
# -performance-move-const-arg,
# Turn all the warnings from the checks above into errors.
# WarningsAsErrors: "*"
HeaderFilterRegex: '*.h, *.hpp, *.hh'
CheckOptions:
# 局部变量名单词之间使用下划线隔开
- { key: readability-identifier-naming.LocalVariableCase, value: lower_case }
- { key: readability-identifier-naming.LocalVariableIgnoredRegexp, value: '_[a-zA-Z_]+' }
# 类的变量成员用下划线作为前缀如 _file_name
- { key: readability-identifier-naming.ClassMemberCase, value: lower_case }
- { key: readability-identifier-naming.ClassMemberPrefix, value: _ }
# 类的函数名使用驼峰类型;如doSomething()
- { key: readability-identifier-naming.ClassMethodCase, value: camelBack }
# 类的成员存取使用 如get_file_name() set_file_name()
- { key: readability-identifier-naming.ClassMethodIgnoredRegexp, value: '[gs]et_[a-zA-Z_]+' }
# 类名是PASCAL风格,即首字母大写 如MyClass
- { key: readability-identifier-naming.ClassCase, value: CamelCase }
- { key: readability-identifier-naming.StructCase, value: CamelCase }
# 常量用k作为前缀后面是PASCAL风格如 kFileName
- { key: readability-identifier-naming.GlobalConstantPrefix, value: k }
- { key: readability-identifier-naming.GlobalConstantCase, value: CamelCase }
# 全局变量用g作为前缀后面是PASCAL风格如 gFileName
- { key: readability-identifier-naming.GlobalVariablePrefix, value: g }
- { key: readability-identifier-naming.GlobalVariableCase, value: CamelCase }
# 接口类必须以Interface为后缀
- { key: readability-identifier-naming.AbstractClassSuffix, value: Interface }
# 宏定义全大写,中间用下划线隔开 FILE_NAME
- { key: readability-identifier-naming.MacroDefinitionCase, value: UPPER_CASE }
- { key: readability-identifier-naming.EnumConstantCase, value: CamelCase }
- { key: readability-identifier-naming.EnumConstantPrefix, value: k }
- { key: readability-identifier-naming.GlobalFunctionCase, value: CamelCase }
# - { key: readability-identifier-naming.NamespaceCase, value: aNy_CasE }
# - { key: readability-identifier-naming.TemplateParameterCase, value: aNy_CasE }
# - { key: readability-identifier-naming.ConstexprVariableCase, value: aNy_CasE }
# - { key: readability-identifier-naming.ConstexprVariablePrefix, value: k }
# - { key: readability-identifier-naming.GlobalConstantCase, value: aNy_CasE }
# - { key: readability-identifier-naming.GlobalConstantPrefix, value: k }
# - { key: readability-identifier-naming.MemberConstantCase, value: aNy_CasE }
# - { key: readability-identifier-naming.MemberConstantPrefix, value: k }
# - { key: readability-identifier-naming.StaticConstantCase, value: aNy_CasE }
# - { key: readability-identifier-naming.StaticConstantPrefix, value: k }
# - { key: readability-implicit-bool-conversion.AllowIntegerConditions, value: 1 }
# - { key: readability-implicit-bool-conversion.AllowPointerConditions, value: 1 }
# - { key: readability-function-cognitive-complexity.IgnoreMacros, value: 1 }
# reference: https://clang.llvm.org/extra/clang-tidy/checks/list.html
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/gpz_joseph/iEDA.git
git@gitee.com:gpz_joseph/iEDA.git
gpz_joseph
iEDA
iEDA
master

搜索帮助