Skip to content

Commit 7cfd928

Browse files
authored
Scaffolding: add function-like macros section in the guidelines (#64)
1 parent dd2d665 commit 7cfd928

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

src/coding-guidelines/macros.rst

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,48 @@ Macros
9090
9191
// TODO
9292
93+
.. guideline:: Shall not use Function-like Macros
94+
:id: gui_WJlWqgIxmE8P
95+
:category: mandatory
96+
:status: draft
97+
:release: todo
98+
:fls: fls_utd3zqczix
99+
:decidability: decidable
100+
:scope: system
101+
:tags: reduce-human-error
102+
103+
Description of the guideline goes here.
104+
105+
.. rationale::
106+
:id: rat_C8RRidiVzhRj
107+
:status: draft
108+
109+
Explanation of why this guideline is important.
110+
111+
.. non_compliant_example::
112+
:id: non_compl_ex_TjRiRkmBY6wG
113+
:status: draft
114+
115+
Explanation of code example.
116+
117+
.. code-block:: rust
118+
119+
fn example_function() {
120+
// Non-compliant implementation
121+
}
122+
123+
.. compliant_example::
124+
:id: compl_ex_AEKEOYhBWPMl
125+
:status: draft
126+
127+
Explanation of code example.
128+
129+
.. code-block:: rust
130+
131+
fn example_function() {
132+
// Compliant implementation
133+
}
134+
93135
.. guideline:: Shall not invoke macros
94136
:id: gui_a1mHfjgKk4Xr
95137
:category: mandatory

0 commit comments

Comments
 (0)