clang-tools 22.0.0git
clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck Class Reference

Warns when an rvalue reference function parameter is never moved within the function body. More...

#include <RvalueReferenceParamNotMovedCheck.h>

Inheritance diagram for clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck:
[legend]

Public Member Functions

 RvalueReferenceParamNotMovedCheck (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
void storeOptions (ClangTidyOptions::OptionMap &Opts) override

Detailed Description

Warns when an rvalue reference function parameter is never moved within the function body.

This check implements CppCoreGuideline F.18.

For the user-facing documentation see: https://clang.llvm.org/extra/clang-tidy/checks/cppcoreguidelines/rvalue-reference-param-not-moved.html

Definition at line 21 of file RvalueReferenceParamNotMovedCheck.h.

Constructor & Destructor Documentation

◆ RvalueReferenceParamNotMovedCheck()

clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck::RvalueReferenceParamNotMovedCheck ( StringRef Name,
ClangTidyContext * Context )

Definition at line 119 of file RvalueReferenceParamNotMovedCheck.cpp.

Member Function Documentation

◆ check()

void clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck::check ( const ast_matchers::MatchFinder::MatchResult & Result)
override

Definition at line 79 of file RvalueReferenceParamNotMovedCheck.cpp.

◆ isLanguageVersionSupported()

bool clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck::isLanguageVersionSupported ( const LangOptions & LangOpts) const
inlineoverride

Definition at line 26 of file RvalueReferenceParamNotMovedCheck.h.

◆ registerMatchers()

void clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck::registerMatchers ( ast_matchers::MatchFinder * Finder)
override

Definition at line 39 of file RvalueReferenceParamNotMovedCheck.cpp.

◆ storeOptions()

void clang::tidy::cppcoreguidelines::RvalueReferenceParamNotMovedCheck::storeOptions ( ClangTidyOptions::OptionMap & Opts)
override

Definition at line 128 of file RvalueReferenceParamNotMovedCheck.cpp.


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