Skip to content

readability-inconsistent-declaration-parameter-name shouldn't trigger on variadic template names #169195

@heinrich5991

Description

@heinrich5991
template<typename... Args>
void variadic_function(Args... args)
{
}

template<> inline void variadic_function(int foo) {} // readability-inconsistent-declaration-parameter-name
template<> inline void variadic_function(int args, int foo) {} // no warning
template<> inline void variadic_function(int foo, int args) {} // readability-inconsistent-declaration-parameter-name
template<> inline void variadic_function(int foo, int bar) {} // readability-inconsistent-declaration-parameter-name

I think readability-inconsistent-declaration-parameter-name shouldn't trigger on variadic arguments. It doesn't really make sense to name the first argument the same as an argument group.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions