Swasti Shrivastava
742d6513a1
Modified rule 10.6 ( #1263 )
...
* Modified rule 10.6
* Improved rule 10.6
2018-05-24 22:28:36 +02:00
Kyle Chisholm
6ce3571bdd
Add --suppress-rules argument for misra.py ( #1259 )
...
* Added ignore list
- Added ignore list
- Use argparse to parse arguments
- Source formatting
* misra.py changed argument name
- Changed ` --ignore-rules` to ` --suppress-rules`
* Resolved VERIFY option in misra.py
Resolved broken broken logic in commit to add argparse.
* edit suppression list
Modified names
Hide some arguments
* command line help formatting
* Revert removal of --no-summary argument
* missing text rules no longer reported
* VERIFY scope modified to global
2018-05-24 06:31:20 +02:00
Daniel Marjamäki
9f47d04af6
misra.py: add rule 10.1, partial checking
2018-05-23 16:26:00 +02:00
Swasti Shrivastava
ea5417b8af
Modified rule 11.9 ( #1262 )
2018-05-23 15:48:07 +02:00
Swasti Shrivastava
8daa8520ba
Modified rule 11.6 ( #1261 )
2018-05-23 12:50:35 +02:00
Swasti Shrivastava
684c18f657
Modified rule 11.3 and 11.7 ( #1260 )
...
* Modified rule 11.3 and 11.7
* Changed if to elif
2018-05-23 10:14:17 +02:00
Swasti Shrivastava
c73dc63537
Modified rule 11.5 ( #1256 )
2018-05-22 14:32:00 +02:00
Daniel Marjamäki
5505cbac26
misra.py: fixed fix for fp so that struct initializers are handled also
2018-05-22 13:27:27 +02:00
Daniel Marjamäki
dbe2a42e89
misra.py: Fixed 13.1 fp for struct initialization
2018-05-22 13:11:39 +02:00
Swasti Shrivastava
c511b3de20
Modified rule 11.4 ( #1252 )
...
* Modified rule 11.4
* Made changes in isEnum()
* Made suggested changes in isEnum()
2018-05-22 09:07:48 +02:00
Richard A. Smith
01cbadc6ed
Add --quiet flag to misra.py for cleaner output ( #1254 )
...
Output will still be given for style violations.
This allows the build process output to be smaller and cleaner,
making it easier to spot and address problems.
2018-05-21 21:46:58 +02:00
Swasti Shrivastava
f78314b613
Updated rule 10 4 ( #1251 )
...
* Updated rule 10.4
* Updated rule 10.4
* updated rule 10.4 along with test suite
2018-05-21 12:04:20 +02:00
Richard A. Smith
e4f10bce6d
Show summary of violations ( #1244 )
...
- Show a summary of the of the number of violations. This can be
disabled with the --no-summary option.
- Return an error code if -verify flag not used and violation exists.
2018-05-20 14:48:01 +02:00
Swasti Shrivastava
00970274b2
Added rule 21.6 and 21.10 ( #1243 )
2018-05-20 14:44:12 +02:00
Richard A. Smith
672d0433a4
Allow per project misra.py addon ( #1241 )
...
Use python's __file__ variable to figure out where the checker script is
located.
This allows a customized per project scripts to be used instead of the
one provided in the cppcheck release.
2018-05-20 14:42:25 +02:00
Richard A. Smith
a26d73f78f
Fix false positive in misra.py rule 20.14 ( #1240 )
...
MISRA rule 20.14 is not limited to #if pragmas and also extends to
positives whenever #ifdef/#ifndef is used.
2018-05-20 08:31:59 +02:00
Swasti Shrivastava
248e2ef2f8
Modified rule 7.3 ( #1232 )
2018-05-16 12:04:02 +02:00
Swasti Shrivastava
92fd7d9343
Modified rule 5.1 along with test suite ( #1231 )
...
* Modified rule 5.1 along with test suite
* Modified variable name in misra-test.c
* Modified rule 5.1 along with test suite
* Changed variable name
2018-05-16 11:07:44 +02:00
Swasti Shrivastava
bb7ffd123d
Modified rule 8.12 ( #1233 )
2018-05-15 13:18:55 +02:00
Swasti Shrivastava
4b873ed573
Rule 5.3 modified along with test suite ( #1227 )
...
* Added rule 5.2
* updated 5.2
request-checks: true
* Added rule 5.3
* Changed rule 5.4, 5.5
* Updated test suite for Rule 5.2
* Changes in Rule 5.4 and 5.5
* Change in function name in test suite and removed type from class token in cppcheck
* Changed the name of function in misra-test.c
* Modified rule 5.3
* Modified misra-test.c for rule 5.3
2018-05-14 13:09:38 +02:00
swasti16
4956b89506
Changes in misra c rule 5.4 and 5.5 ( #1219 )
...
* Added rule 5.2
* updated 5.2
request-checks: true
* Added rule 5.3
* Changed rule 5.4, 5.5
* Updated test suite for Rule 5.2
* Changes in Rule 5.4 and 5.5
* Change in function name in test suite and removed type from class token in cppcheck
* Changed the name of function in misra-test.c
2018-05-11 14:57:08 +02:00
orbitcowboy
c39e3467a4
misra.py: Rule 21.8, added missing exit() function.
2018-05-09 16:48:49 +02:00
orbitcowboy
bcae3ce9d4
misra.py: State that Cppcheck already covers rule 22.4 with error-id: 'writeReadOnlyFile'.
2018-05-09 13:51:14 +02:00
swasti16
d934065d21
Added rule 5.2 ( #1212 )
...
* Added rule 5.2
* updated 5.2
request-checks: true
* Updated test suite for Rule 5.2
2018-05-08 20:41:45 +02:00
Markus Elfring
58ebc64b2f
Using compiled regular expressions for MISRA check functions ( #1208 )
...
The method “match” was used as a module-level function in for loops
of implementations for MISRA check functions so far.
Use compiled regular expression objects instead.
Link: https://trac.cppcheck.net/ticket/8547
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
2018-05-07 22:19:39 +02:00
Daniel Marjamäki
904e9149bf
misra: fix 16.3 false negative for conditional break
2018-05-04 22:27:45 +02:00
Daniel Marjamäki
53e3217254
misra: updated 20.14
2018-05-04 06:37:02 +02:00
Daniel Marjamäki
8b42706158
misra: Added check for rule 20.13
2018-05-03 22:53:06 +02:00
Daniel Marjamäki
274d56d0aa
misra: Added 20.14 rule
2018-05-03 22:41:12 +02:00
Daniel Marjamäki
493e243c0b
misra: fix fp in 16.6
2018-05-03 10:59:09 +02:00
Daniel Marjamäki
2a9ee563c2
misra: avoid fp for essentially boolean conditions when bitfield member is used
2018-05-02 20:56:03 +02:00
Daniel Marjamäki
5e31911fcd
misra.py: fix false positives in 16.3 for unconditional blocks of code
2018-04-24 09:28:24 +02:00
Daniel Marjamäki
fb89c987b0
misra.py: Improved 'isBoolExpression'
2018-04-18 16:20:54 +02:00
Daniel Marjamäki
f94a2b0019
misra.py: cppcheck handle rule 20.6
2018-04-17 08:15:36 +02:00
Sebastian
d46e4c1df6
misra.py: Typo in number of rules (comment) ( #1150 )
...
I have no copy of the misra pdf but according to
https://sourceforge.net/p/cppcheck/discussion/general/thread/ccbe9e89/#a6ab
and the number of lines/rules printed by misra.py -generate-table i
guess 143 is really the correct number of rules.
2018-04-10 08:55:25 +02:00
Daniel Marjamäki
d31ba0ca02
misra.py: updated 11.8
2018-04-03 15:11:25 +02:00
Daniel Marjamäki
4a36520af2
misra.py: reformatting -generate-table output
2018-04-02 13:04:44 +02:00
Daniel Marjamäki
15218b388f
misra.py: Add -generate-table option that shows what rules are implemented
2018-03-31 12:52:00 +02:00
Daniel Marjamäki
ed8fda571b
misra.py: Add rule 4.1
2018-03-31 12:17:55 +02:00
Daniel Marjamäki
588ec80122
misra: the user must provide the rule texts in text file.
2018-03-24 13:28:40 +01:00
amai
ed25e21929
Set executable bit for addons/ python scripts
2018-03-20 20:54:59 +01:00
Daniel Marjamäki
480d84d69c
Fixed #8441 (MISRA Addon: FP 12.3 issued for initializer lists)
2018-03-18 22:05:31 +01:00
amai2012
449dcc15e8
Add links to external references
2018-03-16 08:12:39 +01:00
Daniel Marjamäki
1110cd0c57
misra.py: updated parsing of misra-rules.txt
2018-03-14 23:00:17 +01:00
Daniel Marjamäki
c74b0934e9
misra.py: assume that '0' and '1' have essentially boolean types
2018-03-14 14:54:05 +01:00
Daniel Marjamäki
08ee5709ed
misra.py: updated 17.1 to catch non-compliant code in example suite
2018-03-14 09:41:23 +01:00
Daniel Marjamäki
348232a599
misra.py: catch all 15.6 bugs in misra exemplar suite
2018-03-13 14:22:25 +01:00
Daniel Marjamäki
49c8e42b30
misra.py: Clarify code for switch case fallthrough
2018-03-13 13:14:26 +01:00
Daniel Marjamäki
caf0789ab3
misra.py: updated -verify behaviour, print all errors seen and not just the first
2018-03-12 15:51:41 +01:00
Daniel Marjamäki
a705391054
misra.py: minor update
2018-03-12 15:47:06 +01:00