Skip to content

A2-10-1: Exclude variable templates #214

Closed
@lcartey

Description

@lcartey

Affected rules

  • A2-10-1

Description

Variable templates can cause name duplication across scopes. The simplest option would be to exclude variable templates all together from this rule.

In addition, the example shows two variable templates in the same scope - is that something we actually report? The rule should only report issues from inner/outer scope pairs.

Example

template <typename Foo>
constexpr bool foo = false;
template <T>
constexpr bool foo<T> = true;

Metadata

Metadata

Assignees

Labels

Difficulty-LowA false positive or false negative report which is expected to take <1 day effort to addressImpact-Highfalse positive/false negativeAn issue related to observed false positives or false negatives.top-25-fpsuser-reportIssue reported by an end user of CodeQL Coding Standards

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions