Skip to content

Commit 24f43e6

Browse files
committed
[2.1] Justify unreachable code in example
1 parent b99f0ea commit 24f43e6

1 file changed

Lines changed: 23 additions & 8 deletions

File tree

MISRA.md

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,6 @@ with ( Assuming rule 8.4 violation; with justification in point 1 ):
1818
grep 'MISRA Ref 8.4.1' . -rI
1919
```
2020

21-
#### Dir 2.2
22-
23-
MISRA C:2012 Dir 2.2: There shall be no dead code.
24-
25-
_Ref 2.2_
26-
- `vPortEndScheduler` is erroneously determined to be dead code due to
27-
simplified verification port.
28-
2921
#### Dir 4.7
3022

3123
MISRA C:2012 Dir 4.7: If a function returns error information, then that error
@@ -162,6 +154,29 @@ Certain deviating code is left unsurpressed for awarness. This code should
162154
not be considered for usage in MISRA compliant applications. These violations
163155
will be reported when audited by a MISRA-checking static analysis tool.
164156

157+
#### Dir 2.1
158+
159+
MISRA C:2012 Dir 2.1: A project shall not contain unreachable code
160+
161+
_Ref 2.1_
162+
- Simplified example contains unreachable code for demonstration of
163+
freertos scheduler. A production implemenation should not contain
164+
this.
165+
166+
Affected Files:
167+
- examples/cmake_example/main.c
168+
169+
#### Dir 2.2
170+
171+
MISRA C:2012 Dir 2.2: There shall be no dead code.
172+
173+
_Ref 2.2_
174+
- `vPortEndScheduler` is erroneously determined to be dead code due to
175+
simplified verification port.
176+
177+
Affected Files:
178+
- tasks.c
179+
165180
#### Rule 21.3
166181

167182
MISRA C-2012 Rule 21.3: The memory allocation and deallocation functions of

0 commit comments

Comments
 (0)