Qt-CtorMissingParentArgument

Warns when QObject derived classes do not have at least one constructor receiving a QObject

Required inputs: IR

This is an attempt to catch classes which are missing the parent argument. It does not have false-positives, but might miss true-positives. For example, if you have a CTOR which receives a QObject* but then forget to pass it to the base CTOR.

This rule is based on clazy rule ctor-missing-parent-argument

Possible Messages

Key

Text

Severity

Disabled

warning

Class {} should take {} parent argument in its constructor.

None

False

Options

level

level : int = 2

Importance level of the rule as given for clazy. 0 is most desirable, higher values fall off in quality.