Skip to content

A2-7-3: documented type alias to template instantiation considered undocumented #709

Open
@fjatWbyT

Description

@fjatWbyT

Affected rules

  • A2-7-3

Description

A documented type alias where type-id is a template results in a missing documentation false positive. If the rhs of the (documented) alias declaration does not involve a template, then there is no alert.

Example

/// @brief Template type template_type description.
///
/// @tparam template parameter T.
template<typename T> struct template_type {};

/// @brief Alias to int a_documented_alias.
using a_documented_alias = int;

/// @brief Alias a2_7_3_fp_alias to instantiated template_type with int template parameter.
using a2_7_3_fp_alias = template_type<int>;

Running query UndocumentedUserDefinedType.ql, AUTOSAR A2-7-3, will evaluate to

| declaration of a2_7_3_fp_alias | Declaration entry for user-defined type a2_7_3_fp_alias is missing documentation. |

Metadata

Metadata

Assignees

No one assigned

    Labels

    Difficulty-MediumA false positive or false negative report which is expected to take 1-5 days effort to addressImpact-LowStandard-AUTOSARfalse 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

    Status

    Triaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions