Skip to content

Rule 8.3: Consider anonymous structs and namespaces. #618

Closed

Description

@lcartey

Affected rules

  • RULE-8-3

Description

Anonymous structs provide an undistinguished qualified name - e.g. <anonymous struct>. This can cause false positives for this rule for structs which are not the same.

Example

struct OuterStruct {
	struct {
		SomeOtherStruct val[10];
		size_t size;
	} firstArray;

	struct {
		SomeOtherStruct val[10][2];
		size_t size;
	} secondArray;
};

Activity

  1. added
    Difficulty-MediumA false positive or false negative report which is expected to take 1-5 days effort to address
    false positive/false negativeAn issue related to observed false positives or false negatives.
    user-reportIssue reported by an end user of CodeQL Coding Standards
    on Jun 7, 2024
  2. self-assigned this
    on Jul 3, 2024
  3. added a commit that references this issue on Jul 3, 2024
    06bcd5b
  4. moved this from Triaged to Ready for review in Coding Standards Public Development Boardon Jul 3, 2024
  5. moved this from Ready for review to Reviewed in Coding Standards Public Development Boardon Jul 4, 2024
  6. added a commit that references this issue on Jul 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Difficulty-MediumA false positive or false negative report which is expected to take 1-5 days effort to addressImpact-MediumPhase IIIfalse positive/false negativeAn issue related to observed false positives or false negatives.user-reportIssue reported by an end user of CodeQL Coding Standards

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions