|
clang 22.0.0git
|
#include "clang/Sema/Sema.h"
Public Types | |
| enum class | Kind { Added , Removed , ConditionMismatch } |
| enum class | OverrideResult { NoAction , Warn , Merge } |
| Describes the result of effects differing between a base class's virtual method and an overriding method in a subclass. More... | |
Public Member Functions | |
| StringRef | effectName () const |
| bool | shouldDiagnoseConversion (QualType SrcType, const FunctionEffectsRef &SrcFX, QualType DstType, const FunctionEffectsRef &DstFX) const |
| Return true if adding or removing the effect as part of a type conversion should generate a diagnostic. | |
| bool | shouldDiagnoseRedeclaration (const FunctionDecl &OldFunction, const FunctionEffectsRef &OldFX, const FunctionDecl &NewFunction, const FunctionEffectsRef &NewFX) const |
| Return true if adding or removing the effect in a redeclaration should generate a diagnostic. | |
| OverrideResult | shouldDiagnoseMethodOverride (const CXXMethodDecl &OldMethod, const FunctionEffectsRef &OldFX, const CXXMethodDecl &NewMethod, const FunctionEffectsRef &NewFX) const |
| Return true if adding or removing the effect in a C++ virtual method override should generate a diagnostic. | |
Public Attributes | |
| FunctionEffect::Kind | EffectKind |
| Kind | DiffKind |
| std::optional< FunctionEffectWithCondition > | Old |
| std::optional< FunctionEffectWithCondition > | New |
|
strong |
|
strong |
|
inline |
| bool clang::Sema::FunctionEffectDiff::shouldDiagnoseConversion | ( | QualType | SrcType, |
| const FunctionEffectsRef & | SrcFX, | ||
| QualType | DstType, | ||
| const FunctionEffectsRef & | DstFX ) const |
Return true if adding or removing the effect as part of a type conversion should generate a diagnostic.
Definition at line 1578 of file SemaFunctionEffects.cpp.
References Added, clang::FunctionEffect::Allocating, clang::FunctionEffect::Blocking, ConditionMismatch, DiffKind, EffectKind, clang::FunctionEffect::NonAllocating, clang::FunctionEffect::NonBlocking, and Removed.
| Sema::FunctionEffectDiff::OverrideResult clang::Sema::FunctionEffectDiff::shouldDiagnoseMethodOverride | ( | const CXXMethodDecl & | OldMethod, |
| const FunctionEffectsRef & | OldFX, | ||
| const CXXMethodDecl & | NewMethod, | ||
| const FunctionEffectsRef & | NewFX ) const |
Return true if adding or removing the effect in a C++ virtual method override should generate a diagnostic.
Definition at line 1640 of file SemaFunctionEffects.cpp.
References Added, clang::FunctionEffect::Allocating, clang::FunctionEffect::Blocking, ConditionMismatch, DiffKind, EffectKind, Merge, NoAction, clang::FunctionEffect::NonAllocating, clang::FunctionEffect::NonBlocking, Removed, and Warn.
| bool clang::Sema::FunctionEffectDiff::shouldDiagnoseRedeclaration | ( | const FunctionDecl & | OldFunction, |
| const FunctionEffectsRef & | OldFX, | ||
| const FunctionDecl & | NewFunction, | ||
| const FunctionEffectsRef & | NewFX ) const |
Return true if adding or removing the effect in a redeclaration should generate a diagnostic.
Definition at line 1615 of file SemaFunctionEffects.cpp.
References Added, clang::FunctionEffect::Allocating, clang::FunctionEffect::Blocking, ConditionMismatch, DiffKind, EffectKind, clang::FunctionEffect::NonAllocating, clang::FunctionEffect::NonBlocking, and Removed.
| Kind clang::Sema::FunctionEffectDiff::DiffKind |
Definition at line 15511 of file Sema.h.
Referenced by shouldDiagnoseConversion(), shouldDiagnoseMethodOverride(), and shouldDiagnoseRedeclaration().
| FunctionEffect::Kind clang::Sema::FunctionEffectDiff::EffectKind |
Definition at line 15510 of file Sema.h.
Referenced by shouldDiagnoseConversion(), shouldDiagnoseMethodOverride(), and shouldDiagnoseRedeclaration().
| std::optional<FunctionEffectWithCondition> clang::Sema::FunctionEffectDiff::New |
Definition at line 15515 of file Sema.h.
Referenced by effectName().
| std::optional<FunctionEffectWithCondition> clang::Sema::FunctionEffectDiff::Old |
Definition at line 15513 of file Sema.h.
Referenced by effectName().