AutosarC++18_10-A11.0.2

A type defined as struct shall: (1) provide only public data members, (2) not provide any special member functions or methods, (3) not be a base of another struct or class, (4) not inherit from another struct or class

Required inputs: IR

Possible Messages

Key

Text

Severity

Disabled

no_function_member

Struct shall not provide any member functions or methods.

None

False

no_struct_as_base

A struct shall not be a base of another struct or class.

None

False

no_struct_inheritance

A struct shall not inherit from another struct or class.

None

False

non_public_member

Structs shall only have public data members.

None

False

Options

ignore_template_specializations

ignore_template_specializations : bool = False

Whether special member functions or methods in template specializations should be ignored and not considered a violation.