clang-tools 23.0.0git
clang::tidy::llvm_check::RedundantCastingCheck Class Reference

Detect redundant uses of LLVM's cast and dyn_cast functions. More...

#include <RedundantCastingCheck.h>

Inheritance diagram for clang::tidy::llvm_check::RedundantCastingCheck:
[legend]

Public Member Functions

 RedundantCastingCheck (StringRef Name, ClangTidyContext *Context)
void registerMatchers (ast_matchers::MatchFinder *Finder) override
void check (const ast_matchers::MatchFinder::MatchResult &Result) override
bool isLanguageVersionSupported (const LangOptions &LangOpts) const override
std::optional< TraversalKind > getCheckTraversalKind () const override

Detailed Description

Detect redundant uses of LLVM's cast and dyn_cast functions.

For the user-facing documentation see: https://clang.llvm.org/extra/clang-tidy/checks/llvm/redundant-casting.html

Definition at line 20 of file llvm/RedundantCastingCheck.h.

Constructor & Destructor Documentation

◆ RedundantCastingCheck()

clang::tidy::llvm_check::RedundantCastingCheck::RedundantCastingCheck ( StringRef Name,
ClangTidyContext * Context )
inline

Definition at line 22 of file llvm/RedundantCastingCheck.h.

Member Function Documentation

◆ check()

void clang::tidy::llvm_check::RedundantCastingCheck::check ( const ast_matchers::MatchFinder::MatchResult & Result)
override

◆ getCheckTraversalKind()

std::optional< TraversalKind > clang::tidy::llvm_check::RedundantCastingCheck::getCheckTraversalKind ( ) const
inlineoverride

Definition at line 30 of file llvm/RedundantCastingCheck.h.

◆ isLanguageVersionSupported()

bool clang::tidy::llvm_check::RedundantCastingCheck::isLanguageVersionSupported ( const LangOptions & LangOpts) const
inlineoverride

Definition at line 26 of file llvm/RedundantCastingCheck.h.

◆ registerMatchers()

void clang::tidy::llvm_check::RedundantCastingCheck::registerMatchers ( ast_matchers::MatchFinder * Finder)
override

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