clang-tools 22.0.0git
|
This check diagnoses when the loop induction expression of a for loop has floating-point type. More...
#include <FloatLoopCounter.h>
Public Member Functions | |
FloatLoopCounter (StringRef Name, ClangTidyContext *Context) | |
void | registerMatchers (ast_matchers::MatchFinder *Finder) override |
void | check (const ast_matchers::MatchFinder::MatchResult &Result) override |
This check diagnoses when the loop induction expression of a for loop has floating-point type.
The check corresponds to: https://www.securecoding.cert.org/confluence/display/c/FLP30-C.+Do+not+use+floating-point+variables+as+loop+counters
For the user-facing documentation see: https://clang.llvm.org/extra/clang-tidy/checks/cert/flp30-c.html
Definition at line 22 of file FloatLoopCounter.h.
|
inline |
Definition at line 24 of file FloatLoopCounter.h.
|
override |
Definition at line 32 of file FloatLoopCounter.cpp.
|
override |
Definition at line 18 of file FloatLoopCounter.cpp.