clang-tools 23.0.0git
clang::tidy::bugprone::filter::relatedness_heuristic Namespace Reference

This namespace contains the implementations for the suppression of diagnostics from similarly-used ("related") parameters. More...

Typedefs

template<typename T, std::size_t N = SmallDataStructureSize>
using ParamToSmallSetMap
template<typename T, std::size_t N = SmallDataStructureSize>
using ParamToSmallPtrSetMap

Functions

template<typename MapTy, typename ElemTy>
static bool lazyMapOfSetsIntersectionExists (const MapTy &Map, const ElemTy &E1, const ElemTy &E2)
 Returns whether the sets mapped to the two elements in the map have at least one element in common.

Variables

static constexpr std::size_t SmallDataStructureSize = 4

Detailed Description

This namespace contains the implementations for the suppression of diagnostics from similarly-used ("related") parameters.

Typedef Documentation

◆ ParamToSmallPtrSetMap

template<typename T, std::size_t N = SmallDataStructureSize>
using clang::tidy::bugprone::filter::relatedness_heuristic::ParamToSmallPtrSetMap
Initial value:
llvm::DenseMap<const ParmVarDecl *, llvm::SmallPtrSet<T, N>>

Definition at line 1590 of file EasilySwappableParametersCheck.cpp.

◆ ParamToSmallSetMap

template<typename T, std::size_t N = SmallDataStructureSize>
using clang::tidy::bugprone::filter::relatedness_heuristic::ParamToSmallSetMap
Initial value:
llvm::DenseMap<const ParmVarDecl *, llvm::SmallSet<T, N>>

Definition at line 1586 of file EasilySwappableParametersCheck.cpp.

Function Documentation

◆ lazyMapOfSetsIntersectionExists()

template<typename MapTy, typename ElemTy>
bool clang::tidy::bugprone::filter::relatedness_heuristic::lazyMapOfSetsIntersectionExists ( const MapTy & Map,
const ElemTy & E1,
const ElemTy & E2 )
static

Returns whether the sets mapped to the two elements in the map have at least one element in common.

Definition at line 1596 of file EasilySwappableParametersCheck.cpp.

Variable Documentation

◆ SmallDataStructureSize

std::size_t clang::tidy::bugprone::filter::relatedness_heuristic::SmallDataStructureSize = 4
staticconstexpr

Definition at line 1583 of file EasilySwappableParametersCheck.cpp.