Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
en:manual:contrib:coding_style_guidelines [2020/03/10 23:37] emulatorman |
en:manual:contrib:coding_style_guidelines [2022/03/08 20:40] i3_relativism ↷ Page name changed from en:project:hyperbolabsd_coding_style_guidelines to en:project:coding_style_guidelines |
||
---|---|---|---|
Line 108: | Line 108: | ||
When declaring variables in structures, declare them sorted by use, then by size (largest to smallest), then by alphabetical order. | When declaring variables in structures, declare them sorted by use, then by size (largest to smallest), then by alphabetical order. | ||
- | Major structures should be declared at the top of the file in which they are used, or in separate header files if they are used in multiple source files. | + | Major structures should be declared at the top of the file in which they are used, or in separate header files if they are used in multiple source files. |
<code c> | <code c> | ||
Line 123: | Line 123: | ||
<code c> | <code c> | ||
#include < | #include < | ||
- | struct | + | struct foo { |
LIST_ENTRY(foo) link; /* Queue macro glue for foo lists */ | LIST_ENTRY(foo) link; /* Queue macro glue for foo lists */ | ||
struct | struct | ||
Line 394: | Line 394: | ||
===== History ===== | ===== History ===== | ||
- | This article is largely based on the <color # | + | This article is largely based on the <color # |
===== Licensing ===== | ===== Licensing ===== | ||
Line 402: | Line 402: | ||
===== Acknowledgement ===== | ===== Acknowledgement ===== | ||
- | This wiki article is based on **[[https:// | + | This wiki article is based on **4.4BSD-Lite2 |