Skip to content

DCL51-CPP: Use of __func__ is considered a declaration of __func__. #215

Closed
@lcartey

Description

@lcartey

Affected rules

  • DCL5-CPP

Description

Any use of __func__ is being flagged a declaration/definition of __func__. This is because our model treats uses of __func__ as a LocalVariable declarations (!).

I think we should just exclude LocalVariables called __func__ from the query results.

Example

void test() { __func__; }

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