-misra2012 [Professional Edition only] [V1.02 or later]
|
This option checks source code against the MISRA-C:2012 rules.
[Specification format]
- | Interpretation when omitted |
The source code is not checked against the MISRA-C: 2012 rules.
[Detailed description]
- | This option checks source code against the MISRA-C:2012 rules.
A message is output if the item specified for the check is item. |
- | The items that can be specified as item are shown below.
An error will occur if any other item is specified.
The source code is always checked against the rules of the "mandatory" type regardless of the following specification. |
|
|
|
all
|
None
|
The source code is checked against all of the rules which are supported.
|
apply
|
num[,num]...
|
The source code is checked against the rules with the numbers specified by num among the rules which are supported.
|
ignore
|
num[,num]...
|
The source code is checked against the rules with the numbers that are not specified by num among the rules which are supported.
|
required
|
None
|
The source code is checked against the rules of the "mandatory" and "required" types among the rules which are supported.
|
required_add
|
num[,num]...
|
The source code is checked against the rules of the "mandatory" and "required" types and the rules with the numbers specified by num among the rules which are supported.
|
required_remove
|
num[,num]...
|
The source code is checked against the rules of the "required" type except for the rules with the numbers specified by num among the rules which are supported.
|
file
|
The source code is checked against the rules with the numbers described in specified file file among the rules which are supported.
Specify one rule number per one line in the file.
|
- | The items that can be specified as num are shown below. [V1.06]
An error will occur if any other item is specified. |
2.2 2.6 2.7
3.1 3.2
4.1 4.2
5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9
6.1 6.2
7.1 7.2 7.3 7.4
8.1 8.2 8.3 8.4 8.8 8.9 8.11 8.12 8.14
9.1 9.2 9.3 9.4 9.5
10.1 10.2 10.3 10.4 10.5 10.6 10.7 10.8
11.1 11.2 11.3 11.4 11.5 11.6 11.7 11.8 11.9
12.1 12.2 12.3 12.4 12.5
13.1 13.2 13.3 13.4 13.5 13.6
14.4
15.1 15.2 15.3 15.4 15.5 15.6 15.7
16.1 16.2 16.3 16.4 16.5 16.6 16.7
17.1 17.3 17.4 17.5 17.6 17.7 17.8
18.4 18.5 18.7
19.2
20.1 20.2 20.3 20.4 20.5 20.6 20.7 20.8 20.9 20.10 20.11 20.12 20.13 20.14
21.1 21.2 21.3 21.4 21.5 21.6 21.7 21.8 21.9 21.10 21.11 21.12 21.13 21.15 21.16
- | An error will occur if item is omitted. |
[Example of use]
- | To check the source code against MISRA-C:2012 rule number: 5.2, 5.3 describe as: |
>ccrl -misra2012=apply=5.2,5.3 -cpu=S2 -dev=dr5f100pj.dvf main.c
|
[Caution]
- | An error will occur when this option is specified in the Standard Edition of the compiler. |
- | The source code cannot be simultaneously checked against the MISRA-C: 2004 rules. |