Skip to content

Commit 9f35565

Browse files
committed
Add change note, update manual.
1 parent e38e416 commit 9f35565

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

change_notes/2025-02-13-deviations.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
- A new in code deviation format has been introduced, using the C/C++ attribute syntax:
2+
```
3+
[[codeql::<standard>_deviation("<code-identifier>")]]
4+
```
5+
This can be applied to functions, statements and variables to apply a deviation from the Coding Standards configuration file. The user manual has been updated to describe the new format.
6+
- For those codebases that cannot use standard attributes, we have also introduced a comment based syntax
7+
```
8+
// codeql::<standard>_deviation(<code-identifier>)
9+
// codeql::<standard>_deviation_next_line(<code-identifier>)
10+
// codeql::<standard>_deviation_begin(<code-identifier>)
11+
// codeql::<standard>_deviation_end(<code-identifier>)
12+
```
13+
Further information is available in the user manual.

docs/user_manual.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ A code identifier specified in a deviation record can be applied to certain resu
439439
[[codeql::<standard>_deviation("code-identifier")]]
440440
```
441441

442-
For example `[[codeql::misra_deviation("a1-2-4")]]` would apply a deviation of a rule in a MISRA standard, using the code identifier `a1-2-4`. The supported standard names are `misra`, `autosar` and `cert`.
442+
For example `[[codeql::autosar_deviation("a1-2-4")]]` would apply a deviation of a rule in the AUTOSAR standard, using the code identifier `a1-2-4`. The supported standard names are `misra`, `autosar` and `cert`.
443443

444444
This attribute may be added to the following program elements:
445445

0 commit comments

Comments
 (0)