codeql-coding-standards
codeql-coding-standards copied to clipboard
This repository contains CodeQL queries and libraries which support various Coding Standards.
Bumps the pip group with 5 updates in the /scripts directory: | Package | From | To | | --- | --- | --- | | [certifi](https://github.com/certifi/python-certifi) | `2023.7.22` |...
### Affected rules - `RULE-25-21` - Likely others, haven't researched ### Description Rule `25-21` requires that the `atomic_*_explicit` operations use the memory order `memory_order_seq_cst`. It would probably be overly restrictive...
### Affected rules - `CON34-C` ### Description [The documentation](https://wiki.sei.cmu.edu/confluence/display/c/CON34-C.+Declare+objects+shared+between+threads+with+appropriate+storage+durations) seems to describe the risk of passing a `tss_t` into a thread. The risk here is that the new thread will...
### Affected rules - `A0-1-1` (useless assignment) ### Description Constant expression used as non-type template parameter (NTTP) produces useless-assignment false positive. It can be reproduced with integer NTTP. ### Example...
### Affected rules - `A12-1-1`: `cpp/autosar/explicit-constructor-base-class-initialization` > Rule A12-1-1 (required, implementation, automated) > Constructors shall explicitly initialize all virtual base classes, all direct > non-virtual base classes and all non-static...
### Affected rules - `RULE-18-1` - `M5-0-16` ### Description The query expects that as pointers are made they are assigned to variables, and assumes that pointers into arrays always use...
A new module in [https://github.com/github/codeql-coding-standards/pull/784](thisPR) adds support for reducing noise from reports in macros, which `A5-2-2` and `RULE-1-2` both have logic to do. This module should be integrated and will...
### Affected rules - `RULE-2-2`, and likely others ### Description These rules look for dead code and exclude results from macros to reduce noise, since macros may be expanded dozens...
### Affected rules A15-4-4 ### Description 1. Query doesn’t consider ReThrowExpr. E.g. the query says to mark `rethrow()` below as `noexcept` ### Example ```cpp template void rethrow() { throw; }...
### Affected rules - `RULE-10-4` ### Description The text states that the rule applies to _usual arithmetic conversions_, and the c spec states that for `a ? b : c`...