aboutsummaryrefslogtreecommitdiffstats
path: root/cparser/Checks.mli
Commit message (Collapse)AuthorAgeFilesLines
* [BROKEN] Merge with v3.9 : something broken for __builtin_expect in ↵Cyril SIX2021-06-011-4/+5
| | | | cfrontend/C2C.ml
* Added new diagnostic for non-linear conditionalsBernhard Schommer2019-07-041-0/+2
| | | | | | | | | | | | | | The new diagnostics is triggered if a conditional is used that may not be transformed into linear code by the later by the if conversion. The new diagnostic is emitted if a conditional may contain an unsafe expression or is contained within another conditional, logical and or logical or expression. An expression is unsafe if it contains a call, changes memory or if its evaluation leads to undefined behavior, for example division and modulo. Also fixes a small typo in a comment in Cutil.
* Added a simple check for unused variables.Bernhard Schommer2017-02-171-0/+2
| | | | | | | | | | | | | | | | | The check test whether the identifier is used at all in the function and if not issue a warning. It is not tested whether the usage is reachable at all, so int i; if (0) i; would not generate a warning. This is the same as gcc/clang does. The warning is disabled per default, but is active if -Wall is given. Bug 19872
* Checks can be applied add several places.Bernhard Schommer2017-02-171-1/+1
| | | | | | There should not be a single check place, since for example unknonw attributes should be check after elaboration and other simplifications.
* Added new module for checks on elaborated C codeBernhard Schommer2017-02-171-0/+16
The new module adds a function which is called during parse after all C transformation have taken place for adding additional checks. Currently only unknown attribute are checked. Bug 19872