Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

A12-1-1: Does not apply transitively #829

Open
Labels
Difficulty-LowA false positive or false negative report which is expected to take <1 day effort to addressImpact-MediumStandard-AUTOSARfalse positive/false negativeAn issue related to observed false positives or false negatives.false-positiveAn issue representing a false positive report.user-reportIssue reported by an end user of CodeQL Coding Standards
@nbusser-sr

Description

@nbusser-sr

Affected rules

  • A12-1-1:cpp/autosar/explicit-constructor-base-class-initialization

Rule A12-1-1 (required, implementation, automated)
Constructors shall explicitly initialize all virtual base classes, all direct
non-virtual base classes and all non-static data members.

Description

⚠️ I'm not 100% sure if the rule actually allows transitive calls to constructors⚠️

Let an inherited class having two constructora andb.
a calls the base class constructor whileb callsa.
A12-1-1 gets reported onb because it does not call base class constructor directly (but it calls it transitively througha)

Example

classBaseClass {public:BaseClass()noexcept =default;};classClassfinal : public BaseClass {public:Class(void)noexcept : BaseClass() {};Class(bool)noexcept : Class() {};// Triggers `A12-1-1`};

Metadata

Metadata

Assignees

No one assigned

    Labels

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

    Type

    No type

    Projects

    Status

    Triaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp