clang-tools 22.0.0git
clang::tidy::linuxkernel::MustCheckErrsCheck Class Reference

Checks Linux kernel code to see if it uses the results from the functions in linux/err.h. More...

#include <MustCheckErrsCheck.h>

Inheritance diagram for clang::tidy::linuxkernel::MustCheckErrsCheck:
[legend]

Public Member Functions

 MustCheckErrsCheck (StringRef Name, ClangTidyContext *Context)
void registerMatchers (ast_matchers::MatchFinder *Finder) override
void check (const ast_matchers::MatchFinder::MatchResult &Result) override

Detailed Description

Checks Linux kernel code to see if it uses the results from the functions in linux/err.h.

Also checks to see if code uses the results from functions that directly return a value from one of these error functions.

For the user-facing documentation see: https://clang.llvm.org/extra/clang-tidy/checks/linuxkernel/must-check-errs.html

Definition at line 22 of file MustCheckErrsCheck.h.

Constructor & Destructor Documentation

◆ MustCheckErrsCheck()

clang::tidy::linuxkernel::MustCheckErrsCheck::MustCheckErrsCheck ( StringRef Name,
ClangTidyContext * Context )
inline

Definition at line 24 of file MustCheckErrsCheck.h.

Member Function Documentation

◆ check()

void clang::tidy::linuxkernel::MustCheckErrsCheck::check ( const ast_matchers::MatchFinder::MatchResult & Result)
override

Definition at line 31 of file MustCheckErrsCheck.cpp.

◆ registerMatchers()

void clang::tidy::linuxkernel::MustCheckErrsCheck::registerMatchers ( ast_matchers::MatchFinder * Finder)
override

Definition at line 16 of file MustCheckErrsCheck.cpp.


The documentation for this class was generated from the following files: