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

希望举某个规则示例时,该示例也能符合全文其他地方要求的规范,统一风格 #56

Open
plopop opened this issue Jul 21, 2024 · 0 comments

Comments

@plopop
Copy link

plopop commented Jul 21, 2024

比如4.1要求全局变量名不能太短,在4.10的示例中推荐了单个字符变量名,对随手翻阅党不友好😂

R4.1 全局名称应遵循合理的命名方式:
// In global scope
const int i = 0; // Non-compliant, name too short
typedef int t; // Non-compliant, name too short
class A { .... }; // Non-compliant, name too short
...

R4.10 全局对象只应为常量或静态对象:
// In global scope
...
const int k = 0; // Compliant

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

No branches or pull requests

1 participant