📄 coding
字号:
JOS CODING STANDARDSIt's easier on everyone if all authors working on a sharedcode base are consistent in the way they write their programs.We have the following conventions in our code:* No space after the name of a function in a call For example, printf("hello") not printf ("hello").* One space after keywords "if", "for", "while", "switch". For example, if (x) not if(x).* Space before braces. For example, if (x) { not if (x){.* Function names are all lower-case separated by underscores.* Beginning-of-line indentation via tabs, not spaces.* Preprocessor macros are always UPPERCASE. There are a few grandfathered exceptions: assert, panic, static_assert, offsetof.* Pointer types have spaces: (uint16_t *) not (uint16_t*).* Multi-word names are lower_case_with_underscores.* Comments in imported code are usually C /* ... */ comments. Comments in new code are C++ style //.* In a function definition, the function name starts a new line. Then you can grep -n '^foo' */*.c to find the definition of foo.* Functions that take no arguments are declared f(void) not f().
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -